mirror of
https://github.com/CCOSTAN/Home-AssistantConfig.git
synced 2025-08-18 03:15:45 +00:00
Closes #72 - Move IFTTT triggers locally to Input_booleans
This commit is contained in:
19
automation/flash_all.yaml
Executable file
19
automation/flash_all.yaml
Executable file
@@ -0,0 +1,19 @@
|
||||
######################################################################
|
||||
## Turn off my Office light whenever I leave the house.
|
||||
######################################################################
|
||||
- alias: 'Carlo has left the building'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: input_boolean.flash
|
||||
state: 'on'
|
||||
from: 'off'
|
||||
|
||||
action:
|
||||
- service: light.turn_on
|
||||
entity_id:
|
||||
- group.all_lights
|
||||
data:
|
||||
flash: long
|
||||
|
||||
- service: input_boolean.turn_off
|
||||
entity_id: input_boolean.flash
|
@@ -4,8 +4,10 @@
|
||||
|
||||
- alias: 'Good Morning Routine'
|
||||
trigger:
|
||||
- platform: event
|
||||
event_type: good_morning
|
||||
- platform: state
|
||||
entity_id: input_boolean.good_morning
|
||||
state: 'on'
|
||||
from: 'off'
|
||||
- platform: state
|
||||
entity_id:
|
||||
- binary_sensor.sleepnumber_carlo_stacey_is_in_bed
|
||||
@@ -38,3 +40,5 @@
|
||||
- delay: 00:01:00
|
||||
- service: switch.turn_on
|
||||
entity_id: switch.kitchen_accents
|
||||
- service: input_boolean.turn_off
|
||||
entity_id: input_boolean.good_morning
|
||||
|
@@ -4,8 +4,10 @@
|
||||
|
||||
- alias: 'Good Night Trigger'
|
||||
trigger:
|
||||
- platform: event
|
||||
event_type: good_night
|
||||
- platform: state
|
||||
entity_id: input_boolean.good_night
|
||||
state: 'on'
|
||||
from: 'off'
|
||||
- platform: state
|
||||
entity_id:
|
||||
- binary_sensor.sleepnumber_carlo_carlo_is_in_bed
|
||||
@@ -27,6 +29,9 @@
|
||||
state: 'on'
|
||||
|
||||
action:
|
||||
- service: input_boolean.turn_off
|
||||
entity_id: input_boolean.good_night
|
||||
|
||||
- service: script.Voice_notify
|
||||
data_template:
|
||||
value1: >
|
||||
|
@@ -4,8 +4,10 @@
|
||||
|
||||
- alias: Meal Time
|
||||
trigger:
|
||||
- platform: event
|
||||
event_type: mealtime
|
||||
- platform: state
|
||||
entity_id: input_boolean.meal_time
|
||||
state: 'on'
|
||||
from: 'off'
|
||||
|
||||
action:
|
||||
- service: light.turn_on
|
||||
@@ -15,3 +17,5 @@
|
||||
- service: light.turn_off
|
||||
entity_id:
|
||||
- group.living_room_lights
|
||||
- service: input_boolean.turn_off
|
||||
entity_id: input_boolean.meal_time
|
||||
|
@@ -7,8 +7,10 @@
|
||||
- platform: sun
|
||||
event: sunset
|
||||
offset: '+01:00:00'
|
||||
- platform: event
|
||||
event_type: tv_time
|
||||
- platform: state
|
||||
entity_id: input_boolean.TV_time
|
||||
state: 'on'
|
||||
from: 'off'
|
||||
- platform: state
|
||||
entity_id: sensor.samsungtv
|
||||
state: 'Online'
|
||||
@@ -32,8 +34,10 @@
|
||||
state: 'off'
|
||||
|
||||
action:
|
||||
service: scene.turn_on
|
||||
- service: scene.turn_on
|
||||
entity_id: scene.tv_time
|
||||
- service: input_boolean.turn_off
|
||||
entity_id: input_boolean.tv_time
|
||||
|
||||
######################################################################
|
||||
## Turn off the Living room lights when the TV is turned off.
|
||||
|
@@ -4,8 +4,10 @@
|
||||
|
||||
- alias: Time to Work
|
||||
trigger:
|
||||
- platform: event
|
||||
event_type: work
|
||||
- platform: state
|
||||
entity_id: input_boolean.work
|
||||
state: 'on'
|
||||
from: 'off'
|
||||
|
||||
action:
|
||||
- service: light.turn_off
|
||||
@@ -16,3 +18,5 @@
|
||||
- service: light.turn_on
|
||||
entity_id:
|
||||
- light.office_lamp
|
||||
- service: input_boolean.turn_off
|
||||
entity_id: input_boolean.work
|
||||
|
24
input_boolean/trigger_booleans.yaml
Executable file
24
input_boolean/trigger_booleans.yaml
Executable file
@@ -0,0 +1,24 @@
|
||||
#triggers
|
||||
good_night:
|
||||
name: Good Night
|
||||
initial: off
|
||||
|
||||
good_morning:
|
||||
name: Good Morning
|
||||
initial: off
|
||||
|
||||
meal_time:
|
||||
name: Meal Time
|
||||
initial: off
|
||||
|
||||
tv_time:
|
||||
name: TV Time
|
||||
initial: off
|
||||
|
||||
work:
|
||||
name: Work
|
||||
initial: off
|
||||
|
||||
flash:
|
||||
name: Flash
|
||||
initial: off
|
Reference in New Issue
Block a user