kevinmuise Posted November 11, 2012 Share Posted November 11, 2012 Room with television turns off and lights in bedroom go on. I go to bed; perfect most of the time. Occasionally I would like the television room to just turn off. What is the best way to program this? Kevin Link to comment Share on other sites More sharing options...
Cyknight Posted November 11, 2012 Share Posted November 11, 2012 Well easiest is in reverse - room off normally doesn't turn lights on, program "When room off command is received in room x, IF room is off, (trigger light)" This would make a second press (or any press while the room is off) turn those lights on.Do note that this doesn't work on all systems - on occasion a system may be too "slow".Another option is to create a boolean variable.on room off command received (don't use "when room is turned off for this), program a delay of 500 ms, then if variable is false, trigger the light program.Then, ABOVE this programming, do "WHEN room off command...., IF room is off, set variable to TRUE.This then prevents the light portion from triggereing on a double press.Same note as above however.OH!, at the bottom of this programming, do a "SET variable to false". Link to comment Share on other sites More sharing options...
kevinmuise Posted November 11, 2012 Author Share Posted November 11, 2012 Room off is not in my drop down in Events Command. Am I looking in the wrong place for When command 'Room Off' is received? Kevin Link to comment Share on other sites More sharing options...
Cyknight Posted November 12, 2012 Share Posted November 12, 2012 Sorry my bad - mixing a few things (versions ) up here.You can do the above right under the default events - power off, where it'll state "when room turns off". Unlike what I said previously this is where it has to be. Link to comment Share on other sites More sharing options...
kevinmuise Posted November 13, 2012 Author Share Posted November 13, 2012 Thank you so much for responding. This does not work. When the room turns off, the controller recognizes the room is off and the indented lighting program is sent. Any other suggestions? I would prefer light sequence after room off as default.I have a work-around where the 3-button keypad only turns on the lighting sequence and the keypad is on the way to bed. I have removed the lighting sequence after room off. Kevin Link to comment Share on other sites More sharing options...
Cyknight Posted November 13, 2012 Share Posted November 13, 2012 Try increasing the delay before light off to 5 seconds, see if that fixes it. From there you can lower that delay.So - IF room is off--Set variable to truedelay 5 secondsIF variable is false--Trigger lighting scene (or induvidual lights etcSet variable to falseLet me know if it doesn't work, I'm working on an alternative, but I need a bit to work it out. Link to comment Share on other sites More sharing options...
Cyknight Posted November 13, 2012 Share Posted November 13, 2012 The above works for me, just tested it, but I can see where it could possibly fail - the room is considered off already by the time the system looks at the programming.Try thisCreate a NUMBER variable X.Create a timer X, non-repeating, 1 second should doWhen Room turns off-Variables -> X = Variables->X+1 (in other words add 1)-Start timer XThen under that timerWhen timer X expires-IF Variable->X EQUAL TO 1--(insert your lighting programming here, indented below the IF).-Variables->X =0 (not that this one is NOT indented below the IF).Now pressing room off would have the lights turn on after 1 secondPressing it twice (or more) within the span of the 1 second timer will ramp that variable past 1 before timer expires and the lighting should NOT turn on. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.