I did create the last_called sensor and also added 0.5 delay before the update_last_called and before the notify.alexa_media_last_called which did seem to help and yes they are the older echoes without the cloth so maybe that was why.
action:
- delay:
seconds: 0.5
- service: alexa_media.update_last_called
- delay:
seconds: 0.5
- service: notify.alexa_media_last_called
data:
message: >-
{% if (state_attr('light.dialog', 'brightness') | int / 255 * 100 ) | int == 10 %}
The battery is currently at {{ states('sensor.solar_battery_soc') }} percent
{% elif (state_attr('light.dialog', 'brightness') | int / 255 * 100 ) | int == 20 %}
The EV battery is currently at {{ states('sensor.charging_level_hv') }} percent
{% elif (state_attr('light.dialog', 'brightness') | int / 255 * 100 ) | int == 30 %}
The electric range is {{ states('sensor.remaining_range_electric') }} kilometers
{% else %}
There is no routine set up for that value.
{% endif %}
data:
type: tts
- service: light.turn_off
entity_id: light.dialog
I have also added two more routines but for some reason this one doesn’t work {% elif (state_attr('light.dialog', 'brightness') | int / 255 * 100 ) | int == 30 %}
keeps going down to the there is no routine set up bit and I have no idea why, the brightness is set to 30 in the routine itself.
Can anyone spot anything incorrect (the value of that sensor is 0 at this moment)