I'm working with a traditional state machine that stores the current state in an OO cluster and reads it in the next iteration (no shift registers).
I have another VI that handles the User Interface, it's a loop with an event structure.
I need to transition the state machine according to the events of the UI.
In the past, I have simply wrote a new state to class variable when the desired event occurs. This "works", but has proven unreliable because at times I find that the state machine will rewrite the variable after the User Interface VI tries to change it.
I've tried boolean flags indicating certain UI events, but it seems to be slower. I've also tried writing event refnums to variables, this is about the same speed and probably a gratuitous waste of memory.
How do you do it?