01-02-2015 11:23 AM
In this application, a TopVI has several buttons which call various subVIs.
The subVIs to be called have a few indicators or controls in common - like a waveform chart and boolean in this example.
Because the subVI selected could be any based on the button pressed, control/indicator references are bundled as a cluster and output from the subVI through the pinout.
See the block diagram of the topVI below/
In the topVI, when the subVI is called, the output control reference cluster is stored in a cluster. During data operations, the control refs are passed via a local variable to the code that does the graph or data operations as in the lower loop. A state machine is used to decide which state the program is in (depending on the button pressed).
The lower loop uses a local variable referring to the state to decide what data operation to do. Note, the updateVI operation is generic and works for any subVI that has a waveform chart.
The above example relates to a very specific customer application.
01-02-2015 11:24 AM
Here's the zipped file for program.