Hi. Ive found the wind speed using the attribute wind_speed, but cant seem to extract the direction. It shows when you look at the sensor and gives the future forecast, but i cant figure out how to get the wind speed and cant find any reference to it on here or elsewhere online.
There you go... place in your config.yaml and it will refresh every 15mins. Change the [0] but to [1] for tomorrow etc.
- trigger:
- platform: time_pattern
minutes: /15
- platform: homeassistant
event: start
action:
- service: weather.get_forecasts
target:
entity_id: weather.forecast_home
data:
type: hourly
response_variable: hourly
sensor:
- name: Wind Speed
unique_id: hourly_wind_speed
state: "{{ hourly['weather.forecast_home'].forecast[0].wind_speed }}"
- name: Wind Direction
unique_id: hourly_wind_direction
state: "{{ hourly['weather.forecast_home'].forecast[0].wind_bearing }}"
1 Like
Perfect thanks. I had tried every combination but hadnt thought of Wind Bearing!