LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to properly update control cluster in a state machine

Solved!
Go to solution

Hello,

 

I have a program with an FSM feeded by a global cluster containing both controls and data.

 

The user can enter his own data in the STRINGA/B field, but these fields can also be updated programmatically (by clicking on update).

 

The programming concept is fine for data (which remains invisible for the user, and should not be edited directly), but I have problems correctly updating the controls in front panel. Moreover, the user input are not taken into account inside the program : maybe this is normal, because Global cluster is outside while loop... but i'm stuck : I don't know how I can do that properly otherwise...

 

Is it a good thing to have data and controls in a same cluster ? How can I have a proper control cluster which can be updated by user and by the program (last who update is the winner) ? 

0 Kudos
Message 1 of 6
(2,341 Views)

You also need an event for "global cluster:value change" where you write the new value from the event terminal into the cluster in the shift register. In the cases for programmatic change, write to the shift register and a local variable of the cluster.

Message 2 of 6
(2,315 Views)
Solution
Accepted by topic author haha1234

Maybe something like this?

 

 

Download All
Message 3 of 6
(2,310 Views)

thank you for your help.

 

I will try to implement this by myself, but could you please convert your solution to LV 2015 so that I can open it ?

 

best regards !!

0 Kudos
Message 4 of 6
(2,278 Views)

I down-converted to 2012, but accidentally uploaded the wrong file. I added the LabVIEW 2012 to my post above.

Message 5 of 6
(2,265 Views)

thank you everything is working as it should 😉

0 Kudos
Message 6 of 6
(2,256 Views)