#Sun automations, between certain time possible?

1 messages · Page 1 of 1 (latest)

fleet isle
#

Only execute the automation if the sun is an hour before sundown and at sundown.
Is something like that possible, i dont see it easily in the documentation.

warm bay
#

Add condition -> Time and Location -> Sun

fleet isle
# warm bay

Yes, then it executes after sun dawn and an hour before sunset

#

What about it should execute an hour before sunset and sunset?

warm bay
#

It's right there. Select "before" and add -01:00:00 as the offset.

#

Offsets can be in either direction. So an hour after would be +01:00:00 and an hour before would be -01:00:00

fleet isle
#

But then the condition is "after sundawn, before sunset minus 1h.

It can execute in a super large timeframe.

#

Im talking about a timespan of just 1 hour when the automation can execute

warm bay
#

What is your exact condition you want?

fleet isle
#

I could make a binary switch that executes an hour before sunset. But thats complicated

warm bay
#

If it's either an hour before or an hour after?

fleet isle
warm bay
#

Then use the sun as the trigger, and check brightness.

lilac palm
#

after an hour before sunset and before sunset

#
conditions:

  - condition: sun
    after: sunset
    after_offset: "-01:00:00"
  - condition: sun
    before: sunset
#

use whatever trigger you want but that will ensure the automation only fires between the hour before sunset

warm bay
#

That looks a bit redundant to me..

lilac palm
#

how

#

it's literally the time between an hour before sunset and sunset

warm bay
#

Breaks my logic train. But maybe I'm just seeing something weird that is t there.

lilac palm
#

it might need a +1 instead of -1

fleet isle
lilac palm
#

just checked docs, hour before sunset is -1

fleet isle
#

Yeah i knew, thanks. I use sun in a lot, just didnt have to do this specific hour yet

#

In my head making it double, would clash with each other and then would not function at all