|
blueprint: |
|
name: ISY/IoX Button Light Control |
|
description: |- |
|
Control a light with an ISY/IoX button like a KeypadLinc or RemoteLinc. |
|
|
|
Supports ON, FAST ON, OFF, FAST OFF, and a Nightlight mode (turn fast off while off) |
|
|
|
Transition times are 1s for On/Off and 0s for Fast On/Fast Off. |
|
domain: automation |
|
input: |
|
button_sensor: |
|
name: Button Sensor Entity |
|
description: The sensor entity_id for the button you would like to use as a trigger. |
|
selector: |
|
entity: |
|
multiple: false |
|
domain: sensor |
|
integration: isy994 |
|
target_light: |
|
name: Light |
|
description: The target light you would like to control. |
|
selector: |
|
entity: |
|
domain: light |
|
multiple: true |
|
on_level: |
|
name: On Level |
|
description: The On-Level (%) to use for a normal "ON" command |
|
selector: |
|
number: |
|
min: 0 |
|
max: 100 |
|
step: 1 |
|
unit_of_measurement: '%' |
|
mode: slider |
|
nightlight_brightness: |
|
name: Nightlight Brightness |
|
description: The brightness (%) to use for the nightlight |
|
selector: |
|
number: |
|
min: 0 |
|
max: 100 |
|
step: 1 |
|
unit_of_measurement: '%' |
|
mode: slider |
|
|
|
trigger: |
|
- platform: event |
|
event_type: isy994_control |
|
event_data: |
|
entity_id: !input button_sensor |
|
condition: [] |
|
action: |
|
- choose: |
|
- conditions: |
|
- condition: template |
|
value_template: "{{ trigger.event.data.control == \"DON\" }}" |
|
alias: Turned On |
|
sequence: |
|
- service: light.turn_on |
|
data: |
|
transition: 1 |
|
brightness_pct: !input on_level |
|
target: |
|
entity_id: !input target_light |
|
- conditions: |
|
- condition: template |
|
value_template: "{{ trigger.event.data.control == \"DFON\" }}" |
|
alias: Turned Fast On |
|
sequence: |
|
- service: light.turn_on |
|
data: |
|
transition: 0 |
|
brightness_pct: 100 |
|
target: |
|
entity_id: !input target_light |
|
- conditions: |
|
- condition: template |
|
value_template: "{{ trigger.event.data.control == \"DOF\" }}" |
|
alias: Turned Off |
|
sequence: |
|
- service: light.turn_off |
|
data: |
|
transition: 1 |
|
target: |
|
entity_id: !input target_light |
|
- conditions: |
|
- condition: template |
|
value_template: "{{ trigger.event.data.control == \"DFOF\" }}" |
|
alias: Turned Fast Off while On |
|
- condition: state |
|
entity_id: !input target_light |
|
state: "on" |
|
sequence: |
|
- service: light.turn_off |
|
data: |
|
transition: 0 |
|
target: |
|
entity_id: !input target_light |
|
- conditions: |
|
- condition: template |
|
value_template: "{{ trigger.event.data.control == \"DFOF\" }}" |
|
alias: Nightlight (Fast Off while Off) |
|
- condition: state |
|
entity_id: !input target_light |
|
state: "off" |
|
sequence: |
|
- service: light.turn_on |
|
data: |
|
transition: 0 |
|
brightness_pct: !input nightlight_brightness |
|
target: |
|
entity_id: !input target_light |
|
mode: single |