diff --git a/automation/mealtime.yaml b/automation/mealtime.yaml index 18872132..55b5e7ac 100755 --- a/automation/mealtime.yaml +++ b/automation/mealtime.yaml @@ -1,17 +1,17 @@ -###################################################################### -## Time to eat - Set it up! -###################################################################### - -- alias: Mealtime - trigger: - - platform: event - event_type: mealtime - - action: - - service: light.turn_on - entity_id: - - group.dinette_lights - - group.kitchen_lights - - service: light.turn_off - entity_id: - - group.living_room_lights \ No newline at end of file +###################################################################### +## Time to eat - Set it up! +###################################################################### + +- alias: Meal Time + trigger: + - platform: event + event_type: mealtime + + action: + - service: light.turn_on + entity_id: + - group.dinette_lights + - group.kitchen_lights + - service: light.turn_off + entity_id: + - group.living_room_lights diff --git a/automation/tv_time_on_and_off.yaml b/automation/tv_time_on_and_off.yaml index c04d46fe..c360a1af 100755 --- a/automation/tv_time_on_and_off.yaml +++ b/automation/tv_time_on_and_off.yaml @@ -1,62 +1,62 @@ -###################################################################### -## TV Time at sunset or 8pm. Whichever is later. -###################################################################### - -- alias: TV Time - trigger: - - platform: sun - event: sunset - offset: '+01:00:00' - - platform: event - event_type: tv_time - - platform: state - entity_id: sensor.samsungtv - state: 'Online' - - platform: time - after: '20:00:00' - - condition: - condition: and - conditions: - - condition: state - entity_id: group.family - state: home - - condition: state - entity_id: sensor.samsungtv - state: 'Online' - - condition: state - entity_id: sun.sun - state: 'below_horizon' - - condition: state - entity_id: input_boolean.guest_mode - state: 'off' - - action: - service: scene.turn_on - entity_id: scene.living_room_tv_time - -###################################################################### -## Turn off the Living room lights when the TV is turned off. -###################################################################### - -- alias: TV Time off - trigger: - - platform: state - entity_id: sensor.samsungtv - state: 'Offline' - - condition: - condition: and - conditions: - - condition: state - entity_id: sun.sun - state: 'below_horizon' - - condition: state - entity_id: input_boolean.guest_mode - state: 'off' - - action: - service: light.turn_off - entity_id: - - group.living_room - - group.living_room_accents \ No newline at end of file +###################################################################### +## TV Time at sunset or 8pm. Whichever is later. +###################################################################### + +- alias: TV Time + trigger: + - platform: sun + event: sunset + offset: '+01:00:00' + - platform: event + event_type: tv_time + - platform: state + entity_id: sensor.samsungtv + state: 'Online' + - platform: time + after: '20:00:00' + + condition: + condition: and + conditions: + - condition: state + entity_id: group.family + state: home + - condition: state + entity_id: sensor.samsungtv + state: 'Online' + - condition: state + entity_id: sun.sun + state: 'below_horizon' + - condition: state + entity_id: input_boolean.guest_mode + state: 'off' + + action: + service: scene.turn_on + entity_id: scene.tv_time + +###################################################################### +## Turn off the Living room lights when the TV is turned off. +###################################################################### + +- alias: TV Time off + trigger: + - platform: state + entity_id: sensor.samsungtv + state: 'Offline' + + condition: + condition: and + conditions: + - condition: state + entity_id: sun.sun + state: 'below_horizon' + - condition: state + entity_id: input_boolean.guest_mode + state: 'off' + + action: + service: light.turn_off + entity_id: + - group.living_room + - group.living_room_accents