MeteoAlarm info card

check the card-mod thread, first post, link at the bottom and select the card you need to change.

its a generic thing you want to do, nothing special related to MeteoAlarm, so a good thing to check out

btw, if you’d want to translate the time and dates to your local language, I suggest you install custom_template Easy_time (find in on HACS) , set your default language in it and use things like:

      {% from 'easy_time.jinja' import weekday, month %}
      {% set meteo = 'binary_sensor.meteoalarm_brabant' %}

      {% set van = state_attr(meteo,'effective')|as_datetime|as_local %}
      {% set tot = state_attr(meteo,'expires')|as_datetime|as_local %}
      {% set gepubliceerd = state_attr(meteo,'onset')|as_datetime|as_local %}

      <b>Geldig:</b>

      <i>van: </i>{{weekday(van)}} {{van.day}} {{month(van)}} {{van.strftime('%H:%M')}}
      <i>tot: </i> {{weekday(tot)}} {{tot.day}} {{month(tot)}} {{tot.strftime('%H:%M')}}

      <b>Gepubliceerd:</b> {{weekday(gepubliceerd) ~' '~gepubliceerd.day~' '~month(gepubliceerd)~' om '~gepubliceerd.strftime('%H:%M') }}

Aware I use Onset in a wrong way, but that is besides the templating suggestion :wink:

1 Like