mirror of
https://github.com/CeeWeasel/fresh-home.git
synced 2026-08-09 10:30:14 -04:00
95 lines
2.5 KiB
YAML
95 lines
2.5 KiB
YAML
alias: Baby Monitor on TV
|
|
id: automation_baby_monitor_on_tv
|
|
|
|
trigger:
|
|
- platform: state
|
|
entity_id: binary_sensor.black_bed_occupied
|
|
to: "off"
|
|
for: "00:00:03"
|
|
- platform: state
|
|
entity_id: binary_sensor.white_bed_occupied
|
|
to: "off"
|
|
for: "00:00:03"
|
|
|
|
condition:
|
|
- condition: state
|
|
entity_id: input_boolean.home_occupied
|
|
state: "on"
|
|
- condition: state
|
|
entity_id: input_boolean.front_room_occupied
|
|
state: "on"
|
|
- condition: or
|
|
conditions:
|
|
- condition: state
|
|
entity_id: media_player.front_room_tv
|
|
state: "off"
|
|
- condition: state
|
|
entity_id: media_player.front_room_tv
|
|
state: "standby"
|
|
- condition: state
|
|
entity_id: input_boolean.computer_area_occupied
|
|
state: "off"
|
|
- condition: state
|
|
entity_id: binary_sensor.bed_presence_c175a4_bed_occupied_either
|
|
state: "off"
|
|
- condition: state
|
|
entity_id: binary_sensor.master_bedroom_occupied
|
|
state: "off"
|
|
- condition: state
|
|
entity_id: input_boolean.master_bedroom_occupied
|
|
state: "off"
|
|
- condition: state
|
|
entity_id: input_boolean.master_bedroom_asleep
|
|
state: "off"
|
|
- condition: or
|
|
conditions:
|
|
- condition: and
|
|
conditions:
|
|
- condition: state
|
|
entity_id: input_boolean.emmett_home
|
|
state: "on"
|
|
- condition: state
|
|
entity_id: input_boolean.emmett_in_bed
|
|
state: "on"
|
|
- condition: and
|
|
conditions:
|
|
- condition: state
|
|
entity_id: input_boolean.bridget_home
|
|
state: "on"
|
|
- condition: state
|
|
entity_id: input_boolean.bridget_in_bed
|
|
state: "on"
|
|
- condition: and
|
|
conditions:
|
|
- condition: state
|
|
entity_id: input_boolean.ebin_home
|
|
state: "on"
|
|
- condition: state
|
|
entity_id: input_boolean.ebin_in_bed
|
|
state: "on"
|
|
- condition: not
|
|
conditions:
|
|
- condition: state
|
|
entity_id: media_player.front_room_tv
|
|
state: playing
|
|
- condition: state
|
|
entity_id: media_player.front_room_tv
|
|
state: paused
|
|
- condition: state
|
|
entity_id: media_player.front_room_tv
|
|
attribute: source
|
|
state: "IP Camera Viewer - Pro"
|
|
|
|
action:
|
|
- choose:
|
|
- conditions:
|
|
- condition: state
|
|
entity_id: timer.nursery_camera_on_hub
|
|
state: "idle"
|
|
sequence:
|
|
- action: rest_command.nursery_on_roku_1
|
|
|
|
- action: timer.start
|
|
data:
|
|
entity_id: timer.nursery_camera_on_tv
|