LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I keep the local variables that are within my subvi, local to only that instance.

I have created a subvi to detect a state change of a boolean control with a date/time stamp. I need this subvi to run simultaneously, about 64 instances, monitoring the states of those switches. The problem I have encountered is that the local variables are not local to the subvi rather to the mainvi cause the other switches to interfere with each other, thus giving me mixed results. I DO NOT want to pass any of these local variables out of the subvi. So that the multiple instances would treat them as their own variables.
0 Kudos
Message 1 of 2
(2,658 Views)
Hi Thomas,

To have a subvi running simultaneously you would need to set the subvi as re-entrant. But it sounds as if you need the front panel to show a visual state of your switches, which would cause a problem as a reentrant vi does not update the front panel.

A other way would be to have individual subvi for each switch.

Ray Farmer
Regards
Ray Farmer
Message 2 of 2
(2,658 Views)