Oklahomazeke Posted June 16, 2020 Posted June 16, 2020 I am trying to trouble shoot my first program...a motion sensor turns on a light, waits 5 minutes, then turns it off. It turns on, but not off. I have also attached the log file as a screenshot. >>pasting code<< laundry light on - [ID 0004][Parent 0001] If 'Laundry sensor-Sensor' Status is On Then Set 'laundry switch' On Wait 5 minutes Set 'laundry switch' Off Else - No Actions - (To add one, press 'Action') <<
larryllix Posted June 16, 2020 Posted June 16, 2020 In addition to lilyoyo1's advise above, set your Motion sensor to send On only. The off signal is likely cancelling your Wait line and running Else which contains nothing. You could add Set 'laundry switch' Off to the Else section to capture the short time-out of the MS, also to prove that is happenning.
BamBamF16 Posted June 17, 2020 Posted June 17, 2020 I'll go into a little more detail and expound on the larryllix and lilyoyo1 said. Here is what is happening: 1. Motion sensor sees motions and sets control to on and status to on. 2. That triggers your program and the light turns on. 3. Wait 5 minutes happens. 4.Motion sensor stops detecting motion and after timeout a Control off and status off is sent. And here is where it gets dicey: 5. Because the program was in a wait AND an event in the IF statement changes (Status On) the if is reevaluated, but now it is FALSE. So the program runs the ELSE branch and the light never turns off. Here is what I would do to help combat that: 1. Set MS to send on ONLY 2. Make a scene with the MS as a controller and the light as a responder. Set the light level you desire. 3. When the MS sends the ON, the light will come on very fast 4. Since the MS only sends an ON, and it is a scene nothing get reevaluated. What about turning the light off? Make a program as follows (excuse my poor syntax): If MS control is on Then Wait 5 Minutes Turn Light Off Else Nothing This will reset the 5 minute timer every time motion is sensed, but the light will turn off after 5 minutes of no motion. PS. I'm pretty sure I use control, but I just moved and don't have my full setup running and no MS's currently. Jeff
apostolakisl Posted June 17, 2020 Posted June 17, 2020 you could also just move the "wait 5 minutes, turn light off" to the else clause. The light will then turn off 5 minutes after the last detected motion. Personally, I would set it to more like 2 minutes unless the room has hidden spots where you could be moving without the MS seeing you. Might also consider an over ride program. If laundry rm switch is control switched fast on and laundry rm switch is not control switched fast off Then disable first program Else enable first program
asbril Posted June 17, 2020 Posted June 17, 2020 10 hours ago, bambamf16 said: 2. Make a scene with the MS as a controller and the light as a responder. Set the light level you desire. 3. When the MS sends the ON, the light will come on very fast This works with Zwave ?
BamBamF16 Posted June 17, 2020 Posted June 17, 2020 4 hours ago, asbril said: This works with Zwave ? That I do not know as I did not use ZWave MS's. I would guess since it requires ISY interaction it wouldn't be as fast as insteon MS's
Oklahomazeke Posted June 17, 2020 Author Posted June 17, 2020 Thank you thank you thank you all! I'm starting to grok the flow...much appreciated. 20 hours ago, lilyoyo1 said: Change status to control
Recommended Posts
Archived
This topic is now archived and is closed to further replies.