This object is in archive! 

Turn on light set time and keep it on

Tim O'Pry shared this question 8 years ago
Need Answer

Goal is to turn on a light at a set time and keep it on until a specific time (if turned off manually before the end time).


The following rule will turn on the light ONCE - if and only if, the start time is in the future from when I last synchronized the rule. If I use a prior date/time - nothing happens. I should not have to constantly change the start time each and every time I edit the rule? Since it is set to repeat every minute - I thought it would check the conditions of the rule - each cycle (minute). Is that not the case:

7f3eb177d9125a8548ff050e25b284a9


If the schedule start time is in the future when synchronized, then the light will turn on at the beginning of the between time, but if it is turned off - it stays off, regardless of the time - and never turns back on - even the next day.


How can I get the light to be turned on at a specific start time and have the rule constantly check the light each minute and turn it back on if off?


I have looked at all the examples/YouTube videos, including: https://community.zipato.com/knowledge-base/article/rule-example-presence-simulator and have not seen any specific information on the scheduler, indicating that it must use a start date/time in the future.

Replies (4)

photo
1

I think you are after something like this. One rule will turn the light on every day at whatever time you put into the scheduler. The second will turn the light back on if it is turned off during your specified timeframe.


If this is not correct, please explain you intentions again. Hope this helps

photo
1

Thank you for the suggestion, but your first rule that uses the scheduler turns on the light and it stays on, even without the 2nd rule, turning it off from the control center/mobile app - once the interval lapses, the light turns back on.


The 2nd rule with the JOIN does not appear to have any effect. If I disable that rule, the results are the same and even if combined with my original rule, the light remains ON/turns back on - indefinitely.

photo
1

Remove, not disable, any other rules you have established with this switch. Just have the rules I posted. If you want to turn the light off at 23:01 you can make another rule like the first with the scheduler. Attached is a pic of how the "on" scheduler should look

What do you mean "once the interval lapses, the light turns back on." What interval?


I have found, with some Zipaboxes, that disabling a rule did not always stop it from working or conflicting with other rules. Not sure why this happens, so to be sure I just remove them. Alternatively you could try the second rule like this.

photo
1

Thanks for the info about disabled rules not being...disabled. I will experiment more once I verify the suggestion by Olivier Legros below.

photo
photo
1

I would create a virtual switch 'Force Light On' that will be triggered by 2 schedulers: a daily one that 4pm that will turn the light on and set the virtual switch to 'on', and a second one at 11pm that will turn the light off and set the virtual switch to off.

Then a third rule will be triggered when your actual switch is pressed and verify the virtual switch 'Force Light On' is not on.

Basically the virtual switch acts as a 'global variable'


Edit: just tried, works well :)

photo
1

Thank you - that's an interesting approach, I will give it try.

photo
photo
1

Nice Idea, think ill try this one myself but with a variable rather than creating a virtual switch. Thanks

photo
1

I am quite new with Zipato, playing with it for the last couple of weeks. Do you mean variable do persist outside the execution of the rule. If that's the case, it sure is easier ...

photo
2

Yes, the can create a variable inside the rule maker and use its values inside other rules. Saves having to add so many virtual devices. Variable can also be used as sensors or metres. Very handy.

photo
1

Thanks for the suggestion about using a variable - works great!

photo
Leave a Comment
 
Attach a file