In this video you will see a simple template which you can use to write a simple state machine that handles UI and user events. Additional resources: bit.ly/1eEoi6B
i used to implement state machine with case structure inside a while loop, to respond the user event, maybe some more while loop, case and event structure...the block diagram turn messy. and your demo really hit me in the spot, case inside event inside while, nice!
Lol if only our professor would've taught us on how to use Event Structures, many of our assignments would've been so much easier. Already see many ways to implement this, good job explaining the combination of state machines and event structures.
Excellent Tutorial. There is no problem to follow by the intermediate level. But it will be too fast for whom just started to learn the Labview unless they use the pause or rewind to follow. Overall this video is excellent. Much appreciated for posting it here.
a great work , thank you alot . My question is how can i use event structure with a sub VI , , it means inside the event structure , how can i put a sub vi.
Weird to execute any functional code in the timeout event. What if events happen so fast that the timeout is never triggered? The event structure should be inside the case "Idle" (or I usually call it "Wait Event"). Also, all cases should go back to the "Idle" state after executing (except "Stop" that exits the loop).
what happen if there is a WHILE loop inside aFOR loop inside one of the states (Pause for FOR loop), and while the FOR loop is waiting, it is needed to trigger another process in another state, will the event structure still have high priority over inner loops?
Why do you put the case structure inside the event structure? 🤔 I would prefer to put the event structure inside the case structure instead. And name the state as wait for event.