Change lights automations
Merge with white temperature automations
This commit is contained in:
parent
92bf8c23e2
commit
2af639deb4
@ -36,7 +36,6 @@
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 3200
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_select.home_mode
|
||||
@ -66,7 +65,7 @@
|
||||
condition:
|
||||
- condition: state
|
||||
entity_id: binary_sensor.bathroom_motion_occupancy
|
||||
for: '0:02:00'
|
||||
for: '0:05:00'
|
||||
state: 'off'
|
||||
- condition: state
|
||||
entity_id: binary_sensor.shower_motion
|
||||
|
@ -14,11 +14,27 @@
|
||||
entity_id: input_select.home_mode
|
||||
state: Day
|
||||
action:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'on'
|
||||
sequence:
|
||||
- service: light.turn_on
|
||||
entity_id: light.bedroom_lights
|
||||
data:
|
||||
brightness_pct: 60
|
||||
kelvin: 2000
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'off'
|
||||
sequence:
|
||||
- service: light.toggle
|
||||
entity_id: light.bedroom_lights
|
||||
data:
|
||||
brightness_pct: 60
|
||||
kelvin: 3200
|
||||
|
||||
- id: bedroom-motion-off
|
||||
alias: '[Bedroom] Motion Off'
|
||||
|
@ -7,9 +7,27 @@
|
||||
type: remote_button_short_press
|
||||
subtype: turn_on
|
||||
action:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'on'
|
||||
sequence:
|
||||
- service: light.turn_on
|
||||
data:
|
||||
entity_id: light.desk_lightbar
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 2000
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'off'
|
||||
sequence:
|
||||
- service: light.toggle
|
||||
entity_id: light.desk_lightbar
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 3200
|
||||
mode: single
|
||||
|
||||
- id: button-computer-cave-off
|
||||
@ -35,9 +53,27 @@
|
||||
device_id: 5b972523e427721ec88e095994f7cc16
|
||||
command: move_with_on_off
|
||||
action:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'on'
|
||||
sequence:
|
||||
- service: light.turn_on
|
||||
data:
|
||||
entity_id: light.tv_lights
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 2000
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'off'
|
||||
sequence:
|
||||
- service: light.toggle
|
||||
entity_id: light.tv_lights
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 3200
|
||||
mode: single
|
||||
|
||||
- id: button-computer-cave-hold-off
|
||||
|
@ -1,35 +1,44 @@
|
||||
- id: hallway-motion-day
|
||||
alias: '[Hallway] Motion Day'
|
||||
- id: hallway-lightstrip-on
|
||||
alias: '[Hallway] Lights strip on'
|
||||
mode: restart
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: binary_sensor.hallway_motion_sensor
|
||||
from: 'off'
|
||||
to: 'on'
|
||||
condition:
|
||||
action:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_select.home_mode
|
||||
state: Day
|
||||
action:
|
||||
sequence:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'on'
|
||||
sequence:
|
||||
- service: light.turn_on
|
||||
entity_id: light.hallway_lightstrip
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 2000
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'off'
|
||||
sequence:
|
||||
- service: light.toggle
|
||||
entity_id: light.hallway_lightstrip
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 3200
|
||||
|
||||
- id: hallway-motion-night
|
||||
alias: '[Hallway] Motion Night'
|
||||
mode: restart
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: binary_sensor.hallway_motion_sensor
|
||||
from: 'off'
|
||||
to: 'on'
|
||||
condition:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_select.home_mode
|
||||
state: Night
|
||||
action:
|
||||
sequence:
|
||||
- service: light.turn_on
|
||||
entity_id: light.hallway_lightstrip
|
||||
data:
|
||||
|
@ -10,9 +10,43 @@
|
||||
type: remote_button_short_press
|
||||
subtype: button_1
|
||||
action:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_select.home_mode
|
||||
state: Day
|
||||
sequence:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'on'
|
||||
sequence:
|
||||
- service: light.turn_on
|
||||
target:
|
||||
entity_id: light.kitchen_lights
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 2000
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'off'
|
||||
sequence:
|
||||
- service: light.toggle
|
||||
entity_id: light.kitchen_lights
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 3200
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_select.home_mode
|
||||
state: Night
|
||||
sequence:
|
||||
- service: light.turn_on
|
||||
entity_id: light.kitchen_lights
|
||||
data:
|
||||
brightness_pct: 5
|
||||
kelvin: 2700
|
||||
|
||||
- id: kitchen-button-2 # Upper right
|
||||
alias: '[Kitchen] Button 2'
|
||||
@ -58,6 +92,9 @@
|
||||
- service: light.turn_off
|
||||
target:
|
||||
entity_id: light.hallway_light
|
||||
- service: light.turn_off
|
||||
target:
|
||||
entity_id: light.hallway_lightstrip
|
||||
|
||||
- id: kitchen-button-2-held # Upper right
|
||||
alias: '[Kitchen] Button 2 Hold'
|
||||
@ -103,9 +140,27 @@
|
||||
type: remote_button_short_press
|
||||
subtype: turn_on
|
||||
action:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'on'
|
||||
sequence:
|
||||
- service: light.turn_on
|
||||
data:
|
||||
entity_id: light.kitchen_sink_lighstrip
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 2000
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'off'
|
||||
sequence:
|
||||
- service: light.toggle
|
||||
entity_id: light.kitchen_sink_lighstrip
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 3200
|
||||
mode: single
|
||||
|
||||
- id: kitchen-sink-button-off
|
||||
@ -131,9 +186,43 @@
|
||||
device_id: a47c928b108240ed8866f9f7a70bc844
|
||||
command: move_with_on_off
|
||||
action:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_select.home_mode
|
||||
state: Day
|
||||
sequence:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'on'
|
||||
sequence:
|
||||
- service: light.turn_on
|
||||
data:
|
||||
entity_id: light.kitchen_lights
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 2000
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'off'
|
||||
sequence:
|
||||
- service: light.toggle
|
||||
entity_id: light.kitchen_lights
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 3200
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_select.home_mode
|
||||
state: Night
|
||||
sequence:
|
||||
- service: light.turn_on
|
||||
entity_id: light.kitchen_lights
|
||||
data:
|
||||
brightness_pct: 5
|
||||
kelvin: 2700
|
||||
mode: single
|
||||
|
||||
- id: kitchen-sink-button-hold-off
|
||||
|
@ -1,46 +1,55 @@
|
||||
- id: kitchen-motion-dark
|
||||
alias: '[Kitchen] Motion day dark'
|
||||
- id: kitchen-lights-on
|
||||
alias: '[Kitchen] Lights On'
|
||||
mode: single
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: binary_sensor.kitchen_motion_sensor
|
||||
from: 'off'
|
||||
to: 'on'
|
||||
condition:
|
||||
- condition: numeric_state
|
||||
entity_id: sensor.kitchen_motion_luminance
|
||||
below: '25'
|
||||
action:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_select.home_mode
|
||||
state: Day
|
||||
action:
|
||||
- condition: numeric_state
|
||||
entity_id: sensor.kitchen_motion_luminance
|
||||
below: '25'
|
||||
sequence:
|
||||
- choose:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'on'
|
||||
sequence:
|
||||
- service: light.turn_on
|
||||
entity_id: light.kitchen_lights
|
||||
data:
|
||||
brightness_pct: 90
|
||||
brightness_pct: 100
|
||||
kelvin: 2000
|
||||
|
||||
- id: kitchen-motion-night
|
||||
alias: '[Kitchen] Motion night'
|
||||
mode: single
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: binary_sensor.kitchen_motion_sensor
|
||||
from: 'off'
|
||||
to: 'on'
|
||||
condition:
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'off'
|
||||
sequence:
|
||||
- service: light.toggle
|
||||
entity_id: light.kitchen_lights
|
||||
data:
|
||||
brightness_pct: 100
|
||||
kelvin: 3200
|
||||
- conditions:
|
||||
- condition: state
|
||||
entity_id: input_select.home_mode
|
||||
state: Night
|
||||
action:
|
||||
sequence:
|
||||
- service: light.turn_on
|
||||
entity_id: light.kitchen_lights
|
||||
data:
|
||||
brightness_pct: 5
|
||||
kelvin: 2000
|
||||
kelvin: 2700
|
||||
|
||||
- id: kitchen-motion-off
|
||||
alias: '[Kitchen] Motion Off'
|
||||
- id: kitchen-lights-off
|
||||
alias: '[Kitchen] Lights Off'
|
||||
mode: restart
|
||||
trigger:
|
||||
- platform: state
|
||||
|
@ -17,10 +17,6 @@
|
||||
name: Shower Lights
|
||||
- entityId: light.tv_lights
|
||||
name: TV Lights
|
||||
- entityId: light.computer_computer_cave_background
|
||||
name: Computer Computer Cave Background
|
||||
- entityId: light.couch_lamp
|
||||
name: Couch lamp
|
||||
- entityId: light.desk_lightbar
|
||||
name: Desk Lightbar
|
||||
- name: Concat scripts
|
||||
|
@ -1,21 +1,5 @@
|
||||
{% for light in lights %}
|
||||
# {{ light.name }}
|
||||
- id: sleep_mode_{{ light.entityId }}
|
||||
alias: '[Sleep-Mode] {{ light.name }}'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: {{ light.entityId }}
|
||||
to: 'on'
|
||||
condition:
|
||||
- condition: state
|
||||
entity_id: input_boolean.sleep_mode
|
||||
state: 'on'
|
||||
action:
|
||||
- service: light.turn_on
|
||||
data:
|
||||
kelvin: 2000
|
||||
entity_id: {{ light.entityId }}
|
||||
mode: single
|
||||
- id: sleep_on_{{ light.entityId }}
|
||||
alias: '[Sleep-On] {{ light.name }}'
|
||||
trigger:
|
||||
@ -31,21 +15,6 @@
|
||||
kelvin: 2000
|
||||
entity_id: {{ light.entityId }}
|
||||
mode: single
|
||||
- id: day_mode_{{ light.entityId }}
|
||||
alias: '[Day-Mode] {{ light.name }}'
|
||||
trigger:
|
||||
- platform: time
|
||||
at: input_datetime.day_mode
|
||||
condition:
|
||||
- condition: state
|
||||
entity_id: {{ light.entityId }}
|
||||
state: 'on'
|
||||
action:
|
||||
- service: light.turn_on
|
||||
data:
|
||||
kelvin: 3200
|
||||
entity_id: {{ light.entityId }}
|
||||
mode: single
|
||||
- id: day_on_{{ light.entityId }}
|
||||
alias: '[Day-On] {{ light.name }}'
|
||||
trigger:
|
||||
|
Loading…
Reference in New Issue
Block a user