2019-04-17 22:46:06 +00:00
|
|
|
###############################################################################
|
|
|
|
# @author : Mahasri Kalavala
|
|
|
|
# @date : 04/15/2017
|
2019-12-20 15:32:28 +00:00
|
|
|
# @package : Daily Light Routine around the house
|
2019-04-17 22:46:06 +00:00
|
|
|
# @description : Daily light routine stuff
|
|
|
|
###############################################################################
|
|
|
|
|
|
|
|
automation:
|
2019-12-20 15:32:28 +00:00
|
|
|
# ÛÛÛÛÛÛ ÛÛÛÛÛÛ ÛÛÛ
|
|
|
|
# °°ÛÛÛÛÛÛ ÛÛÛÛÛÛ °°°
|
|
|
|
# °ÛÛÛ°ÛÛÛÛÛ°ÛÛÛ ÛÛÛÛÛÛ ÛÛÛÛÛÛÛÛ ÛÛÛÛÛÛÛÛ ÛÛÛÛ ÛÛÛÛÛÛÛÛ ÛÛÛÛÛÛÛ
|
|
|
|
# °ÛÛÛ°°ÛÛÛ °ÛÛÛ ÛÛÛ°°ÛÛÛ°°ÛÛÛ°°ÛÛÛ°°ÛÛÛ°°ÛÛÛ °°ÛÛÛ °°ÛÛÛ°°ÛÛÛ ÛÛÛ°°ÛÛÛ
|
|
|
|
# °ÛÛÛ °°° °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °°° °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ
|
|
|
|
# °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ
|
|
|
|
# ÛÛÛÛÛ ÛÛÛÛÛ°°ÛÛÛÛÛÛ ÛÛÛÛÛ ÛÛÛÛ ÛÛÛÛÛ ÛÛÛÛÛ ÛÛÛÛ ÛÛÛÛÛ°°ÛÛÛÛÛÛÛ
|
|
|
|
# °°°°° °°°°° °°°°°° °°°°° °°°° °°°°° °°°°° °°°° °°°°° °°°°°ÛÛÛ
|
|
|
|
# ÛÛÛ °ÛÛÛ
|
|
|
|
# °°ÛÛÛÛÛÛ
|
|
|
|
# °°°°°°
|
|
|
|
###############################################################################
|
|
|
|
# Turn Indoor lights ON only during weekdays
|
|
|
|
###############################################################################
|
2019-04-17 22:46:06 +00:00
|
|
|
- alias: Morning Indoor Lights ON
|
|
|
|
initial_state: true
|
|
|
|
trigger:
|
|
|
|
platform: time_pattern
|
2019-12-20 15:32:28 +00:00
|
|
|
minutes: "/5"
|
2019-04-17 22:46:06 +00:00
|
|
|
seconds: 00
|
|
|
|
condition:
|
|
|
|
- condition: state
|
2019-12-20 15:32:28 +00:00
|
|
|
entity_id: "binary_sensor.workday_sensor"
|
|
|
|
state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: template
|
2019-12-20 15:32:28 +00:00
|
|
|
value_template: "{{ states('sensor.wakeup_hour') |int == now().hour |int }}"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: template
|
2019-12-20 15:32:28 +00:00
|
|
|
value_template: "{{ states('sensor.wakeup_minute') |int == now().minute|int }}"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: state
|
|
|
|
entity_id: input_boolean.light_automations
|
2019-12-20 15:32:28 +00:00
|
|
|
state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
action:
|
|
|
|
- service: switch.turn_on
|
|
|
|
data:
|
2022-11-30 00:50:52 +00:00
|
|
|
entity_id: switch.kitchen_switch
|
2019-04-17 22:46:06 +00:00
|
|
|
|
2019-12-20 15:32:28 +00:00
|
|
|
###############################################################################
|
|
|
|
# Turn ON Master Bedroom lights ON in the morning
|
|
|
|
# Turn On Bedroom Lights 10 minutes after wake up time
|
|
|
|
###############################################################################
|
2019-04-17 22:46:06 +00:00
|
|
|
- alias: Morning Master Bedroom Lights ON (Mallika)
|
|
|
|
initial_state: true
|
|
|
|
trigger:
|
|
|
|
platform: time_pattern
|
2019-12-20 15:32:28 +00:00
|
|
|
minutes: "/5"
|
2019-04-17 22:46:06 +00:00
|
|
|
seconds: 00
|
|
|
|
condition:
|
|
|
|
- condition: state
|
2019-12-20 15:32:28 +00:00
|
|
|
entity_id: "binary_sensor.workday_sensor"
|
|
|
|
state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: template
|
2019-12-20 15:32:28 +00:00
|
|
|
value_template: "{{ states('sensor.wakeup_hour') |int == now().hour|int }}"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: template
|
2019-12-20 15:32:28 +00:00
|
|
|
value_template: "{{ now().minute | int == (states('sensor.wakeup_minute') | int + 10) }}"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: state
|
|
|
|
entity_id: input_boolean.light_automations
|
2019-12-20 15:32:28 +00:00
|
|
|
state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
action:
|
|
|
|
- service: light.turn_on
|
|
|
|
data:
|
|
|
|
entity_id: light.master_bedroom_2
|
|
|
|
transition: 15
|
|
|
|
brightness: 25
|
|
|
|
color_temp: 154
|
2022-11-30 00:50:52 +00:00
|
|
|
- service: switch.turn_on
|
|
|
|
data:
|
|
|
|
entity_id: switch.chromecast_monitor
|
2019-04-17 22:46:06 +00:00
|
|
|
|
|
|
|
- alias: Morning Master Bedroom Lights OFF (Mallika)
|
|
|
|
initial_state: true
|
|
|
|
trigger:
|
|
|
|
platform: time_pattern
|
2019-12-20 15:32:28 +00:00
|
|
|
minutes: "/5"
|
2019-04-17 22:46:06 +00:00
|
|
|
seconds: 00
|
|
|
|
condition:
|
|
|
|
- condition: state
|
2019-12-20 15:32:28 +00:00
|
|
|
entity_id: "binary_sensor.workday_sensor"
|
|
|
|
state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: template
|
2019-12-20 15:32:28 +00:00
|
|
|
value_template: "{{ states('sensor.wakeup_hour') |int == now().hour|int }}"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: template
|
2019-12-20 15:32:28 +00:00
|
|
|
value_template: "{{ now().minute|int == (states('sensor.wakeup_minute') |int + 15) }}"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: state
|
|
|
|
entity_id: input_boolean.light_automations
|
2019-12-20 15:32:28 +00:00
|
|
|
state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
action:
|
|
|
|
- service: light.turn_off
|
|
|
|
data:
|
|
|
|
entity_id: light.master_bedroom_2
|
|
|
|
|
2019-12-20 15:32:28 +00:00
|
|
|
###############################################################################
|
|
|
|
# Turn off outdoor lights 15 minutes after sunrise
|
|
|
|
###############################################################################
|
2019-04-17 22:46:06 +00:00
|
|
|
- alias: Morning Outdoor Lights OFF
|
|
|
|
initial_state: true
|
|
|
|
trigger:
|
|
|
|
platform: sun
|
|
|
|
event: sunrise
|
2019-12-20 15:32:28 +00:00
|
|
|
offset: "00:15:00"
|
2019-04-17 22:46:06 +00:00
|
|
|
condition:
|
|
|
|
- condition: state
|
|
|
|
entity_id: input_boolean.light_automations
|
2019-12-20 15:32:28 +00:00
|
|
|
state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
action:
|
|
|
|
- service: switch.turn_off
|
2021-01-10 23:15:03 +00:00
|
|
|
entity_id: switch.frontyard_light
|
2019-04-17 22:46:06 +00:00
|
|
|
- service: switch.turn_off
|
2021-01-10 23:15:03 +00:00
|
|
|
entity_id: switch.backyard_light
|
2019-04-17 22:46:06 +00:00
|
|
|
|
2019-12-20 15:32:28 +00:00
|
|
|
###############################################################################
|
|
|
|
# Turn OF Kitchen Lights after 3 hours of wake up time during school/work days
|
|
|
|
###############################################################################
|
2019-04-17 22:46:06 +00:00
|
|
|
- alias: Morning Kitchen Light OFF
|
|
|
|
initial_state: true
|
|
|
|
trigger:
|
|
|
|
platform: time_pattern
|
2019-12-20 15:32:28 +00:00
|
|
|
minutes: "/5"
|
2019-04-17 22:46:06 +00:00
|
|
|
seconds: 00
|
|
|
|
condition:
|
|
|
|
- condition: state
|
2019-12-20 15:32:28 +00:00
|
|
|
entity_id: "binary_sensor.workday_sensor"
|
|
|
|
state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: template
|
2019-12-20 15:32:28 +00:00
|
|
|
value_template: "{{ now().hour|int == (states('sensor.wakeup_hour') |int + 3) }}"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: template
|
2019-12-20 15:32:28 +00:00
|
|
|
value_template: "{{ states('sensor.wakeup_minute') |int == now().minute|int }}"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: state
|
|
|
|
entity_id: input_boolean.light_automations
|
2019-12-20 15:32:28 +00:00
|
|
|
state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
action:
|
2019-12-20 15:32:28 +00:00
|
|
|
- service: switch.turn_off
|
2022-11-30 00:50:52 +00:00
|
|
|
entity_id: switch.kitchen_switch
|
2021-03-22 01:56:34 +00:00
|
|
|
- service: switch.turn_off
|
|
|
|
entity_id: switch.front_room
|
2019-04-17 22:46:06 +00:00
|
|
|
|
2019-12-20 15:32:28 +00:00
|
|
|
# ÛÛÛÛÛÛÛÛÛÛ ÛÛÛ
|
|
|
|
# °°ÛÛÛ°°°°°Û °°°
|
|
|
|
# °ÛÛÛ Û ° ÛÛÛÛÛ ÛÛÛÛÛ ÛÛÛÛÛÛ ÛÛÛÛÛÛÛÛ ÛÛÛÛ ÛÛÛÛÛÛÛÛ ÛÛÛÛÛÛÛ
|
|
|
|
# °ÛÛÛÛÛÛ °°ÛÛÛ °°ÛÛÛ ÛÛÛ°°ÛÛÛ°°ÛÛÛ°°ÛÛÛ °°ÛÛÛ °°ÛÛÛ°°ÛÛÛ ÛÛÛ°°ÛÛÛ
|
|
|
|
# °ÛÛÛ°°Û °ÛÛÛ °ÛÛÛ °ÛÛÛÛÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ
|
|
|
|
# °ÛÛÛ ° Û °°ÛÛÛ ÛÛÛ °ÛÛÛ°°° °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ
|
|
|
|
# ÛÛÛÛÛÛÛÛÛÛ °°ÛÛÛÛÛ °°ÛÛÛÛÛÛ ÛÛÛÛ ÛÛÛÛÛ ÛÛÛÛÛ ÛÛÛÛ ÛÛÛÛÛ°°ÛÛÛÛÛÛÛ
|
|
|
|
# °°°°°°°°°° °°°°° °°°°°° °°°° °°°°° °°°°° °°°° °°°°° °°°°°ÛÛÛ
|
|
|
|
# ÛÛÛ °ÛÛÛ
|
|
|
|
# °°ÛÛÛÛÛÛ
|
|
|
|
# °°°°°°
|
|
|
|
###############################################################################
|
|
|
|
# Turn outdoor lights on 15 minutes before sunset
|
|
|
|
###############################################################################
|
2019-04-17 22:46:06 +00:00
|
|
|
- alias: Evening Outdoor Lights ON (At Sunset)
|
2022-12-03 16:28:12 +00:00
|
|
|
# initial_state: true
|
2019-04-17 22:46:06 +00:00
|
|
|
trigger:
|
|
|
|
platform: sun
|
|
|
|
event: sunset
|
2019-12-20 15:32:28 +00:00
|
|
|
offset: "+00:00:00"
|
2019-04-17 22:46:06 +00:00
|
|
|
condition:
|
|
|
|
- condition: state
|
|
|
|
entity_id: input_boolean.light_automations
|
2019-12-20 15:32:28 +00:00
|
|
|
state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
action:
|
|
|
|
- service: switch.turn_on
|
2021-01-10 23:15:03 +00:00
|
|
|
entity_id: switch.frontyard_light
|
2019-04-17 22:46:06 +00:00
|
|
|
- service: switch.turn_on
|
2021-01-10 23:15:03 +00:00
|
|
|
entity_id: switch.backyard_light
|
2019-04-17 22:46:06 +00:00
|
|
|
|
2022-12-01 01:27:26 +00:00
|
|
|
- alias: Christmas Lights ON (At Sunset)
|
|
|
|
trigger:
|
|
|
|
platform: sun
|
|
|
|
event: sunset
|
|
|
|
offset: "+00:00:00"
|
|
|
|
condition:
|
|
|
|
- condition: state
|
|
|
|
entity_id: input_boolean.light_automations
|
|
|
|
state: "on"
|
|
|
|
action:
|
|
|
|
- service: switch.turn_on
|
|
|
|
entity_id: switch.left
|
|
|
|
- service: switch.turn_on
|
|
|
|
entity_id: switch.backyard_light
|
|
|
|
|
|
|
|
- alias: Christmas Lights OFF (At Sunrise)
|
|
|
|
initial_state: true
|
|
|
|
trigger:
|
|
|
|
platform: sun
|
|
|
|
event: sunrise
|
|
|
|
offset: "00:15:00"
|
|
|
|
condition:
|
|
|
|
- condition: state
|
|
|
|
entity_id: input_boolean.light_automations
|
|
|
|
state: "on"
|
|
|
|
action:
|
|
|
|
- service: switch.turn_off
|
|
|
|
entity_id: switch.left
|
|
|
|
- service: switch.turn_off
|
|
|
|
entity_id: switch.backyard_light
|
|
|
|
|
2019-12-20 15:32:28 +00:00
|
|
|
###############################################################################
|
|
|
|
# Turn indoor lights on 30 minutes before sunset
|
|
|
|
###############################################################################
|
2019-04-17 22:46:06 +00:00
|
|
|
- alias: Evening Indoor Lights ON Before Sunset
|
|
|
|
initial_state: true
|
|
|
|
trigger:
|
|
|
|
platform: sun
|
|
|
|
event: sunset
|
2019-12-20 15:32:28 +00:00
|
|
|
offset: "-00:30:00"
|
2019-04-17 22:46:06 +00:00
|
|
|
condition:
|
|
|
|
- condition: state
|
|
|
|
entity_id: input_boolean.light_automations
|
2019-12-20 15:32:28 +00:00
|
|
|
state: "on"
|
2019-05-14 23:32:32 +00:00
|
|
|
- condition: state
|
|
|
|
entity_id: input_boolean.movie_time
|
2019-12-20 15:32:28 +00:00
|
|
|
state: "off"
|
2019-04-17 22:46:06 +00:00
|
|
|
action:
|
|
|
|
- service: switch.turn_on
|
|
|
|
data:
|
2022-11-30 00:50:52 +00:00
|
|
|
entity_id: switch.kitchen_switch
|
2019-04-17 22:46:06 +00:00
|
|
|
- service: light.turn_on
|
|
|
|
data:
|
|
|
|
entity_id: light.hue_color_lamp_1
|
2022-11-30 00:50:52 +00:00
|
|
|
transition: 3000
|
2019-04-17 22:46:06 +00:00
|
|
|
brightness: 255
|
|
|
|
color_temp: 154
|
|
|
|
- service: light.turn_on
|
|
|
|
data:
|
|
|
|
entity_id: light.hue_color_lamp_2
|
2022-11-30 00:50:52 +00:00
|
|
|
transition: 3000
|
2019-04-17 22:46:06 +00:00
|
|
|
brightness: 255
|
|
|
|
color_temp: 154
|
|
|
|
- service: light.turn_on
|
|
|
|
data:
|
|
|
|
entity_id: light.hue_color_lamp_3
|
2022-11-30 00:50:52 +00:00
|
|
|
transition: 3000
|
2019-04-17 22:46:06 +00:00
|
|
|
brightness: 255
|
|
|
|
color_temp: 154
|
|
|
|
- service: light.turn_on
|
|
|
|
data:
|
|
|
|
entity_id: light.master_bedroom_1
|
|
|
|
brightness: 25
|
|
|
|
color_temp: 366
|
|
|
|
- service: light.turn_on
|
|
|
|
data:
|
|
|
|
entity_id: light.master_bedroom_2
|
|
|
|
brightness: 25
|
|
|
|
color_temp: 366
|
|
|
|
- service: switch.turn_on
|
2022-11-30 00:50:52 +00:00
|
|
|
entity_id: switch.hasika_bed_accent
|
2020-03-14 00:10:10 +00:00
|
|
|
- service: switch.turn_on
|
|
|
|
entity_id: switch.front_room
|
2021-01-10 20:03:52 +00:00
|
|
|
- service: switch.turn_on
|
|
|
|
entity_id: switch.officeroom_accent_lights
|
2019-04-17 22:46:06 +00:00
|
|
|
|
2019-12-20 15:32:28 +00:00
|
|
|
# ÛÛÛÛÛÛ ÛÛÛÛÛ ÛÛÛ ÛÛÛÛÛ ÛÛÛÛÛ
|
|
|
|
# °°ÛÛÛÛÛÛ °°ÛÛÛ °°° °°ÛÛÛ °°ÛÛÛ
|
|
|
|
# °ÛÛÛ°ÛÛÛ °ÛÛÛ ÛÛÛÛ ÛÛÛÛÛÛÛ °ÛÛÛÛÛÛÛ ÛÛÛÛÛÛÛ
|
|
|
|
# °ÛÛÛ°°ÛÛÛ°ÛÛÛ °°ÛÛÛ ÛÛÛ°°ÛÛÛ °ÛÛÛ°°ÛÛÛ °°°ÛÛÛ°
|
|
|
|
# °ÛÛÛ °°ÛÛÛÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ
|
|
|
|
# °ÛÛÛ °°ÛÛÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ °ÛÛÛ ÛÛÛ
|
|
|
|
# ÛÛÛÛÛ °°ÛÛÛÛÛ ÛÛÛÛÛ°°ÛÛÛÛÛÛÛ ÛÛÛÛ ÛÛÛÛÛ °°ÛÛÛÛÛ
|
|
|
|
# °°°°° °°°°° °°°°° °°°°°ÛÛÛ°°°° °°°°° °°°°°
|
|
|
|
# ÛÛÛ °ÛÛÛ
|
|
|
|
# °°ÛÛÛÛÛÛ
|
|
|
|
# °°°°°°
|
|
|
|
###############################################################################
|
|
|
|
# Set the mood for bed time - Dim Family Room lights if they are ON
|
|
|
|
###############################################################################
|
2019-04-17 22:46:06 +00:00
|
|
|
- alias: Night Dim TV Lights
|
|
|
|
initial_state: true
|
|
|
|
trigger:
|
|
|
|
platform: time_pattern
|
2019-12-20 15:32:28 +00:00
|
|
|
minutes: "/5"
|
2019-04-17 22:46:06 +00:00
|
|
|
seconds: 00
|
|
|
|
condition:
|
|
|
|
- condition: template
|
2019-12-20 15:32:28 +00:00
|
|
|
value_template: "{{ states('sensor.bedtime_hour') |int == now().hour|int }}"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: template
|
2019-12-20 15:32:28 +00:00
|
|
|
value_template: "{{ (states('sensor.bedtime_minute') |int - 15 ) == now().minute|int }}"
|
2020-09-05 02:12:14 +00:00
|
|
|
# - condition: state
|
|
|
|
# entity_id: light.family_room
|
|
|
|
# state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: state
|
|
|
|
entity_id: input_boolean.light_automations
|
2019-12-20 15:32:28 +00:00
|
|
|
state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
action:
|
|
|
|
- service: light.turn_on
|
|
|
|
data:
|
2020-09-05 02:12:14 +00:00
|
|
|
entity_id: light.hue_color_lamp_1, light.hue_color_lamp_2, light.hue_color_lamp_3
|
2019-04-17 22:46:06 +00:00
|
|
|
brightness: 30
|
|
|
|
color_temp: 154
|
|
|
|
transition: 15
|
|
|
|
|
2019-12-20 15:32:28 +00:00
|
|
|
###############################################################################
|
|
|
|
# TURN INDOOR LIGHTS OFF AFTER BED TIME
|
|
|
|
###############################################################################
|
2019-04-17 22:46:06 +00:00
|
|
|
- alias: Night Turn Lights Off
|
|
|
|
initial_state: true
|
|
|
|
trigger:
|
|
|
|
platform: time_pattern
|
2019-12-20 15:32:28 +00:00
|
|
|
minutes: "/5"
|
2019-04-17 22:46:06 +00:00
|
|
|
seconds: 00
|
|
|
|
condition:
|
|
|
|
- condition: template
|
2019-12-20 15:32:28 +00:00
|
|
|
value_template: "{{ states('sensor.bedtime_hour') |int == now().hour|int }}"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: template
|
2019-12-20 15:32:28 +00:00
|
|
|
value_template: "{{ states('sensor.bedtime_minute') |int == now().minute|int }}"
|
2019-04-17 22:46:06 +00:00
|
|
|
- condition: state
|
|
|
|
entity_id: input_boolean.light_automations
|
2019-12-20 15:32:28 +00:00
|
|
|
state: "on"
|
2019-04-17 22:46:06 +00:00
|
|
|
action:
|
|
|
|
- service: script.all_indoor_lights_off
|
|
|
|
|
2019-12-20 15:32:28 +00:00
|
|
|
###############################################################################
|
|
|
|
# Provide Bed time Report via TTS
|
|
|
|
###############################################################################
|
2019-04-17 22:46:06 +00:00
|
|
|
- alias: Night Bedtime Report
|
|
|
|
initial_state: true
|
|
|
|
trigger:
|
|
|
|
platform: time
|
2019-12-20 15:32:28 +00:00
|
|
|
at: "22:10:00"
|
2019-04-17 22:46:06 +00:00
|
|
|
condition:
|
|
|
|
- condition: template
|
|
|
|
value_template: "{{ states('input_boolean.nightly_report') == 'on' }}"
|
|
|
|
action:
|
2019-12-20 15:32:28 +00:00
|
|
|
- service: script.good_night_tts
|
2021-03-22 01:56:34 +00:00
|
|
|
|
2022-12-03 16:28:12 +00:00
|
|
|
###############################################################################
|
|
|
|
# TOGGLE WORKING IN OFFICE BOOLEAN
|
|
|
|
###############################################################################
|
2021-03-22 01:56:34 +00:00
|
|
|
|
2022-12-03 16:28:12 +00:00
|
|
|
- alias: Suresh Working in Office Start
|
2021-03-22 01:56:34 +00:00
|
|
|
initial_state: true
|
|
|
|
trigger:
|
|
|
|
platform: time
|
|
|
|
at: "08:00:00"
|
|
|
|
condition:
|
|
|
|
- condition: state
|
|
|
|
entity_id: "binary_sensor.workday_sensor"
|
|
|
|
state: "on"
|
|
|
|
action:
|
|
|
|
- service: input_boolean.turn_on
|
|
|
|
entity_id: input_boolean.working_in_office_room
|
|
|
|
|
|
|
|
- alias: Suresh Working in Office End
|
|
|
|
initial_state: true
|
|
|
|
trigger:
|
|
|
|
platform: time
|
|
|
|
at: "18:00:00"
|
|
|
|
condition:
|
|
|
|
- condition: state
|
|
|
|
entity_id: "binary_sensor.workday_sensor"
|
|
|
|
state: "on"
|
|
|
|
action:
|
|
|
|
- service: input_boolean.turn_off
|
|
|
|
entity_id: input_boolean.working_in_office_room
|