I assume this will be an easy one, but I’m a total node-red noob: for my vacation mode, I want the lights to come on at sundown or at 7pm, whichever is earlier. That way, in the summer months, the house doesn’t stay dark until ~9pm when the sun finally goes down. Any advice?
Right now I’m using bigtimer and have it triggering off just sundown. Maybe I can combine this with another bigtimer and use OR logic to achieve what I want? Should I just have 2 bigtimers that feed into the same sequence? I’ll have the “repeat every 1 minute” option enabled, so I was worried about 2 timers causing the lights to turn on and off repeatedly, if one ever wants them on while the other wants them off.
I’d also like to know how I can combine two timers with AND, so that e.g. I can have the lights turn on if it’s 7pm and after sundown.
On the surface, why don’t you have two timers feeding into your light node?
Obviously the earlier one will turn on the lights first!
If you are concerned with the second node turning on the lights after you’ve explicitly turned off the lights then you can simply place a rate limiting before the light node to drop any messages after the first one.
Part of the appeal of bigtimer for me is the option to trigger ON once per minute if the current time is within the range, and OFF if isn’t. That way, the lights enter the state they should be in within a minute of switching the house to vacation mode. My concern is that with one timer starting at sundown and the other at 7pm, then for a couple of hours each day they’ll be sending competing messages.
Yeah, that’s why my initial question was basically: how can I combine these two timers using OR logic? If either says on, then I want the lights to turn on. I suppose I could listen to all the once-per-minute messages and turn the lights off only when there are two off messages in a row. But I’m not sure how to go about that, and it seems like there should be an easier/less hacky way.