1) Give a description of the problem
I have a piston that turns on Garage Entrance Lights when vehicle is parked (trigger), then waits for 5 mins before continuing along, unless the light is manually switched off then it stops waiting and continues on. The only way I have successfully made this work is using a for loop and break on if condition. I’ve tried and tried with while and if statements to no avail. The for loop/break method works, but its holding up the piston for intervals of time and not efficient. Can someone please show me how this is done?
2) What is the expected behaviour?
Turn on light, wait for period of time, or if light is turned off at switch stop ‘wait’ and continue piston
3) What is happening/not happening?
I have to use continuous for loop on delay to keep checking for condition of light then break loop to continue or loop ends after count and continues. I’m looking for more efficient method.
**4) Post a Green Snapshot of the piston![image|45x37]
5) Attach logs after turning logging level to Full