I have rflink switch. I want to turn it off after xx seconds. It is motion sensor which send only ON signal. I created automation but it doesn´t run. Could anybody help?
Using automation editor inside HA this automation.yaml was created:
- action:
- delay: 0:10
- alias: ‘’
data:
entity_id: switch.senzor_pohybu_1
service: switch.turn_off
alias: off cidla
condition:
- condition: state
entity_id: switch.senzor_pohybu_1
state: ‘on’
id: ‘1510082561392’
trigger:
- entity_id: switch.senzor_pohybu_1
from: ‘on’
platform: state
to: ‘off’
###############################################################################################
# #
# Turn off the PIR's once they have triggered #
# #
###############################################################################################
- alias: 'Turn off PIRs'
initial_state: 'on'
trigger:
- platform: state
entity_id: switch.senzor_pohybu_1
to: 'on'
action:
- delay: '00:00:10'
- service: switch.turn_off
entity_id: switch.senzor_pohybu_1
@keithh666 If I want to trigger sirene or send push message to phone could I do it using your automatization - only add another “action:” ? I want to do it with the same trigger.