Lovelace Windrose Card

Released version 1.23.4

Fixes:

  • Auto text color switching when light/dark theme switches automatically. Refresh was needed before. Thanks @Ainndy. Fixes #153.

Released version 1.23.5

Fixes:

  • Current wind direction center circle is now drawn on top.
  • Current wind direction hide_direction_below_speed option was not working in some cases because the direction was not updated when the speed changes.
  • Improved efficiency during card start up.
1 Like

Released version 1.24.0

Feature:

  • Added auto option for rose percentage text color, this is also the default.
    The text color depends on the background, making the text more readable when a windrose leave is the text background.
1 Like

Released version 1.25.0

Feature:

  • Add text above and below the windrose with entity states or specific values about the data used for the windrose.

For details see the readme on GitHub.

Example:

5 Likes

Released version 1.25.1

  • Fix problem: Multiple background image elements added to HTML, when using period buttons. Thanks @mickut
2 Likes

Hi! I am using your Windrose Card since about two years and love it very much! Thank you so much for your work. :heart_eyes:

I am wondering if you could create a similar card for lightnings. There are sources like https://blitzortung.org which already can be used within Home Assistant.
There is some information like

  • what was the distance to a lightning
  • when did it happen
  • what was the direction

I think about a configurable card showing all lightnings within maybe the last hour and within a distance of maybe 100km. It would be interesting then to see how often there are lightnings from any direction and how far they are.

What do you think? Isn’t this similar to the Windrose card?

Thank you in advance

Ruediger

2 Likes

Hi Ruediger,

Other people used this card to display lightning data.

See these GitHub issues:

An other sort of circular graph with distance from centre and color intensity indicating how long ago the lighting happened, would be better for lightning data.

I don’t have the time the make something like that, maybe in the future. You can add an issue in GitHub, I’ll give it the ‘new card request’ label.
Someone else requested a compass card, maybe this could be a feature of a more advanced compass card.

Thanks for using windrose-card.

Auke

1 Like

I would like to have this as a sample configuration. Thx!

Here’s a starting block with mine:
You will need to modify the sensor entities, and change other styling variables.
You can remove the corner entity values (e.g. Current knots in bottom left) without messing up the code else-where.
Changing the wind direction from NOZWX may be required if your weather station has a precise bearing direction in degrees (rather than mine for only 8 segments).

Do check with the GitHub table of variables. It is very helpful.

type: custom:windrose-card
title: Wind
data_period:
  period_selector:
    location: bottom
    active_color: black
    active_bg_color: white
    log_measurement_counts: true
    buttons:
      - hours: 1
        title: 1 hour
      - hours: 2
        title: 2 hour
      - hours: 6
        title: 6 hour
      - hours: 12
        title: 12 hours
      - hours: 24
        title: 1 day
        active: true
      - hours: 240
        title: 10 days
refresh_interval: 30
windspeed_bar_location: bottom
wind_direction_entity:
  entity: sensor.weather_station_esp32_station_wind_direction_bearing
  use_statistics: false
  direction_compensation: 0
  direction_letters: NOZWX
windspeed_entities:
  - entity: sensor.weather_station_esp32_station_wind_speed
    name: Speed
    speed_unit: false
    use_statistics: true
    windspeed_bar_full: false
    output_speed_unit: kph
    speed_range_beaufort: false
  - entity: sensor.weather_station_esp32_station_wind_gust
    name: Gust
    speed_unit: false
    use_statistics: false
    windspeed_bar_full: false
    output_speed_unit: kph
    speed_range_beaufort: false
windrose_draw_north_offset: 0
current_direction:
  show_arrow: true
  arrow_size: 100
  center_circle_size: 30
corner_info:
  top_left:
    label: Current average speed
    unit: " km/h"
    entity: sensor.weather_station_esp32_station_wind_speed
    label_text_size: 50
    value_text_size: 50
    input_unit: kph
    output_unit: kph
    precision: 1
  top_right:
    label: Wind direction
    unit: °
    color: white
    entity: sensor.weather_station_esp32_station_wind_direction_bearing
    input_unit: degrees
    output_unit: letters
  bottom_left:

1 Like

Here’s another example with the code for mine (not very windy so I have two screen snapshots):

type: custom:windrose-card
title: Wind Direction & Speed
circle_legend_text_size: 40
data_period:
  period_selector:
    buttons:
      - hours: 1
        title: 1 hr
      - hours: 8
        title: 8 hrs
      - hours: 16
        title: 16 hrs
      - hours: 20
        title: 20 hrs
      - hours: 24
        title: 24 hrs
      - hours: 48
        title: 48 hrs
refresh_interval: 300
windspeed_bar_location: bottom
windspeed_bar_full: true
wind_direction_entity:
  entity: sensor.ridgewood_estate_personal_weather_station_wind_dir
  use_statistics: false
  direction_compensation: 0
  direction_letters: NESWX
windspeed_entities:
  - entity: sensor.ridgewood_estate_personal_weather_station_wind_speed
    current_speed_arrow_location: below
    name: Speed
    speed_unit: mph
    output_speed_unit: mph
    speed_range_beaufort: false
    use_statistics: false
    windspeed_bar_full: true
    current_speed_arrow: true
    speed_ranges:
      - from_value: 0
        color: rgb(0,160,0)
      - from_value: 5
        color: rgb(0,140,0)
      - from_value: 10
        color: yellow
      - from_value: 20
        color: hsl(200, 100%, 60%)
      - from_value: 30
        color: hsl(200, 100%, 40%)
      - from_value: 40
        color: red
  - entity: sensor.ridgewood_estate_personal_weather_station_wind_gust
    current_speed_arrow_location: below
    name: Gust Speed
    speed_unit: mph
    output_speed_unit: mph
    speed_range_beaufort: false
    use_statistics: false
    windspeed_bar_full: true
    current_speed_arrow: true
    speed_ranges:
      - from_value: 0
        color: rgb(0,160,0)
      - from_value: 5
        color: rgb(0,140,0)
      - from_value: 10
        color: yellow
      - from_value: 20
        color: hsl(200, 100%, 60%)
      - from_value: 30
        color: hsl(200, 100%, 40%)
      - from_value: 40
        color: red
windrose_draw_north_offset: 0
current_direction:
  show_arrow: true
  arrow_size: 60
  center_circle_size: 30
compass_direction:
  auto_rotate: false
  entity: input_number.compass
corner_info:
  top_left:
    label: Speed
    unit: " MPH"
    entity: sensor.ridgewood_estate_personal_weather_station_wind_speed
    label_text_size: 60
    value_text_size: 40
    input_unit: mph
    output_unit: mph
    precision: 2
  top_right:
    label: Direction
    color: white
    entity: sensor.ridgewood_estate_personal_weather_station_wind_dir
    label_text_size: 60
    value_text_size: 40
    input_unit: degrees
    output_unit: letters
  bottom_left:
    label: null
    unit: " MPH Gust"
    color: white
    entity: sensor.ridgewood_estate_personal_weather_station_wind_gust
    label_text_size: 60
    value_text_size: 40
    input_unit: mph
    output_unit: mph
direction_labels:
  cardinal_direction_letters: NESW
  show_cardinal_directions: true
  show_intercardinal_directions: true
  show_secondary_intercardinal_directions: true
  cardinal_directions_text_size: 60
  intercardinal_directions_text_size: 0
  secondary_intercardinal_directions_text_size: 0
  center_calm_percentage: true
colors:
  rose_lines: rgb(255,255,255)
  rose_cardinal_direction_labels: orange
  rose_intercardinal_direction_labels: purple
  rose_secondary_intercardinal_direction_labels: yellow
  rose_center_percentage: white
  rose_percentages: white
  rose_current_direction_arrow: red
  bar_border: hsl(200, 100%, 60%)
  bar_unit_name: white
  bar_name: white
  bar_unit_values: white
  bar_percentages: auto

1 Like

Code for my two cards in a horizontal stack. One for gusts and one for prevailing.

                - type: custom:windrose-card
                  title: null
                  data_period:
                    hours_to_show: 24
                  max_width: 400
                  refresh_interval: 300
                  windspeed_bar_location: right
                  wind_direction_entity:
                    entity: sensor.netatmo_devonport_tas_indoor_wind_gust_angle
                    direction_unit: degrees
                    use_statistics: false
                    direction_compensation: 0
                  windspeed_entities:
                    - entity: sensor.netatmo_devonport_tas_indoor_wind_gust_strength
                      name: Wind Gust
                      speed_unit: kph
                      use_statistics: false
                      render_relative_scale: true
                      speed_range_beaufort: false
                      output_speed_unit: kph
                      windspeed_bar_full: false
                      current_speed_arrow: true
                      current_speed_arrow_location: right
                  corner_info:
                    top_left:
                      label: Current Wind Gust
                      unit: ' kph'
                      entity: sensor.netatmo_devonport_tas_indoor_wind_gust_strength
                    top_right:
                      label: Gust Direction
                      unit: °
                      color: red
                      entity: sensor.netatmo_devonport_tas_indoor_wind_gust_angle
                  windrose_draw_north_offset: 0
                  matching_strategy: time-frame
                  center_calm_percentage: false
                  direction_labels:
                    cardinal_direction_letters: NESW
                    show_cardinal_directions: true
                    show_intercardinal_directions: true
                    show_secondary_intercardinal_directions: true
                  current_direction:
                    show_arrow: true
                - type: custom:windrose-card
                  title: null
                  data_period:
                    hours_to_show: 24
                  max_width: 400
                  refresh_interval: 300
                  windspeed_bar_location: right
                  wind_direction_entity:
                    entity: sensor.netatmo_wind_wind_angle
                    direction_unit: degrees
                    use_statistics: false
                    direction_compensation: 0
                  windspeed_entities:
                    - entity: sensor.netatmo_devonport_tas_indoor_wind_wind_strength
                      name: Wind Gust
                      speed_unit: kph
                      use_statistics: false
                      render_relative_scale: true
                      speed_range_beaufort: false
                      output_speed_unit: kph
                      windspeed_bar_full: false
                      current_speed_arrow: true
                      current_speed_arrow_location: right
                  corner_info:
                    top_left:
                      label: Current Prevailing
                      unit: ' kph'
                      entity: sensor.netatmo_devonport_tas_indoor_wind_wind_strength
                    top_right:
                      label: Wind Direction
                      unit: °
                      color: red
                      entity: sensor.netatmo_wind_wind_angle
                  windrose_draw_north_offset: 0
                  matching_strategy: time-frame
                  center_calm_percentage: false
                  direction_labels:
                    cardinal_direction_letters: NESW
                    show_cardinal_directions: true
                    show_intercardinal_directions: true
                    show_secondary_intercardinal_directions: true
                  current_direction:
                    show_arrow: true
1 Like

Released version 1.26.0

First, I opened a new topic here, asking you to share your windrose card configuration.
More info here: Lovelace Windrose Card - examples configurations please

New features:

  • Added time period option, from hours ago to a hours ago.
  • Added statistics to be used in text blocks:
    • median-speed
    • q1-speed
    • q3-speed
    • iqr-range
    • p90-speed
    • wind-description

Fixes:

  • Rounding of speed values in the windbar.

All credits go to David Marton, thanks for your work!

Released version 1.26.1

Fixes:

  • When current speed arrow is disabled, the current direction arrow did not work. Fixed. Thanks @rocket
2 Likes

Hi, many thanks for work so far. Any chance of adding the possibility of a button to toggle the windspeed entity from wind to gust