Hi altenbach,
I really wish I could get your nice event structure to work for me. At least I am learning about them and I am trying to implement it into my code. I have posted my working code to help describe my problem. I have one main loop. The two top case structures are the ones I am concerned about. When the booleans are both FALSE, I only want case "0" to run once. Case "0" won't run again until the booleans change and are again both set to FALSE. If selected, I need cases "1" or "2" to run every 1000ms with the main loop because "1" runs PID controls and "2" needs to update if the flow setting is changed. I couldn't get cases "1" and "2" to run like that with the event structure. In addition, I read about the caveats of event structures and I will need to have more than one structure in the main loop. That is, the structure below the top case structure needs to operate similarly.
I thought I could do it with with a simple shift register comparison, but I like the event structure programming and can see more uses for it in my code.
Thank you very much for your patience and help.
Yours,
-dewey