I am having problems executing a simple IF statement and I think it is because my trigger turns off before actions are completed. I would like my kitchen sink light to turn on (red) for 3 seconds, turn off, turn on (white) for 3 seconds, turn off.
I know I probably do not need the final statement to turn the light off but I am seeing the light turn on (red), turn off, turn on (white)…and stay on.
The trigger condition (driveway contact sensor) is only active for about 3 seconds so I’m thinking that this turns off and the action statement does not finish executing. I originally thought that when the state changes from closed to open, the action statement would take place regardless of status of trigger but it is not working this way.
If so, how do I get the entire statement to execute even if the trigger turns off before the action is completed?
IF statement not fully executing
zr8000
#1
eibyer
#2
In your WITH, click the cog icon and in the Task Cancellation Policy, select Never Cancel.
jrfarrar
#3
I could understand that if it was “stays” open but wouldn’t a “changes to” open trigger the whole then regardless of what happens next (aka the contact closing?)
Cozdabuch
#4
Moved thread to Piston Design & Assistance category, it didn’t belong in the instructions and tutorials category
bobbles
#5
Put the Turn Off in your first If. Straight after the last Flash.
It shouldn’t be in a desperate with.