Skip to content

Instantly share code, notes, and snippets.

@medmunds
Forked from flyingsubs/zen34.yaml
Last active August 7, 2023 21:13
Show Gist options
  • Save medmunds/96fbdcb8b3ab3d61a88c420706fd48bc to your computer and use it in GitHub Desktop.
Save medmunds/96fbdcb8b3ab3d61a88c420706fd48bc to your computer and use it in GitHub Desktop.
blueprint tutorial for Zen34
blueprint:
name: Zooz ZEN34
description: Automations helper for the Zooz ZEN34 S2 Switch using the Zwave
JS integration.
domain: automation
input:
zooz_zen34:
name: Zooz ZEN34
description: The ZEN34 Switch to interact with.
selector:
device:
integration: zwave_js
manufacturer: Zooz
model: ZEN34
multiple: false
paddle_up_1x:
name: Top Paddle 1x
description: Action to run on upper paddle single tap.
default: []
selector:
action: {}
paddle_up_2x:
name: Top Paddle 2x
description: Action to run on upper paddle double tap.
default: []
selector:
action: {}
paddle_up_3x:
name: Top Paddle 3x
description: Action to run on upper paddle triple tap.
default: []
selector:
action: {}
paddle_up_4x:
name: Top Paddle 4x
description: Action to run on upper paddle quadruple tap.
default: []
selector:
action: {}
paddle_up_5x:
name: Top Paddle 5x
description: Action to run on upper paddle quintuple tap.
default: []
selector:
action: {}
paddle_up_hold:
name: Top Paddle Hold
description: 'Action to run on upper paddle press-and-hold.'
default: []
selector:
action: {}
paddle_up_release:
name: Top Paddle Release
description: Action to run on upper paddle release.
default: []
selector:
action: {}
paddle_down_1x:
name: Lower Paddle 1x
description: Action to run on lower paddle single tap.
default: []
selector:
action: {}
paddle_down_2x:
name: Lower Paddle 2x
description: Action to run on lower paddle double tap.
default: []
selector:
action: {}
paddle_down_3x:
name: Lower Paddle 3x
description: Action to run on lower paddle triple tap.
default: []
selector:
action: {}
paddle_down_4x:
name: Lower Paddle 4x
description: Action to run on lower paddle quadruple tap.
default: []
selector:
action: {}
paddle_down_5x:
name: Lower Paddle 5x
description: Action to run on lower paddle quintuple tap.
default: []
selector:
action: {}
paddle_down_hold:
name: Bottom Paddle Hold
description: 'Action to run on lower paddle press-and-hold.'
default: []
selector:
action: {}
paddle_down_release:
name: Bottom Paddle Release
description: Action to run on lower paddle double tap.
default: []
selector:
action: {}
mode: single
max_exceeded: silent
trigger:
- platform: event
event_type: zwave_js_value_notification
event_data:
command_class_name: Central Scene
device_id: !input zooz_zen34
action:
- variables:
scene_id: '{{ trigger.event.data.label }}'
attribute_id: '{{ trigger.event.data.value }}'
- choose:
- conditions: '{{ scene_id == ''Scene 001'' }}'
sequence:
- choose:
- conditions: '{{ attribute_id == ''KeyPressed'' }}'
sequence: !input paddle_up_1x
- conditions: '{{ attribute_id == ''KeyPressed2x'' }}'
sequence: !input paddle_up_2x
- conditions: '{{ attribute_id == ''KeyPressed3x'' }}'
sequence: !input paddle_up_3x
- conditions: '{{ attribute_id == ''KeyPressed4x'' }}'
sequence: !input paddle_up_4x
- conditions: '{{ attribute_id == ''KeyPressed5x'' }}'
sequence: !input paddle_up_5x
- conditions: '{{ attribute_id == ''KeyReleased'' }}'
sequence: !input paddle_up_release
- conditions: '{{ attribute_id == ''KeyHeldDown'' }}'
sequence: !input paddle_up_hold
- conditions: '{{ scene_id == ''Scene 002'' }}'
sequence:
- choose:
- conditions: '{{ attribute_id == ''KeyPressed'' }}'
sequence: !input paddle_down_1x
- conditions: '{{ attribute_id == ''KeyPressed2x'' }}'
sequence: !input paddle_down_2x
- conditions: '{{ attribute_id == ''KeyPressed3x'' }}'
sequence: !input paddle_down_3x
- conditions: '{{ attribute_id == ''KeyPressed4x'' }}'
sequence: !input paddle_down_4x
- conditions: '{{ attribute_id == ''KeyPressed5x'' }}'
sequence: !input paddle_down_5x
- conditions: '{{ attribute_id == ''KeyReleased'' }}'
sequence: !input paddle_down_release
- conditions: '{{ attribute_id == ''KeyHeldDown'' }}'
sequence: !input paddle_down_hold
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment