I am new to Home Assistant so please do not be upset about this question.
How do I install this Blueprint. Usually Blueprints that I have installed have “click to preview” then install. I think this one has to be installed manually?
Thanks, @ogiewon! Here’s my version. Updated to include actions on a long press and a short press. It also uses trigger ID’s, which I think were introduced to HA after you shared your blueprint.
blueprint:
name: Lutron Caseta Pico 2-button Remote
description: Short and long press automations for the Pico 2-button remote
domain: automation
input:
pico_remote:
name: Pico Remote
description: Select the Pico remote to configure
selector:
device:
integration: lutron_caseta
model: PJ2-2B-GXX-X01 (Pico2Button)
on_short:
name: Top (on) button - Short press
description: Action to run on when the on button is briefly pressed
default: []
selector:
action: {}
off_short:
name: Bottom (off) button - Short press
description: Action to run on when the off button is briefly pressed
default: []
selector:
action: {}
on_long:
name: Top (on) button - Long press
description: Action to run on when the on button is held down
default: []
selector:
action: {}
off_long:
name: Bottom (off) button - Long press
description: Action to run on when the off button is held down
default: []
selector:
action: {}
time_before_long_press:
name: Time before long press
description: Amount of time button needs to be held before triggering "long press" action.
default: 2
selector:
number:
min: 0.0
max: 10.0
step: 0.25
unit_of_measurement: seconds
mode: slider
auto_mode:
name: Automation Mode
description: "Mode that automation runs in (single, restart, queued, parallel)."
default: restart
selector:
select:
options:
- single
- restart
- queued
- parallel
mode_max:
name: "Mode Max (ignored by Single and Restart Modes)"
description: "Maximum number of runs that can be executed or queued at a time."
default: 10
selector:
number:
min: 1
max: 15
trigger:
- platform: device
device_id: !input "pico_remote"
domain: lutron_caseta
type: press
subtype: "on"
id: on_press
- platform: device
device_id: !input "pico_remote"
domain: lutron_caseta
type: press
subtype: "off"
id: off_press
condition: []
action:
- choose:
- conditions:
- condition: trigger
id: on_press
sequence:
- wait_for_trigger:
- platform: device
device_id: !input "pico_remote"
domain: lutron_caseta
type: release
subtype: "on"
timeout: !input "time_before_long_press"
- choose:
- conditions:
- condition: template
value_template: "{{ wait.trigger == none }}"
sequence: !input "on_long"
default: !input "on_short"
- conditions:
- condition: trigger
id: off_press
sequence:
- wait_for_trigger:
- platform: device
device_id: !input "pico_remote"
domain: lutron_caseta
type: release
subtype: "off"
timeout: !input "time_before_long_press"
- choose:
- conditions:
- condition: template
value_template: "{{ wait.trigger == none }}"
sequence: !input "off_long"
default: !input "off_short"
default: []
mode: !input "auto_mode"
max: !input "mode_max"
I know that 2022 October or November update created some problems with @stephack’s original pico blueprint. (See post here and then here.) This looks like it was resolved in 2022.12.0, but I don’t understand what the problem was or if it’s impacted this blueprint.
Following some advice from @stephack in this post many months back, I just updated my blueprint in the first post to comment out the ‘integration’ line below.
I am not currently using any Pico remotes directly with Home Assistant, which is why I have not been on top of any of these issues over the past few months.