Compare commits
2 Commits
stairwell-
...
lightfx-mo
Author | SHA1 | Date | |
---|---|---|---|
ea3bc9a048
|
|||
301e851c2c
|
160
automations.yaml
160
automations.yaml
@ -3217,6 +3217,26 @@
|
|||||||
adapt_brightness: '{{ is_state(''switch.adaptive_lighting_adapt_brightness_master_bedroom'',''on'')
|
adapt_brightness: '{{ is_state(''switch.adaptive_lighting_adapt_brightness_master_bedroom'',''on'')
|
||||||
}}'
|
}}'
|
||||||
mode: restart
|
mode: restart
|
||||||
|
- id: '1697475527093'
|
||||||
|
alias: Lighting Effects Concept
|
||||||
|
description: ''
|
||||||
|
trigger:
|
||||||
|
- platform: state
|
||||||
|
entity_id:
|
||||||
|
- input_boolean.toggle_testing
|
||||||
|
from: 'off'
|
||||||
|
to: 'on'
|
||||||
|
condition: []
|
||||||
|
action:
|
||||||
|
- event: lightfx
|
||||||
|
event_data:
|
||||||
|
basement: true
|
||||||
|
first_floor: true
|
||||||
|
color: red
|
||||||
|
divide: half
|
||||||
|
duration: 10
|
||||||
|
lifx: move
|
||||||
|
mode: restart
|
||||||
- id: '1697819133179'
|
- id: '1697819133179'
|
||||||
alias: Give Me Darkness
|
alias: Give Me Darkness
|
||||||
description: Automatically trigger Give Me Darkness if it has not already happened
|
description: Automatically trigger Give Me Darkness if it has not already happened
|
||||||
@ -5314,146 +5334,6 @@
|
|||||||
data:
|
data:
|
||||||
datetime: '{% from ''time.jinja'' import set_datetime %} {{ set_datetime(0)
|
datetime: '{% from ''time.jinja'' import set_datetime %} {{ set_datetime(0)
|
||||||
}}
|
}}
|
||||||
- id: '1716580842614'
|
|
||||||
alias: Stairwell and Hallway Motion Lighting
|
|
||||||
description: ''
|
|
||||||
trigger:
|
|
||||||
- platform: state
|
|
||||||
entity_id:
|
|
||||||
- binary_sensor.stairwell_top_motion
|
|
||||||
to: 'on'
|
|
||||||
from: 'off'
|
|
||||||
id: top-detected
|
|
||||||
alias: Stairwell Top Detected
|
|
||||||
- platform: state
|
|
||||||
entity_id:
|
|
||||||
- binary_sensor.stairwell_bottom_motion
|
|
||||||
from: 'off'
|
|
||||||
to: 'on'
|
|
||||||
id: bottom-detected
|
|
||||||
alias: Stairwell Bottom Detected
|
|
||||||
- platform: state
|
|
||||||
entity_id:
|
|
||||||
- binary_sensor.stairwell_top_motion
|
|
||||||
from: 'on'
|
|
||||||
to: 'off'
|
|
||||||
id: top-clear
|
|
||||||
alias: Stairwell Top Clear
|
|
||||||
- platform: state
|
|
||||||
entity_id:
|
|
||||||
- binary_sensor.stairwell_bottom_motion
|
|
||||||
from: 'on'
|
|
||||||
to: 'off'
|
|
||||||
id: bottom-clear
|
|
||||||
alias: Stairwell Bottom Clear
|
|
||||||
- platform: event
|
|
||||||
event_type: timer.finished
|
|
||||||
event_data:
|
|
||||||
entity_id: timer.stairwell_motion_timer
|
|
||||||
id: stairwell-timer
|
|
||||||
alias: Stairwell Timer Finished
|
|
||||||
- alias: Hallway Timer Finished
|
|
||||||
platform: event
|
|
||||||
event_type: timer.finished
|
|
||||||
event_data:
|
|
||||||
entity_id: timer.upstairs_hallway_motion_timer
|
|
||||||
id: hallway-timer
|
|
||||||
condition: []
|
|
||||||
action:
|
|
||||||
- variables:
|
|
||||||
hallway_scene: "{% set people_sleeping = is_state('input_boolean.emma_sleeping','on')
|
|
||||||
or is_state('input_boolean.kallen_sleeping','on') or is_state('input_boolean.master_bedroom_sleeping','on')
|
|
||||||
%} {% if is_state('input_boolean.night_mode','on') or people_sleeping == true
|
|
||||||
%}\n Nightlight\n{% else %}\n Adaptive\n{% endif %}\n"
|
|
||||||
hallway_action: "{% set people_sleeping = is_state('input_boolean.emma_sleeping','on')
|
|
||||||
or is_state('input_boolean.kallen_sleeping','on') or is_state('input_boolean.master_bedroom_sleeping','on')
|
|
||||||
%} {% if is_state('input_boolean.goodnight','on') %}\n off\n{% elif is_state('input_boolean.night_mode','on')
|
|
||||||
or people_sleeping == true or is_state('binary_sensor.early_night_mode','on')
|
|
||||||
%}\n on\n{% else %}\n off\n{% endif %}\n"
|
|
||||||
- choose:
|
|
||||||
- conditions:
|
|
||||||
- condition: trigger
|
|
||||||
id:
|
|
||||||
- top-detected
|
|
||||||
- condition: numeric_state
|
|
||||||
entity_id: sensor.stairwell_top_illuminance
|
|
||||||
below: input_number.upstairs_hallway_lux_threshold
|
|
||||||
alias: Stairwell Top Illuminance is below lux threshold
|
|
||||||
sequence: []
|
|
||||||
alias: Stairwell Top Detected
|
|
||||||
- conditions:
|
|
||||||
- condition: trigger
|
|
||||||
id:
|
|
||||||
- bottom-detected
|
|
||||||
- alias: Stairwell Bottom Illuminance is below lux threshold
|
|
||||||
condition: numeric_state
|
|
||||||
entity_id: sensor.stairwell_bottom_illuminance
|
|
||||||
below: input_number.stairwell_lux_threshold
|
|
||||||
sequence: []
|
|
||||||
alias: Stairwell Bottom Detected
|
|
||||||
- conditions:
|
|
||||||
- condition: trigger
|
|
||||||
id:
|
|
||||||
- top-clear
|
|
||||||
- alias: Lights are on
|
|
||||||
condition: or
|
|
||||||
conditions:
|
|
||||||
- condition: state
|
|
||||||
entity_id: light.hallway_overhead
|
|
||||||
state: 'on'
|
|
||||||
alias: Hallway Overhead
|
|
||||||
- alias: Stairwell LED Strip
|
|
||||||
condition: state
|
|
||||||
entity_id: light.stairwell_led_strip
|
|
||||||
state: 'on'
|
|
||||||
sequence:
|
|
||||||
- service: timer.start
|
|
||||||
metadata: {}
|
|
||||||
data:
|
|
||||||
duration: '{{ states(''input_number.upstairs_hallway_lights_off_delay'')
|
|
||||||
| int * 60 }}'
|
|
||||||
target:
|
|
||||||
entity_id: timer.upstairs_hallway_motion_timer
|
|
||||||
alias: Start upstairs hallway motion timer
|
|
||||||
alias: Stairwell Top Clear
|
|
||||||
- conditions:
|
|
||||||
- condition: trigger
|
|
||||||
id:
|
|
||||||
- bottom-clear
|
|
||||||
- alias: Lights are on
|
|
||||||
condition: or
|
|
||||||
conditions:
|
|
||||||
- condition: state
|
|
||||||
entity_id: light.hallway_overhead
|
|
||||||
state: 'on'
|
|
||||||
alias: Hallway Overhead
|
|
||||||
- alias: Stairwell LED Strip
|
|
||||||
condition: state
|
|
||||||
entity_id: light.stairwell_led_strip
|
|
||||||
state: 'on'
|
|
||||||
sequence:
|
|
||||||
- service: timer.start
|
|
||||||
metadata: {}
|
|
||||||
data:
|
|
||||||
duration: '{{ states(''input_number.stairwell_lights_off_delay'') | int
|
|
||||||
* 60 }}'
|
|
||||||
target:
|
|
||||||
entity_id: timer.stairwell_motion_timer
|
|
||||||
alias: Start stairwell motion timer
|
|
||||||
alias: Stairwell Bottom Clear
|
|
||||||
- conditions:
|
|
||||||
- condition: trigger
|
|
||||||
id:
|
|
||||||
- hallway-timer
|
|
||||||
sequence: []
|
|
||||||
alias: Hallway Timer Finished
|
|
||||||
- conditions:
|
|
||||||
- condition: trigger
|
|
||||||
id:
|
|
||||||
- stairwell-timer
|
|
||||||
sequence: []
|
|
||||||
alias: Stairwell Timer Finished
|
|
||||||
mode: restart
|
|
||||||
|
|
||||||
'
|
'
|
||||||
alias: Set time morning meds were taken
|
alias: Set time morning meds were taken
|
||||||
|
@ -44,12 +44,6 @@ input_boolean:
|
|||||||
adaptive_lighting_adjustments:
|
adaptive_lighting_adjustments:
|
||||||
name: Adaptive Lighting Adjustments
|
name: Adaptive Lighting Adjustments
|
||||||
icon: mdi:knob
|
icon: mdi:knob
|
||||||
upstairs_hallway_motion_lighting:
|
|
||||||
name: Upstairs Hallway Motion Lighting
|
|
||||||
icon: mdi:motion-sensor
|
|
||||||
stairwell_motion_lighting:
|
|
||||||
name: Stairwell Motion Lighting
|
|
||||||
icon: mdi:motion-sensor
|
|
||||||
|
|
||||||
input_number:
|
input_number:
|
||||||
upstairs_bathroom_motion_off_delay:
|
upstairs_bathroom_motion_off_delay:
|
||||||
|
53
scripts.yaml
53
scripts.yaml
@ -108,27 +108,12 @@ global_on:
|
|||||||
max_brightness:
|
max_brightness:
|
||||||
sequence:
|
sequence:
|
||||||
- alias: Turn off Adaptive Lighting and Motion Lighting
|
- alias: Turn off Adaptive Lighting and Motion Lighting
|
||||||
parallel:
|
data: {}
|
||||||
- service: automation.turn_off
|
target:
|
||||||
metadata: {}
|
label_id:
|
||||||
data:
|
- adaptive_lighting
|
||||||
stop_actions: true
|
- motion_lighting
|
||||||
target:
|
action: switch.turn_off
|
||||||
label_id: motion_lighting
|
|
||||||
alias: Automations
|
|
||||||
- alias: Switches
|
|
||||||
service: switch.turn_off
|
|
||||||
data: {}
|
|
||||||
target:
|
|
||||||
label_id:
|
|
||||||
- adaptive_lighting
|
|
||||||
- motion_lighting
|
|
||||||
- service: input_boolean.turn_off
|
|
||||||
metadata: {}
|
|
||||||
data: {}
|
|
||||||
target:
|
|
||||||
label_id: motion_lighting
|
|
||||||
alias: Input Booleans
|
|
||||||
- delay:
|
- delay:
|
||||||
hours: 0
|
hours: 0
|
||||||
minutes: 0
|
minutes: 0
|
||||||
@ -478,26 +463,12 @@ max_brightness_cleanup:
|
|||||||
target:
|
target:
|
||||||
entity_id: input_select.basement_studio_scenes
|
entity_id: input_select.basement_studio_scenes
|
||||||
alias: Set basement lights to adaptive
|
alias: Set basement lights to adaptive
|
||||||
- alias: Turn on motion lighting
|
- service: switch.turn_on
|
||||||
parallel:
|
metadata: {}
|
||||||
- service: input_boolean.turn_on
|
data: {}
|
||||||
metadata: {}
|
target:
|
||||||
data: {}
|
label_id: motion_lighting
|
||||||
target:
|
alias: Turn on motion lighting
|
||||||
label_id: motion_lighting
|
|
||||||
alias: Input Booleans
|
|
||||||
- service: switch.turn_on
|
|
||||||
metadata: {}
|
|
||||||
data: {}
|
|
||||||
target:
|
|
||||||
label_id: motion_lighting
|
|
||||||
alias: Switches
|
|
||||||
- service: automation.turn_on
|
|
||||||
metadata: {}
|
|
||||||
data: {}
|
|
||||||
target:
|
|
||||||
label_id: motion_lighting
|
|
||||||
alias: Automations
|
|
||||||
mode: single
|
mode: single
|
||||||
icon: mdi:broom
|
icon: mdi:broom
|
||||||
cleanup_crash:
|
cleanup_crash:
|
||||||
|
Reference in New Issue
Block a user