ed6e91d52b
Tilføj condition til AI overvågning og 'der er nogen i indkørslen': skip notifikation hvis vacuum.roborock_s8_pro_ultra er cleaning/returning
24 lines
760 B
YAML
24 lines
760 B
YAML
- alias: 'AI overvågning'
|
|
trigger:
|
|
platform: state
|
|
entity_id: binary_sensor.indkorsel_sensor_motion
|
|
to: 'on'
|
|
conditions:
|
|
- condition: template
|
|
value_template: >-
|
|
{% set last = state_attr('automation.ai_overvagning', 'last_triggered') %}
|
|
{% set someone_home = is_state('binary_sensor.family_presence', 'on') %}
|
|
{{ not someone_home or last is none or (now() - last).total_seconds() > 900 }}
|
|
- condition: not
|
|
conditions:
|
|
- condition: state
|
|
entity_id: vacuum.roborock_s8_pro_ultra
|
|
state:
|
|
- cleaning
|
|
- returning
|
|
actions:
|
|
- action: script.overvaagning
|
|
metadata: {}
|
|
data: {}
|
|
mode: single
|