Turn off of switch not working


#1

HI,

So I have an if scenario that if the front door is opened during certain times, a light near it goes on, fades, then turns off after a couple minutes. It will turn on the light just fine, but it won’t turn off the light unless I set it in seconds. Minutes isn’t working. First two sets of screen shots are the piston that worked fine and the second two are the one that the turn off command didn’t work…

Works:


Doesn’t work:


47 PM


#2

Try changing the ‘with’ Task Cancellation Policy to never.
Your contact sensor is probably going false before the 1 minute timer can mature and therefore cancelling the tasks.
The first one is only 10 seconds and probably not cancelling the tasks.


#3

Your “doesn’t work” piston logs show an event of door closing. If you close your door before the 1 minute timer is up the If statement becomes false which is then cancelling the actions (timer , then off)

If you do as @bobbles said then closing the door before the 1 minute has elapsed will not cancel the timer. :grinning:


#4

Thank you to both of you, I will give this a try, but I am sure both of you are right. Maybe I should change my name to “Dumbie.” Should most of my pistons be set for “never” on the task cancellation policy? WebCoRE is way smarter than me, apparently…


#5

I would call you a newbie. Not a dumbie.
There is so much to webCoRE and its just a matter of getting your head round it all.
As for setting TCP to never on all pistons, if you have ‘waits’ then I would say yes. But not always. It does really depend on your piston.


#6

Thank you