1
0
ansible-home-assistant/configuration/automations/hallway-lock-button.yaml
Przemek Grondek fe0e59e313 Update hallway/front door automations
switch calling doorbell automation to async script call
 increase lights blinking to 10 seconds
 change doorbell prevention automation from delay to trigger requirement
 wait door close before locking door
 turn on/off hallway light on motion
2021-08-12 00:37:29 +02:00

42 lines
1.1 KiB
YAML

- id: hallway-front-door-button-lock
alias: '[Front Door] Button Lock'
trigger:
- device_id: d30d25752f5e6741eb8d9562f5b44897
domain: zha
platform: device
type: remote_button_short_press
subtype: turn_off
action:
- choose:
- conditions:
- condition: state
entity_id: binary_sensor.front_door_open_close
state: 'on'
sequence:
- wait_for_trigger:
- platform: state
entity_id: binary_sensor.front_door_open_close
to: 'off'
- service: lock.lock
target:
entity_id: lock.front_door_25f246fe_door_lock
- id: hallway-front-door-button-unlock
alias: '[Front Door] Button Unlock'
trigger:
- device_id: d30d25752f5e6741eb8d9562f5b44897
domain: zha
platform: device
type: remote_button_short_press
subtype: turn_on
condition:
- condition: not
conditions:
- condition: state
entity_id: input_select.home_mode
state: Away
action:
- service: lock.unlock
target:
entity_id: lock.front_door_25f246fe_door_lock