1
0
ansible-home-assistant/automations/bathroom-motion.yaml

51 lines
1.2 KiB
YAML
Raw Normal View History

2021-01-11 00:33:46 +00:00
- id: bathroom-motion-day
alias: '[Bathroom] Motion Day'
2020-12-29 18:33:16 +00:00
mode: restart
trigger:
- platform: state
2021-05-06 23:03:19 +00:00
entity_id: binary_sensor.bathroom_motion_occupancy
2020-12-29 18:33:16 +00:00
from: 'off'
to: 'on'
2021-01-11 00:33:46 +00:00
condition:
- condition: state
entity_id: input_select.home_mode
state: Day
action:
- service: light.turn_on
entity_id: light.bathroom_lights
data:
brightness_pct: 100
kelvin: 3200
2021-01-11 00:33:46 +00:00
- id: bathroom-motion-night
alias: '[Bathroom] Motion Night'
mode: restart
trigger:
- platform: state
2021-05-06 23:03:19 +00:00
entity_id: binary_sensor.bathroom_motion_occupancy
2021-01-11 00:33:46 +00:00
from: 'off'
to: 'on'
condition:
- condition: state
entity_id: input_select.home_mode
state: Night
action:
- service: light.turn_on
entity_id: light.bathroom_lights
data:
brightness_pct: 5
2021-01-12 23:00:32 +00:00
kelvin: 2700
2020-12-29 18:33:16 +00:00
- id: bathroom-motion-off
2021-01-07 00:48:14 +00:00
alias: '[Bathroom] Motion Off'
2020-12-29 18:33:16 +00:00
mode: restart
trigger:
- platform: state
2021-05-06 23:03:19 +00:00
entity_id: binary_sensor.bathroom_motion_occupancy
2021-04-12 15:32:28 +00:00
for: '0:05:00'
2020-12-29 18:33:16 +00:00
from: 'on'
to: 'off'
action:
- service: light.turn_off
entity_id:
- light.bathroom_lights
- light.bathroom_mirror_lights