Files
fresh-home/automations/rooms/front_room/front_room_tv_playing.yaml
T
2025-10-10 20:24:52 -04:00

42 lines
1.0 KiB
YAML

alias: Front Room TV Playing
id: automation_front_room_tv_playing
trigger:
- platform: state
entity_id: media_player.front_room_tv
to: "playing"
condition:
- condition: state
entity_id: input_boolean.lighting_automations
state: "on"
- condition: state
entity_id: light.front_room_hue
state: "on"
- condition: state
entity_id: sun.sun
state: "below_horizon"
- condition: not
conditions:
- condition: state
entity_id: media_player.front_room_tv
attribute: "source"
state: "PBS KIDS"
- condition: state
entity_id: media_player.front_room_tv
attribute: "source"
state: "YouTube"
action:
- action: input_text.set_value
data_template:
entity_id: input_text.front_room_mode
value: "{{ states('input_select.front_room_mode') }}"
- action: input_select.select_option
data:
entity_id: input_select.front_room_mode
option: Dimmed
- action: automation.trigger
entity_id: automation.front_room_lights_to_on