03-19-2018 01:13 PM
Hello
I am struggling with the enclosed VI.
I am wanting a VI to perform a calibration when the 'Calibrate' button in MainVI is pressed. A calibration will consist of either:
1) a 'Set' procedure; or
2) a 'Measured' procedure,
3) or both.
Which of these are performed will depend upon which booleans have been set to TRUE in the 'Ranges' cluster in MainVI.
When the 'Calibrate' button is pressed I want the current Boolean values in the Ranges cluster in MainVI to be passed over to the Ranges cluster in CalibrateVI. CalibrateVI will then look at these values and will perform the procedures that have been set to true.
I've had an attempt with the attached VIs (stripped down to the relevant parts) but am not getting the behaviour I require. For example:
1) When I first run MainVI with 'Set' already true in MainVi and
'false' in Calibrate.vi, then pressing the Calibrate button does not
put 'Set' to true in Calibrate.vi.
2) When I first run MainVi with 'Set' false in both MainVI and
calibrate.vi, then by making 'Set' true in MainVI and pressing the
Calibrate button, then 'Set' become true in CalibrateVI.
3) When I press the Calibrate button again (i.e. with Set being true in
MainVI and true in CalibateVI), then Set in CalibrateVI is made false.
I would be grateful if anyone could advise me on what I'm doing wrong and how to get the behaviour I'm looking for.
Thanks
Ron
Solved! Go to Solution.
03-19-2018 01:48 PM - edited 03-19-2018 01:49 PM
The feedback node you are using does not have an initial value; if you click the Set button before you run the VI, the feedback node will output default values (False in this case). Here is a way to set the initial state of the feedback node:
Unless you want other things to happen when you change the value of the Ranges cluster, the best thing to do is read the Ranges cluster directly:
03-20-2018 05:16 AM
Hello Smoot
Thank you very much for your reply. It solved my problem.
Ron