-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathautomations.yaml
577 lines (577 loc) · 13.4 KB
/
automations.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
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
- id: '1621927850930'
alias: "\U0001F4F9 Turn on \"privacy mode\" of camera when people at home"
description: ''
trigger:
- platform: state
entity_id: binary_sensor.no_one_home
from: 'on'
to: 'off'
condition: []
action:
- service: switch.turn_on
data: {}
target:
entity_id: switch.g5_flex_privacy_mode
mode: single
- id: '1621928552564'
alias: "\U0001F4F9 Turn off \"privacy mode\" of camera when no people at home"
description: ''
trigger:
- platform: state
entity_id: binary_sensor.no_one_home
from: 'off'
to: 'on'
condition: []
action:
- service: switch.turn_off
data: {}
target:
entity_id: switch.g5_flex_privacy_mode
mode: single
- id: 0c363e5fa5164f67b91bafc26f04de05
alias: ♻️ Send garbage reminder
trigger:
- platform: state
entity_id:
- sensor.recycleapp_tomorrow
condition:
- condition: template
value_template: '{{ states.sensor.recycleapp_tomorrow.state != ''None'' }}'
action:
- delay:
hours: 18
minutes: 0
seconds: 0
milliseconds: 0
enabled: true
- service: notify.lode_devices
data:
title: ♻️ Afvalophaling
message: 'Morgen worden volgende zaken opgehaald: {{ states.sensor.recycleapp_tomorrow.state
}}'
mode: single
- id: '1632921047367'
alias: "⛱ \U0001F327 Close awning and screen when rain predicted"
description: ''
trigger:
- platform: numeric_state
entity_id: sensor.buienalarm_precipitation_forecast_average
above: '0.1'
condition:
- condition: or
conditions:
- condition: numeric_state
entity_id: cover.screen
attribute: current_position
below: 100
- condition: state
entity_id: cover.awning
state: open
action:
- service: cover.close_cover
target:
entity_id: cover.awning
data: {}
- service: cover.open_cover
data: {}
target:
entity_id: cover.screen
- service: notify.lode_devices
data:
title: "\U0001F327 Luifel en screen gesloten door regen"
message: De luifel en screen werden automatisch gesloten omdat er regen werd
voorspeld in de komende 15 minuten.
mode: single
- id: '1632928778074'
alias: "⛱ \U0001F699 When nobody at home close awning"
description: ''
trigger:
- platform: state
entity_id:
- binary_sensor.no_one_home
from: 'off'
to: 'on'
for:
hours: 0
minutes: 30
seconds: 0
condition:
- condition: state
entity_id: cover.awning
state: open
action:
- service: cover.close_cover
target:
entity_id: cover.awning
data: {}
mode: single
- id: '1636128250859'
alias: "\U0001F634 Inform kids about bedtime"
description: ''
trigger:
- platform: time
at: input_datetime.bedtime_report_time
condition:
- condition: state
entity_id: binary_sensor.no_one_home
state: 'off'
- condition: time
weekday:
- mon
- tue
- wed
- thu
- sun
action:
- service: script.announce_message
data:
message: Het is tijd om te gaan slapen! Naar boven, pyjama aan en tanden poetsen!
Hup hup.
mode: single
- id: '1636129149096'
alias: "\U0001F4DA Inform kids about homework"
description: ''
trigger:
- platform: time
at: input_datetime.homework_report_time
condition:
- condition: state
entity_id: binary_sensor.no_one_home
state: 'off'
- condition: time
weekday:
- mon
- tue
- thu
action:
- service: script.cast_message
data:
message: Tijd om huiswerk te maken!
mode: single
- id: '1636131173499'
alias: "\U0001F4F5 Device offline notification"
trigger:
- platform: state
entity_id:
- light.led_living
- light.group_dining_room
- light.group_dining_table
- light.group_kitchen
- light.group_office_wall
- light.group_office_desk
- light.led_office_mood
- light.group_tv_spots
- light.led_strip_tv
- light.group_fridge
to: unavailable
for:
minutes: 5
action:
- service: notify.lode_devices
data:
title: Device offline detected!
message: "\U0001F4F5 The device {{ state_attr(trigger.to_state.entity_id, 'friendly_name')
}} is offline!"
data:
priority: high
ttl: 0
color: red
mode: parallel
- id: '1637251279206'
alias: "\U0001F6AA Instruct kids to leave for school"
description: ''
trigger:
- platform: time
at: input_datetime.leave_for_school_report_time
condition:
- condition: state
entity_id: binary_sensor.no_one_home
state: 'off'
- condition: time
weekday:
- mon
- tue
- wed
- thu
- fri
action:
- service: script.cast_message
data:
message: Tijd om je klaar te maken voor school!
mode: single
- id: '1638859694197'
alias: "\U0001F976 Fridge smart plug turned off notification"
description: ''
trigger:
- platform: state
to: 'off'
for:
hours: 0
minutes: 0
seconds: 0
entity_id: switch.smart_plug_fridge
- platform: state
to: 'off'
for:
hours: 1
minutes: 0
seconds: 0
entity_id:
- switch.smart_plug_fridge
condition: []
action:
- service: notify.lode_devices
data:
title: Device offline detected!
message: "\U0001F976 The fridge smart plug was turned off!"
data:
priority: high
ttl: 0
color: red
mode: parallel
max: 10
- id: '1638957877743'
alias: "\U0001F4F9 Turn off \"privacy mode\" at night"
description: ''
trigger:
- platform: state
entity_id: binary_sensor.night
from: 'off'
to: 'on'
condition: []
action:
- service: switch.turn_off
data: {}
target:
entity_id: switch.g5_flex_privacy_mode
mode: single
- id: '1638957990044'
alias: "\U0001F4F9 Turn on \"privacy mode\" at day"
description: ''
trigger:
- platform: state
entity_id: binary_sensor.day
from: 'off'
to: 'on'
condition: []
action:
- service: switch.turn_on
data: {}
target:
entity_id: switch.g5_flex_privacy_mode
mode: single
- id: '1650973895443'
alias: "\U0001F699 Ellen leaves from work"
description: ''
trigger:
- platform: zone
entity_id: person.ellen_ophalvens
zone: zone.okra
event: leave
condition: []
action:
- service: notify.lode_devices
data:
message: Ellen vertrok zonet van haar werk. Over {{ states.sensor.okra_home.state
}} minuten is ze thuis.
title: "\U0001F699 Ellen op weg naar huis!"
mode: single
- id: '1657788008411'
alias: "⛱ \U0001F32C Close awning when a lot of wind predicted"
description: ''
trigger:
- platform: numeric_state
entity_id:
- weather.home
above: 30
attribute: wind_speed
condition:
- condition: state
entity_id: cover.awning
state: open
action:
- target:
entity_id: cover.awning
data: {}
action: cover.close_cover
- data:
message: De luifel werd gesloten omdat er hardere wind wordt voorspeld.
title: "\U0001F32C Luifel gesloten door wind"
action: notify.lode_devices
mode: single
- id: '1657790977221'
alias: ⛱ ☀️ Open awning when too bright sunlight and not windy and before 15h30
description: ''
trigger:
- platform: numeric_state
entity_id: sensor.outdoor_luminance
above: 70000
- platform: time
at: 08:15:00
condition:
- condition: numeric_state
entity_id: weather.home
below: '20'
attribute: wind_speed
- condition: state
state: closed
entity_id: cover.awning
- condition: time
before: '15:30:00'
action:
- service: cover.set_cover_position
data:
position: 60
target:
entity_id: cover.awning
- service: notify.lode_devices
data:
message: Luifel wordt automatisch geopend omdat helderheid te hoog is (en geen
harde wind).
title: ⛱ Luifel wordt geopend
mode: single
- id: '1657791504056'
alias: ⛱ ☀️ Close screen when too bright sunlight
description: ''
trigger:
- platform: numeric_state
entity_id: sensor.outdoor_luminance
above: 100000
condition:
- condition: state
entity_id: cover.screen
state: open
action:
- service: cover.close_cover
data: {}
target:
entity_id: cover.screen
- service: notify.lode_devices
data:
message: Screen wordt automatisch gesloten omdat helderheid te hoog is.
title: ⛱ Screen wordt gesloten
mode: single
- id: '1657791651788'
alias: ⛱ ⏱ Open screen at 21h00
description: ''
trigger:
- platform: time
at: '21:00:00'
condition:
- condition: numeric_state
entity_id: cover.screen
attribute: current_position
below: '100'
action:
- service: cover.open_cover
data: {}
target:
entity_id: cover.screen
- service: notify.lode_devices
data:
title: ⛱ Screen openen (avond)
message: Screen wordt automatisch geopend omdat het avond is.
mode: single
- id: '1657793011369'
alias: ⛱ ⏱ Close awning at 15h30
description: ''
trigger:
- platform: time
at: '15:30:00'
condition:
- condition: state
entity_id: cover.awning
state: open
action:
- service: cover.close_cover
data: {}
target:
entity_id: cover.awning
- service: notify.lode_devices
data:
title: ⛱ Luifel gesloten (schaduw)
message: Luifel wordt wordt automatisch gesloten omdat er genoeg schaduw is.
mode: single
- id: '1663504824526'
alias: ☀️⚡️⬆️ Upload solar panel production to EnergyID
description: ''
trigger:
- platform: time_pattern
hours: '23'
minutes: '59'
seconds: '0'
condition: []
action:
- service: energy_id.set_meter_reading
data:
device_id: 40beff9400472b34909cdd9d8852d748
value: '{{ states(''sensor.inverter_solar_energy'') }}'
date: '{{ now().isoformat() }}'
mode: single
- id: '1663759782665'
alias: Dishwasher finished
description: ''
trigger:
- platform: numeric_state
entity_id:
- sensor.smart_plug_dishwasher_power
below: 100
for:
hours: 30
minutes: 0
seconds: 0
condition: []
action:
- service: notify.parents_devices
data:
title: "\U0001F37D️ The dishwasher is ready"
message: The dishwasher has finished its cleaning cycle.
mode: single
- id: '1663760300053'
alias: Washing machine finished
description: ''
trigger:
- platform: numeric_state
entity_id:
- sensor.smart_plug_washer_power
below: 500
for:
hours: 0
minutes: 15
seconds: 0
condition: []
action:
- service: notify.parents_devices
data:
title: "\U0001F9FA \U0001FAE7 Washing machine ready"
message: The washing machine has finished its cycle.
mode: single
- id: '1663760560002'
alias: Dryer finished
description: ''
trigger:
- platform: numeric_state
entity_id:
- sensor.smart_plug_dryer_power
below: 500
for:
hours: 0
minutes: 30
seconds: 0
condition: []
action:
- service: notify.parents_devices
data:
title: "\U0001F455 The dryer is ready"
message: The dryer has finished its cycle.
mode: single
- id: '1666771838886'
alias: "\U0001F30D Warn when internet connection offline"
description: ''
trigger:
- platform: state
entity_id:
- binary_sensor.internet
from: 'on'
to: 'off'
condition: []
action:
- service: notify.lode_devices
data:
message: "\U0001F30D The internet connection is offline!"
data:
priority: high
ttl: 0
color: red
title: Internet connection offline!
mode: parallel
- id: '1666771910607'
alias: "\U0001F30D Inform when internet connection has been restored"
description: ''
trigger:
- platform: state
entity_id:
- binary_sensor.internet
from: 'off'
to: 'on'
condition: []
action:
- service: notify.lode_devices
data:
title: Internet connectivity has been restored.
message: "\U0001F30D The internet connection is online again!"
mode: parallel
- id: '1673380802036'
alias: Set dark theme when sun sets
description: ''
trigger:
- platform: sun
event: sunset
condition: []
action:
- service: frontend.set_theme
data:
mode: dark
name: Mushroom Custom
mode: single
- id: '1673380823820'
alias: Set light theme when sun rises
description: ''
trigger:
- platform: sun
event: sunrise
condition: []
action:
- service: frontend.set_theme
data:
mode: light
name: Mushroom Custom
mode: single
- id: '1684871922041'
alias: "\U0001F440 Send notification when privacy mode off"
description: ''
trigger:
- platform: state
entity_id:
- switch.g5_flex_privacy_mode
from: 'on'
to: 'off'
condition: []
action:
- service: notify.lode_devices
data:
message: Privacy mode of the Tapo webcam was disabled.
title: "\U0001F440 Privacy mode disabled"
mode: single
- id: '1708671176465'
alias: "\U0001F976 Freezer smart plug turned off notification"
description: ''
trigger:
- platform: state
to: 'off'
for:
hours: 0
minutes: 0
seconds: 0
entity_id:
- switch.smart_plug_freezer
- platform: state
to: 'off'
for:
hours: 1
minutes: 0
seconds: 0
entity_id:
- switch.smart_plug_freezer
condition: []
action:
- service: notify.lode_devices
data:
title: Device offline detected!
message: "\U0001F976 The freezer smart plug was turned off!"
data:
priority: high
ttl: 0
color: red
mode: parallel
max: 10