Hello everyone,
I’m trying to create an automation in which the forecast for the temperature of the next 12 hours is read from met.no. An average should be formed from these values. If this value is above a value x (helper), a switch should be flipped.
The background is that I want to use either with the radiator or with the air conditioning. This should be determined twice a day based on the outside temperature.
This is similar to what I’ve been looking for as well - I want to calculate the average temp forecast for the next 3 hours. I’ve figured out the following, although it’s a little clunky. I haven’t worked it into anything useful yet. So far I’ve just been playing around with a script that creates a persistent notification so I can see the output immediately.
I’m not a templating wizard, so there’s likely a better way to do this but for what it’s worth…
I called the weather.get_forecasts service for the ‘weather.church_st’ entity, forecast type of Hourly and the response variable ‘forecast_var’
Then I used the following template in the persistent notification action: