Files
HomeAssistant/scripts.yaml
T
2025-09-11 10:47:34 +03:00

27 lines
931 B
YAML

start_dishwasher_low_cost2:
alias: "Start Dishwasher at Low Cost Slot"
mode: single
max_exceeded: silent
sequence:
- condition: template
value_template: >
{{ states('sensor.404080542911000714_bsh_common_status_operationstate') in ['inactive','ready'] }}
- variables:
start_time: "{{ state_attr('binary_sensor.planner_low_cost','starts_at') }}"
# Convert to local time format that the select expects
start_time_formatted: "{{ as_timestamp(start_time) | timestamp_custom('%H:%M') }}"
- condition: template
value_template: "{{ start_time is not none }}"
# Set the absolute start time
- service: select.select_option
target:
entity_id: select.404080542911000714_bsh_common_option_startinrelative
data:
option: "4:00"
- service: button.press
target:
entity_id: button.404080542911000714_start_pause