55 lines
1.7 KiB
YAML
55 lines
1.7 KiB
YAML
vacuum_today:
|
|
alias: Vacuum only once
|
|
sequence:
|
|
- choose:
|
|
- conditions:
|
|
- condition: state
|
|
entity_id: input_boolean.today_vacuumed
|
|
state: 'off'
|
|
sequence:
|
|
- choose:
|
|
- conditions:
|
|
- condition: or
|
|
conditions:
|
|
- condition: state
|
|
entity_id: alarm_control_panel.ha_alarm
|
|
state: 'armed_away'
|
|
- condition: state
|
|
entity_id: alarm_control_panel.ha_alarm
|
|
state: 'arming'
|
|
sequence:
|
|
- service: alarm_control_panel.alarm_arm_night
|
|
entity_id: alarm_control_panel.ha_alarm
|
|
- service: vacuum.start
|
|
entity_id: vacuum.valetudo_valetudos5
|
|
|
|
vacuum_goto_bin:
|
|
alias: Vacuum go to bin
|
|
sequence:
|
|
- service: mqtt.publish
|
|
data:
|
|
topic: valetudo/ValetudoS5/GoToLocationCapability/go/set
|
|
payload: 55609b09-2d32-4f52-b939-94363172256d
|
|
|
|
vacuum_clean_segments:
|
|
alias: Vacuum clean segments
|
|
sequence:
|
|
- service: script.turn_on
|
|
target:
|
|
entity_id: script.vacuum_clean_segments_message
|
|
data:
|
|
variables:
|
|
segments: '{{expand("group.vacuum_rooms") | selectattr("state","eq","on")
|
|
| map(attribute="attributes.room_id") | list | to_json}}'
|
|
mode: single
|
|
icon: mdi:arrow-right
|
|
|
|
vacuum_clean_segments_message:
|
|
alias: Vacuum clean segments message
|
|
sequence:
|
|
- service: mqtt.publish
|
|
data:
|
|
topic: valetudo/ValetudoS5/MapSegmentationCapability/clean/set
|
|
payload_template: '{"segment_ids": {{segments}}}'
|
|
mode: single
|