I want to have a light bulb change color depending on outdoor temperature and also be on/stay on after Sunset and before Sunrise.
If I so if I make an AND rule that triggers on Sunset and also temperature, I am pretty sure that at Sunset the light will go on to the color that I select.
My question is, if the temperature changes during the night across the threshold that I have set to switch to the new color, will the AND rule be re-evaluated and will it pass the test? In other words, it is no longer "Sunset", but AFTER Sunset. Does "Sunset" mean only the instant that Sunset occurs, or does it mean all the time between Sunset and Sunrise ?
Given the way you describe the rule I would expect that the triggers occur at sunset (turn on set color) and sunrise (turn off). To do it the other way, your trigger would need to be on temperature change with a condition of time between sunset to sunrise.
1 Like
Triggers are inherently "OR" because any event that matches a trigger will cause your actions to run. You can use conditionals in your actions to determine what, if anything, happens as a result. But because of this, the only way to know the answer to your question is for you to provide a screenshot or mock-up of your rule. But also because of this, whatever outcome you want is possible--just have to set it up right.
(The above is oriented towards Rule Machine, which I'm assuming is what you are using for this. I don't think Simple Automation Rules could handle the entirety of this automation, though it could certainly handle pieces, and there's nothing wrong with combining multiple apps/automations to get the result you want.)
I got it working...
It runs (Sunset-20 to Sunrise+20)
It was about 75 degrees out last night (Above 60), so the bulb came on Bug Yellow. There is debate about proper color for bugs with LED's... Warm White might be better, but that is an experiment for another day.
Anyway, I got up around 3 AM for a nature call. The outside temp had dropped to about 55, and the light was bright White.
At 21 minutes after Surrise I watched the light go out completely.
This is cool.
3 Likes