For a machine control application, I have a sub panel container called the Main.vi. And depending on the user menu selection , I have a variety of sub VIs to load ( AutoMode, ManualMode , Calibration mode etc )
I need to read and update the state of some 14 Digital Inputs in each of the above VIs at 50ms intervals in a Timed Loop. Since the 14 DIs are common to all the sub VIs, which is the best way to go ? :
A. Read the state of the DIs in each of the sub VIs which is currently loaded.
B. Read the state of the DIs in the main.vi and pass on to the loaded sub VIs through Global Variables ( after all somone has to use them ;-))
I know the option A is preferred but there is a small catch : The menu selections are mostly done by switches which are also part of the 14 DIs that I mentioned. So when only the main.vi is loaded and I choose the A Option, there is no way for me to "read" the user intention and load the relevant sub VI.
I would hence have to choose option B. If so what is the real penalty ??
Raghunathan
Raghunathan
LabVIEW to Automate Hydraulic Test rigs.