11-12-2019 12:52 PM
"One way out, would be to move the toggle boolean into the while loop."
I tried that before and it doesn't work. The latched toggle resets but master on/off won't work anymore.
I will look into the state machine. Has started looking at that yesterday. Thanks.
11-13-2019 06:51 PM
So I ended up just building a simple State machine from scratch and it works fine. Just took me a while to relearn how they work. That commercial one just seemed to complex and I wanted understand what I was doing.
My new version is very simple. No Event Structures. I saw a Youtube video on a State machine that still uses an Event structure. Maybe that would be more efficient and I may try that later.
My new version just uses some logic in the idle state to see if the Toggle button was pushed, otherwise goes and does another set of reads and then back to idle.
Thanks for all the ideas and help here.