-
Notifications
You must be signed in to change notification settings - Fork 33
/
homematicip_local-actions-for-key_ring_remote_control.yaml
109 lines (108 loc) · 3.62 KB
/
homematicip_local-actions-for-key_ring_remote_control.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
blueprint:
name: Actions for 4-Button Homematic(IP) device
description:
When a button is pressed, the defined actions will be executed. Please
keep in mind, that long-press actions might be executed multiple times, according
to your configured minimum duration for long press. This can be configured in
your CCU.
Tested with HmIP-KRCA. Should work with other device too.
v2022-10-28
domain: automation
source_url: https://github.com/sukramj/custom_homematic/blob/devel/blueprints/automation/homematicip_local-actions-for-key_ring_remote_control.yaml
input:
remote:
name: 4-Button Device (e.g. HmIP-KRCA)
description: Please select a 4-Button device of your Homematic(IP) Local integration.
selector:
device:
integration: homematicip_local
action_1_short:
name: Action
description: Button 1, Short Press
default: []
selector:
action: {}
action_1_long:
name: Action
description: Button 1, Long Press
default: []
selector:
action: {}
action_2_short:
name: Action
description: Button 2, Short Press
default: []
selector:
action: {}
action_2_long:
name: Action
description: Button 2, Long Press
default: []
selector:
action: {}
action_3_short:
name: Action
description: Button 3, Short Press
default: []
selector:
action: {}
action_3_long:
name: Action
description: Button 3, Long Press
default: []
selector:
action: {}
action_4_short:
name: Action
description: Button 4, Short Press
default: []
selector:
action: {}
action_4_long:
name: Action
description: Button 4, Long Press
default: []
selector:
action: {}
trigger:
- platform: event
event_type: homematic.keypress
event_data:
device_id: !input "remote"
condition: []
action:
- choose:
- conditions:
- condition: template
value_template: "{{ trigger.event.data.type == 'press_short' and trigger.event.data.subtype == 2 }}"
sequence: !input "action_1_short"
- conditions:
- condition: template
value_template: "{{ trigger.event.data.type == 'press_long' and trigger.event.data.subtype == 2 }}"
sequence: !input "action_1_long"
- conditions:
- condition: template
value_template: "{{ trigger.event.data.type == 'press_short' and trigger.event.data.subtype == 1 }}"
sequence: !input "action_2_short"
- conditions:
- condition: template
value_template: "{{ trigger.event.data.type == 'press_long' and trigger.event.data.subtype == 1 }}"
sequence: !input "action_2_long"
- conditions:
- condition: template
value_template: "{{ trigger.event.data.type == 'press_short' and trigger.event.data.subtype == 4 }}"
sequence: !input "action_3_short"
- conditions:
- condition: template
value_template: "{{ trigger.event.data.type == 'press_long' and trigger.event.data.subtype == 4 }}"
sequence: !input "action_3_long"
- conditions:
- condition: template
value_template: "{{ trigger.event.data.type == 'press_short' and trigger.event.data.subtype == 3 }}"
sequence: !input "action_4_short"
- conditions:
- condition: template
value_template: "{{ trigger.event.data.type == 'press_long' and trigger.event.data.subtype == 3 }}"
sequence: !input "action_4_long"
mode: parallel
max: 10