-
Notifications
You must be signed in to change notification settings - Fork 23
/
senseo_wifi.yaml
339 lines (310 loc) · 10.6 KB
/
senseo_wifi.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
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
mqtt:
switch:
- name: senseowifi_power
unique_id: uniqueid__senseowifi_power
icon: mdi:power
#
state_topic: "homie/senseo-wifi-rf21/machine/power"
state_on: "true"
state_off: "false"
#
command_topic: "homie/senseo-wifi-rf21/machine/power/set"
payload_on: "true"
payload_off: "false"
#
availability_topic: "homie/senseo-wifi-rf21/$state"
payload_available: "ready"
payload_not_available: "lost"
binary_sensor:
- name: senseowifi_out_of_water
unique_id: uniqueid__senseowifi_out_of_water
icon: mdi:water-off-outline
#
state_topic: "homie/senseo-wifi-rf21/machine/outOfWater"
payload_on: "true"
payload_off: "false"
device_class: problem
#
availability_topic: "homie/senseo-wifi-rf21/$state"
payload_available: "ready"
payload_not_available: "lost"
- name: senseowifi_cup_available
unique_id: uniqueid__senseowifi_cup_available
icon: mdi:coffee-outline
#
state_topic: "homie/senseo-wifi-rf21/machine/cupAvailable"
payload_on: "true"
payload_off: "false"
#
availability_topic: "homie/senseo-wifi-rf21/$state"
payload_available: "ready"
payload_not_available: "lost"
- name: senseowifi_cup_full
unique_id: uniqueid__senseowifi_cup_full
icon: mdi:coffee
#
state_topic: "homie/senseo-wifi-rf21/machine/cupFull"
payload_on: "true"
payload_off: "false"
#
availability_topic: "homie/senseo-wifi-rf21/$state"
payload_available: "ready"
payload_not_available: "lost"
sensor:
- name: senseowifi_brewed_size
unique_id: uniqueid__senseowifi_brewed_size
icon: mdi:coffee-maker
#
state_topic: "homie/senseo-wifi-rf21/machine/brewedSize"
#
availability_topic: "homie/senseo-wifi-rf21/$state"
payload_available: "ready"
payload_not_available: "lost"
- name: senseowifi_opstate
unique_id: uniqueid__senseowifi_opstate
icon: mdi:state-machine
#
state_topic: "homie/senseo-wifi-rf21/machine/opState"
#
availability_topic: "homie/senseo-wifi-rf21/$state"
payload_available: "ready"
payload_not_available: "lost"
##############################################################################
- name: senseowifi_debug
unique_id: uniqueid__senseowifi_debug
icon: mdi:comment-text-multiple-outline
#
state_topic: "homie/senseo-wifi-rf21/machine/debug"
#
availability_topic: "homie/senseo-wifi-rf21/$state"
payload_available: "ready"
payload_not_available: "lost"
#
entity_category: diagnostic
- name: senseowifi_rssi
unique_id: uniqueid__senseowifi_rssi
icon: mdi:signal-cellular-2
#
state_topic: "homie/senseo-wifi-rf21/$stats/signal"
unit_of_measurement: "%"
#
availability_topic: "homie/senseo-wifi-rf21/$state"
payload_available: "ready"
payload_not_available: "lost"
#
device_class: signal_strength
entity_category: diagnostic
- name: senseowifi_uptime
unique_id: uniqueid__senseowifi_uptime
icon: mdi:av-timer
#
state_topic: "homie/senseo-wifi-rf21/$stats/uptime"
unit_of_measurement: "s"
#
availability_topic: "homie/senseo-wifi-rf21/$state"
payload_available: "ready"
payload_not_available: "lost"
##############################################################################
button:
- name: senseowifi_brew_coffee_normal
unique_id: uniqueid__senseowifi_brew_coffee_normal
icon: mdi:coffee
#
command_topic: "homie/senseo-wifi-rf21/machine/brew/set"
payload_press: "1cup"
#
availability_topic: "homie/senseo-wifi-rf21/$state"
payload_available: "ready"
payload_not_available: "lost"
- name: senseowifi_brew_coffee_double
unique_id: uniqueid__senseowifi_brew_coffee_double
icon: mdi:coffee
#
command_topic: "homie/senseo-wifi-rf21/machine/brew/set"
payload_press: "2cup"
#
availability_topic: "homie/senseo-wifi-rf21/$state"
payload_available: "ready"
payload_not_available: "lost"
##############################################################################
template:
- sensor:
- name: senseowifi_uptime_since
unique_id: uniqueid__senseowifi_uptime_since
state: >
{% if is_state("sensor.senseowifi_uptime", "unavailable") %}
"unavailable"
{% else %}
{{ ((as_timestamp(now() - timedelta(seconds=(states.sensor.senseowifi_uptime.state | int))) / 300) | round() * 300) | timestamp_local() }}
{% endif %}
icon: mdi:calendar-clock
device_class: timestamp
##############################################################################
homeassistant:
customize:
switch.senseowifi_power:
friendly_name: "SenseoWifi"
binary_sensor.senseowifi_out_of_water:
friendly_name: "SenseoWifi Wassertank leer Warnung"
binary_sensor.senseowifi_cup_available:
friendly_name: "SenseoWifi Tasse steht unter"
binary_sensor.senseowifi_cup_full:
friendly_name: "SenseoWifi Tasse voll"
sensor.senseowifi_brewed_size:
friendly_name: "SenseoWifi Zähler Kaffee-Brühungen (inkl. klein oder groß)"
sensor.senseowifi_opstate:
friendly_name: "SenseoWifi Operationszustand"
sensor.senseowifi_debug:
friendly_name: "SenseoWifi Debug-Nachrichten"
sensor.senseowifi_uptime:
friendly_name: "SenseoWifi Uptime"
sensor.senseowifi_rssi:
friendly_name: "SenseoWifi WLAN Signalstärke (RSSI)"
button.senseowifi_brew_coffee_normal:
friendly_name: "SenseoWifi Auslöser einfache Tasse brühen"
button.senseowifi_brew_coffee_double:
friendly_name: "SenseoWifi Auslöser große Tasse brühen"
sensor.senseowifi_uptime_since:
friendly_name: "SenseoWifi Letzter Neustart"
##############################################################################
input_boolean:
senseowifi_brew_double_automated:
name: "SenseoWifi Flag automatisch große Tasse brühen"
initial: off
icon: mdi:coffee
##############################################################################
automation:
- id: "1636231455732"
alias: Regel SenseoWifi ausschalten wenn zu lange im READY Zustand
trigger:
- platform: state
entity_id: sensor.senseowifi_opstate
to: "SENSEO_READY"
for:
minutes: 10
action:
- service: switch.turn_off
entity_id: switch.senseowifi_power
- service: mqtt.publish
data:
topic: "homie/senseo-wifi-rf21/machine/buzzer/set"
payload: "tone4"
##############################################################################
- id: "1611257542502"
alias: Regel SenseoWifi Erinnerungston bei voller Tasse
mode: single
trigger:
platform: state
entity_id: binary_sensor.senseowifi_cup_full
to: "on"
action:
- delay:
minutes: 3
- repeat:
while:
- condition: state
entity_id: binary_sensor.senseowifi_cup_full
state: "on"
- condition: state # deal with a known firmware bug
entity_id: binary_sensor.senseowifi_cup_available
state: "on"
sequence:
- service: mqtt.publish
data:
topic: "homie/senseo-wifi-rf21/machine/buzzer/set"
payload: "tone3"
- delay:
minutes: 1
##############################################################################
- id: "1611257542601"
alias: Regel SenseoWifi automatisch brühen (Schritt 1) Einschalten
trigger:
- platform: state
entity_id: input_boolean.senseowifi_brew_double_automated
to: "on"
condition:
- condition: state
entity_id: switch.senseowifi_power
state: "off"
action:
- service: mqtt.publish
data:
topic: "homie/senseo-wifi-rf21/machine/buzzer/set"
payload: "tone4"
- service: switch.turn_on
entity_id: switch.senseowifi_power
- id: "1611257542602"
alias: Regel SenseoWifi automatisch brühen (Schritt 2) Brühen starten
trigger:
- platform: state
entity_id: sensor.senseowifi_opstate
to: "SENSEO_READY"
for:
seconds: 1 # let states settle
- platform: state
entity_id: input_boolean.senseowifi_brew_double_automated
to: "on"
condition:
- condition: state
entity_id: switch.senseowifi_power
state: "on"
- condition: state
entity_id: sensor.senseowifi_opstate
state: "SENSEO_READY"
- condition: state
entity_id: binary_sensor.senseowifi_out_of_water
state: "off"
- condition: state
entity_id: binary_sensor.senseowifi_cup_available
state: "on"
- condition: state
entity_id: binary_sensor.senseowifi_cup_full
state: "off"
- condition: state
entity_id: input_boolean.senseowifi_brew_double_automated
state: "on"
action:
- service: mqtt.publish
data:
topic: "homie/senseo-wifi-rf21/machine/brew/set"
payload: "2cup"
- id: "1611257542603"
alias: Regel SenseoWifi automatisch brühen (Schritt 3) Ausschalten
trigger:
platform: state
entity_id: sensor.senseowifi_opstate
from: "SENSEO_BREWING"
for:
seconds: 1 # let states settle
condition:
- condition: state
entity_id: input_boolean.senseowifi_brew_double_automated
state: "on"
action:
- service: switch.turn_off
entity_id: switch.senseowifi_power
- id: "1611257542604"
alias: Regel SenseoWifi automatisch brühen (Schritt 4) Flag löschen
trigger:
platform: state
entity_id: switch.senseowifi_power
to: "off"
condition:
- condition: state
entity_id: input_boolean.senseowifi_brew_double_automated
state: "on"
action:
- service: input_boolean.turn_off
entity_id: input_boolean.senseowifi_brew_double_automated
- id: "1611257542605"
alias: Regel SenseoWifi automatisch brühen (Schritt 5) Buzzerbestätigung
trigger:
platform: state
entity_id: input_boolean.senseowifi_brew_double_automated
to: "off"
action:
- service: mqtt.publish
data:
topic: "homie/senseo-wifi-rf21/machine/buzzer/set"
payload: "tone4"
##############################################################################