PXI

cancel
Showing results for 
Search instead for 
Did you mean: 

build startup executable for RT

I am trying to make a VI into my startup executable on a PXI System running LV RT.  This VI dynamically calls 2 other VIs.  These VIs call multiple subVIs in turn.  My first attempt at this process created an Error 42:

 

Visit the Request Support page at ni.com/ask to learn more about resolving this problem. Use the following information as a reference:

Error 42 occurred at Create Folder in Create Directory Recursive.vi->AB_Destination.lvclass:Create_Destination.vi->AB_Build.lvclass:Create_Destinations.vi->AB_Application.lvclass:Create_Destinations.vi->AB_Build.lvclass:Build.vi->AB_Application.lvclass:Build.vi->AB_RTEXE.lvclass:Build.vi->AB_Engine_Build.vi->AB_Build_Invoke.vi->AB_Build_Invoke.vi.ProxyCaller

Possible reason(s):

LabVIEW:  Generic error.

C:\FSPR\builds\Engine Monitor\RT PXI Target\SCRAMNetRTApp\c\ni-rt\startup\startup.rtexe\LabVIEW 2009

 

After reading the instructions in Help and the the KB articles I'm confused.  Do I need to make source distribution library for each of the dynamically called VIs?  If so, how do I reference them when I build my startup executable?  Is this the source of my error?  I've enclosed the VI I'm trying to make into a startup executable.

0 Kudos
Message 1 of 11
(5,887 Views)
sorry, here's the VI
0 Kudos
Message 2 of 11
(5,886 Views)

faustina,

 

It is a little difficult for me to tell exactly what is going on in your code with out seeing what is in the subVIs.  But what I would suggest doing is to start pulling pieces out of your VI to see what is causing the error.  It looks like you have determined that this is caused by the VIs that you are calling by reference.  If you make these plain subVIs, do you stop getting the error?  If you make a simple VI that only calls these VIs by reference do you getting error 42?  If so could you post these VIs so that I can see if I can reproduce this?

Justin Parker
National Instruments
Product Support Engineer
0 Kudos
Message 3 of 11
(5,868 Views)
I modified the startup executable VI to not dynamically call the other VIs and I got the same error 42.  Enclosed are the startup executable VI and the dynamically called VIs
Download All
0 Kudos
Message 4 of 11
(5,853 Views)

In the code that you posted you are still calling VIs by reference.  I would like you to just put those VIs in as subVIs, to see if that is what is causing the error you are getting.

 

thank you

Justin Parker
National Instruments
Product Support Engineer
0 Kudos
Message 5 of 11
(5,836 Views)

same error

 

enclosed is the modified VI plus PPT document showing how I configured the Build.  I need to figure this out soon.

Download All
0 Kudos
Message 6 of 11
(5,761 Views)
Hi faustina,

Can you try the following troubleshooting steps:

1. Create a simple project with one VI, can you build a startup application successfully? If not, the your installation may be at fault.
2. Copy your VIs (not the project files like .lvproj) to a new folder and create a new project. Add the VI and make a new build specification. Do you get the same error?
3. If still unsuccessful, try removing VIs from your SCARMNet Interface.vi and rebuild. This is to check it one of those VI are an issue. Since you have not posted all VIs, do you know if those subVIs are RT compatible?
4. If still unsuccessful, can you move all your VIs under the My Computer portion of the project and build an executable. Do you get the same error?
Joshua B.
National Instruments
0 Kudos
Message 7 of 11
(5,738 Views)

step 2 enabled me to finally build the VI.  I could even modify the build specifications in my original project to those of the new project then build and deploy sucessfully.  However, determining the VI is running properly is proving to be a problem.  When I deploy the build the .exe and .alias files are placed in the c:\ni-rt\startup directory.  Then I reboot the PXI System and it crashes soon after startup.  Startup proceeds as normal, with the startup application beginning, up until the VISA Server begins.  Then the System crashes.  If I reboot into safe mode, delete the .exe and .alias files, then reboot into standard LabVIEW RT, the PXI System STILL thinks it is beginning the startup application located in c:\ni-rt\startup directory. Why is this?  The PXI System does not crash and seems to be running the startup application without incident.  I don't know for sure, that's why I want to run the debugger.  However, when I ask to run the debugger from the Project Explorer, LabVIEW cannot find the VI.  I assume this is because the .exe and .alias files have been deleted from the c:\ni-rt\startup directory.  Correct?  So what fundamental RT stand-alone concept am I missing?

0 Kudos
Message 8 of 11
(5,718 Views)
Hi faustina,

Once you delete the file from the RT target you have essentially prevented it from running. However, the ni-rt.ini file still calls for the startup application has specified KnowledgeBase 3Z5BJCIZ: How Do I Deploy a Startup Executable to my Real-Time Controller? The preferred method for disabling a startup application from running is to use the Disable Startup VI swtch on the hardware or the RT target or change the BIOS to Disable Startup VI under the LabVIEW RT options.

What is the crash that you see on the screen of your RT system? Does the application only crash when you enable debugging in your build specification? Do you still get the original error that you reported in the first post of this thread?
Joshua B.
National Instruments
0 Kudos
Message 9 of 11
(5,713 Views)

the original error that started this thread seems to be gone

 

It doesn't seem to matter whether the debug is enabled on the startup exe or not.  The system still crashes right after bootup with the following:

 

NI-VISA Server 4.5 started successfully

Welcome to LabVIEW Real-Time 9.0

Internal Error:  [0...19] nxnxnxn_nxnxnxn_nxnxnxn Scheduler Assert : 1667: If you have enabled serial console error logging, detailed error info could be found at that console.

 

I created a default RT Project with LabVIEW and that made that target VI a startup exe.  It runs at bootup, however, I cannot get the host VI to run because of target issues.  I think this KB describes it.  http://digital.ni.com/public.nsf/allkb/F60F12FC5B3B2161862571160081AA88  However, I don't see the Autodeploy option for the SV library.

0 Kudos
Message 10 of 11
(5,689 Views)