NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Is there a way to keep a VI open during an entire seqeunce run in order to store globals

When TestStand and LabVIEW both finally exit, the resources will probably be released if you don't explicitly close the object, so clean up whatever messes you make.

0 Kudos
Message 11 of 16
(922 Views)

It is wise to close references when you are done with them. That way you don't leave the machine in a bad state.

 

Regards,

jigg
CTA, CLA
testeract.com
~Will work for kudos and/or BBQ~
0 Kudos
Message 12 of 16
(918 Views)

Hi Jigg

I would like to keep automation refnum alive during the test cycle, If labview VI is closed then reference will no longer be valid. Is there an option to keep the reference alive using teststand function.

Thanks 

Vnod

0 Kudos
Message 13 of 16
(385 Views)

Since Teststand will close references after a sequence run, you need to use Labview. Open VI Reference Function with option 0x80, use Start Asycronous Call function. Let that reference remain open running in a loop during the TS test sequence. If you restart your sequence, you have to check if the loop vi is running "VI Property", if running do nothing. If it is not then dynamically (Start Asycronous Call) to open the reference. Your choice of how you would like to stop the loop, a TS Clean Up step, or Task step that sets uses a boolean to stop the loop etc. 

 

In my case, I had only 1 connection to open a reference and could not close the connection unless Labview was exited.

0 Kudos
Message 14 of 16
(356 Views)

Hi Richjoh

 

I'm trying opening reference using 'Labview Automation Refnum" & then VI executes in a loop using asynchronous call and also using TS Sequence Context -- Parameters Property Object in VI looking for Stop variable that I intend to set using LV FG VI.

 

Please send a screen shot of your VI 

 

Thanks 

VKP

0 Kudos
Message 15 of 16
(344 Views)

Don't have a screen shot. 

 

You can start with Open VI Reference, then Start Asynchronous Call to open a loop which will keep the references alive. Since the loop is dynamically called, TS/Labview doesn't care and the Labview maintains its connection to the DLL.

0 Kudos
Message 16 of 16
(329 Views)