DAlba Posted March 8, 2017 Posted March 8, 2017 Here is my current program If status "entry door sensor" is on Then Set scene "hall light switch" on Wait 10 minutes Set scene "hall light switch" off What happens is the lights will come on but never turn off. I have same problem with similar program with garage door sensor and lights so I am sure I am just doing it wrong. It seems as soon as i close door after opening it kills the program so never completes. thanks
stusviews Posted March 8, 2017 Posted March 8, 2017 Does the light turn off if you don't close the door? Are the sensor and hall light members of a scene?
oberkc Posted March 8, 2017 Posted March 8, 2017 Rather than "status" as a condition, use "control". If Control "entry door sensor" is turned on Then Same.....
sdynak Posted March 8, 2017 Posted March 8, 2017 IF it helps here is something that works for me in a similar arrangement .. for some reason the else statement makes some difference which I got from similar suggestions here. Hallway Auto Light - [iD 0021][Parent 0001] If From Sunset + 1 minute To Sunrise - 1 minute (next day) And Status 'Front-Door / Front Door-Opened' is On Then Set Scene 'Hallway Auto Light' On Else Wait 2 minutes Set Scene 'Hallway' Off
andyf0 Posted March 8, 2017 Posted March 8, 2017 (edited) The problem with your program is that when the door is closed the status of the door sensor changes which causes the program to start again from the beginning. Since the door is closed the "else" portion of your program is executed. Since it's empty, it just ends. If your door sensor is an Insteon device you can use the "if control" statement as mentioned above. If it is a Z-Wave sensor then you'll need two programs: if Status "entry door sensor" is on then Run Program "turn light on" (if or then) else Program "turn light on" if then Set Scene "turn hall light" On Wait 10 mins Set Scene "turn hall light" Off else I would have thought that if the door is closed you'd want the light off anyway, in which case you can simply turn the light off in the "else" clause. If status "entry door sensor" is on Then Set scene "hall light switch" on Wait 10 minutes Set scene "hall light switch" off Else Set scene "hall light switch" off Edited March 8, 2017 by andyf0
DAlba Posted March 8, 2017 Author Posted March 8, 2017 Thanks for the replies everyone. Using "control" worked.
Recommended Posts