Hello everyone, I have been using home assistant for a while now, but now I want to automate my roof window blinds because it gets very hot in the storage room on warm, sunny days.
Up until now I used a simple automation that used the interior temperature as a trigger.
Which worked so far.
Now I have expanded my hardware and I am able to move the blinds individually to a desired position, which could now enable me to control a good balance between shading and sufficient light.
I would like to create a way to regulate the shading of the roof windows depending on the azimuth, so that, for example, there is no shading if the azimuth is below 128 and above 207 on March 18th.
I have already determined the values for the individual directions and days.
I was also able to limit these values in the template editor: azimuth within two values and date within two days, for example between July 1st and July 15th
{% set start = now().replace(day=1, month=7).date() %}
{% set end = now().replace(day=15, month=7).date() %}
{% set low, high = [start, end] | min, [start, end] | max %}
{% set current = low <= now().date() <= high %}
{{ not current if start > end else current }}
{{ states('sensor.sonne_solar_azimuth')|float >= 202 and states('sensor.sonne_solar_azimuth') | float < 308 }}
Here are the values I determined
My idea is that I will end up with 4 sensors, one each for north, east, south and west, which will give me true or false for the current day (now).
Example:
Wednesday July 3rd 3:30pm → south = true
because azimuth for south is between 51 and 207
I am still relatively inexperienced with home assistant automations using templates,
or creating a template sensor that gives me this result back, but unfortunately I am too inexperienced here too.