1
0
ansible-home-assistant/automations/files/vacuum.yaml

29 lines
678 B
YAML

- id: vacuum_leave
alias: '[Vacuum] Clean after leaving home'
trigger:
- platform: zone
entity_id: device_tracker.sm_g965f
zone: zone.home
event: leave
condition: []
action:
- service: vacuum.start
data: {}
entity_id: vacuum.robot_vacuum
mode: single
- id: vacuum_arive
alias: '[Vacuum] Stop cleaning after arrival'
trigger:
- platform: zone
entity_id: device_tracker.sm_g965f
zone: zone.home
event: enter
condition: []
action:
- service: vacuum.pause
entity_id: vacuum.robot_vacuum
- delay: '15'
- service: vacuum.return_to_base
entity_id: vacuum.robot_vacuum
mode: single