Code Processing Sequence During Boot of NX / NI
tholt0831
Posts: 1
I am having a problem with code that ran on an NI-3100 running on an NX-3200. I believe it is related to the processing sequence of code during a boot. I thought I understood the order, but maybe I don't. Can some one provide a complete list of when each section is executed?
DEFINE_START in main-program and modules
DEFINE_EVENTS - ONLINE: in main-program and modules
(How do virtual-devices fit in here, both for the local to the NI/NX and for a remote NI/NX)
DEFINE_START in main-program and modules
DEFINE_EVENTS - ONLINE: in main-program and modules
(How do virtual-devices fit in here, both for the local to the NI/NX and for a remote NI/NX)
0
Comments
There shouldn't be any differences.
We upgrade NI's to NX's fairly often and the code only requires a few changes with respect to devices depending on model upgrading.
These do load faster.
Maybe post some code for us to check?
I use it to initialize Variables on Boot.
Do we have a better place to get a Boot Status?
It has to do with under the hood stuff and the way Java is working.
You can make your own Define_Start like this:
That's not exactly true. Technically, every DEFINE_FUNCTION and DEFINE_MODULE are part of the DEFINE_START section. If you leave it out, you are going to get a compiler error. DEFINE_PROGRAM, however, you can do without.
Yeah, this knda points to an old AMX credo of never do somethng that breaks old code. We've been doing DEFINE_START for ever. I'm not sure what exactly is the issue with the discussion on define_start with the new NX series and how it interfaces with JAVA under the hood. I do know that using define program on them results in a significant performance hit. Perhaps it's the same issue.
Define_start has always struck me as odd in regard to what all goes there, like for example, CREATE_BUFFER and why you can't create code with any stack_vars but put the same code in a function or call and call it in DEFNE start and it compiles and works fine. I know it all has to do with the order of the runtime build. But it manifests itself in puzzling ways sometimes.