What's New
- Timestamp timers: Now support duration/progress bar using a configurable
start_time_attr(template sensor recommended, see below and #35) - Expiry actions:
expire_action: keep,dismiss, orremovenow behave consistently for all timer types, and read-only timers now show a Dismiss button - Audio UX: New
audio_completion_delay(default 4s) ensures timer audio finishes before removal/dismissal (#36) - Docs: Expanded template sensor examples for timestamp timers, clearer Voice PE and entity config docs
Template Sensors for Timestamp Timers (Expanded)
To show a progress bar for a timestamp-based timer, you need both an end time (the entity state) and a valid start_time attribute.
Every device and integration is different - it's up to you to create the logic that accurately tracks the start_time and end_time for your needs.
Basic Example (two sensors):
template:
- sensor:
- name: "Dishwasher Timer"
state: "{{ states('sensor.dishwasher_finish') }}"
attributes:
start_time: "{{ states('sensor.dishwasher_start') }}"Advanced Example (trigger-based for Samsung Dryer I personally use):
template:
- trigger:
- platform: state
entity_id: sensor.dryer_status
to: 'running'
id: started
- platform: state
entity_id: sensor.dryer_dryer_completion_time
id: eta_changed
- platform: state
entity_id: sensor.dryer_status
from: 'running'
to: ~
id: stopped
sensor:
- name: Dryer Progress Timer
device_class: timestamp
state: >-
{% set eta = states('sensor.dryer_dryer_completion_time') %}
{% if eta in ['unknown','unavailable','none',''] %}
{{ this.state | default('') }}
{% else %}
{{ eta }}
{% endif %}
attributes:
start_time: >-
{% if trigger.id == 'started' %}
{{ now().isoformat() }}
{% elif trigger.id == 'eta_changed' %}
{{ this.attributes.start_time | default(now().isoformat()) }}
{% elif trigger.id == 'stopped' %}
{{ '' }}
{% else %}
{{ this.attributes.start_time | default('') }}
{% endif %}
availability: >-
{{ states('sensor.dryer_dryer_completion_time') not in ['unknown','unavailable','none',''] }}- Tip: Use triggers and conditions that match your device's actual cycle, so the
start_timeis set when the timer starts and cleared when it stops. - You must adapt this logic for your own device! Some integrations may have a simple
startandfinishsensor, others require more state tracking or template triggers.