LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

state machine vs. event driven programming

As per Altenbach's suggestions,


  1. Set the valves and cursors to a defined state when stop is pressed or the panel closed.
  2. Define proper actions if the system is toggled while it is still in the middle of a previous change sequence.
  3. Make the code more readable by changing the state constant e.g. to an enum with descriptive state names.
  4. I really dislike the current toggle switch implementation because the actual boolean value is not used, just implied from the dataflow. This can be dangerous.
  5. I probably would use a latch action toggle button together with LED indicators that show the current state (right or left).
  6. ...
1.  Good idea, I will install this as a state predicated on the stop button change of value event.
2.  I thought that the cursor sleep function prevented all actions but the LabVIEW stop function...  I will look into this.
3.  A nice thought...
4.  I can fix this by wiring it's state to the 0 state that initiates the state sequence.
5.  Is this not the cluster? 


0 Kudos
Message 11 of 11
(721 Views)