Created
December 20, 2020 11:29
-
-
Save r3mcos3/daf060297b5bf8c3561ad73cda952e14 to your computer and use it in GitHub Desktop.
Home Assistant Blueprint For Light Sensor Activated Lights
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
blueprint: | |
name: Lux Activated Lights | |
description: 'Activated lights when lux level is below a specific level' | |
domain: automation | |
input: | |
lux_sensor: | |
name: Lux Sensor | |
description: Lux sensor to use. | |
selector: | |
entity: | |
device_class: illuminance | |
lights: | |
name: Lights | |
description: 'Lights to use.' | |
selector: | |
target: | |
entity: | |
domain: light | |
lux_level: | |
name: Lux Level | |
description: 'Below value off the sensor, To activate the lights' | |
default: 5 | |
selector: | |
number: | |
min: 0 | |
max: 100 | |
step: 1 | |
mode: slider | |
unit_of_measurement: lx | |
time_after: | |
name: Time After | |
description: 'Time that it has to be after, to prevent lights go on in afternoon' | |
default: '00:00:00' | |
selector: | |
time: | |
time_before: | |
name: Time Before | |
description: 'Time that it has to be before, to prevent lights go on in the middle off the night' | |
default: '00:00:00' | |
selector: | |
time: | |
mode: single | |
trigger: | |
platform: numeric_state | |
entity_id: !input 'lux_sensor' | |
below: !input 'lux_level' | |
action: | |
- choose: | |
- conditions: | |
- condition: time | |
after: !input 'time_after' | |
before: !input 'time_before' | |
sequence: | |
- service: light.turn_on | |
target: !input 'lights' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment