pnbruckner/ha-sun2

Add azimuth_at_time and time_at_azimuth sensor

Closed this issue · 5 comments

Hi,
I've just discovered this useful component, but I've seen it misses sensors like "azimut_at_time" and "time_at_azimuth" that could be useful as same as their existing equivalent related to elevation.

Hope this will be implemented 😃

azimuth_at_time should be easy enough, but not sure about the opposite. Can you describe what you see as the use case for these?

Azimuth_at_time is probably the one I have an use case for: having some bedroom’s covers at NE, I would change their close position during the year when the sun hit them at early morning.

so with new method I can do things like:

If azimuth_at_time(sunrise_or_dawn_datetime_or_timestamp)<90:
  Close position=5
Else:
  Close position=20

With value 90 (it’s an example) identified from online sun calculators site, using same time format existing for elevation.

thanks.

I've already added azimuth sensors for sunrise & sunset. See https://github.com/pnbruckner/ha-sun2/releases/tag/3.3.0b1

I've already added azimuth sensors for sunrise & sunset. See https://github.com/pnbruckner/ha-sun2/releases/tag/3.3.0b1

good to know, I'm on 3.2.1 so I didn't see them, waiting for next release 👍

Rising & setting azimuth sensors have been added. The time_at_azimuth sensor will probably not be easy to implement. Since neither that, nor azimuth_at_time for other times, seem to be "in demand", I'm going to close. But if anyone feels strongly that either are useful and needed, I could reconsider.