-
Notifications
You must be signed in to change notification settings - Fork 0
/
sensors.yaml
811 lines (784 loc) · 26.8 KB
/
sensors.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
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
- platform: template
sensors:
temperature_degrees:
friendly_name: 'Temperature'
value_template: '{{states("input_number.temperature") | float(0)}}'
- platform: time_date
display_options:
- 'time'
- 'date'
- 'date_time'
- 'time_utc'
- platform: template
sensors:
# Zone Times - templated on history_stats sensors
zone1_time_today:
friendly_name: Zone 1 total watering time today
value_template: >
{{ states('sensor.greenhouse_valve_1_history_today') | float(0) * 60 | round }}
unit_of_measurement: minutes
icon_template: mdi:water
zone2_time_today:
friendly_name: Zone 2 total watering time today
value_template: >
{{ states('sensor.greenhouse_valve_2_history_today') | float(0) * 60 | round }}
unit_of_measurement: minutes
icon_template: mdi:water
zone3_time_today:
friendly_name: Zone 3 total watering time today
value_template: >
{{ states('sensor.greenhouse_valve_3_history_today') | float(0) * 60 | round }}
unit_of_measurement: minutes
icon_template: mdi:water
zone4_time_today:
friendly_name: Zone 4 total watering time today
value_template: >
{{ states('sensor.greenhouse_valve_4_history_today') | float(0) * 60 | round }}
unit_of_measurement: minutes
icon_template: mdi:water
# History sensors
# Zone Times
- platform: history_stats
name: greenhouse_valve_1_history_today
entity_id: switch.greenhouse_valve_1
state: 'on'
type: time
start: '{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: greenhouse_valve_1_history_yesterday
entity_id: switch.greenhouse_valve_1
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
hours: 24
- platform: history_stats
name: greenhouse_valve_1_history_week
entity_id: switch.greenhouse_valve_1
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 7
- platform: history_stats
name: greenhouse_valve_1_history_month
entity_id: switch.greenhouse_valve_1
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 30
- platform: history_stats
name: greenhouse_valve_1_history_year
entity_id: switch.greenhouse_valve_1
state: 'on'
type: time
start: '{{ now().replace(month=1).replace(day=1).replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: greenhouse_valve_1_history_alltime
entity_id: switch.greenhouse_valve_1
state: 'on'
type: time
start: '{{ 0 }}'
end: '{{ now() }}'
- platform: template
sensors:
greenhouse_valve_1_stats:
icon_template: >-
{% if is_state('switch.greenhouse_valve_1', 'on') %}
mdi:chart-line-stacked
{% else %}
mdi:chart-line
{% endif %}
value_template: >-
{{ state_attr('sensor.greenhouse_valve_1_history_today', 'value') }}
attribute_templates:
today: >-
{{ state_attr('sensor.greenhouse_valve_1_history_today', 'value') }}
yesterday: >-
{{ state_attr('sensor.greenhouse_valve_1_history_yesterday', 'value') }}
week: >-
{{ state_attr('sensor.greenhouse_valve_1_history_week', 'value') }}
month: >-
{{ state_attr('sensor.greenhouse_valve_1_history_month', 'value') }}
year: >-
{{ states('sensor.greenhouse_valve_1_history_year') + state_attr('sensor.greenhouse_valve_1_history_year', 'unit_of_measurement') }}
all: >-
{{ states('sensor.greenhouse_valve_1_history_alltime') + state_attr('sensor.greenhouse_valve_1_history_year', 'unit_of_measurement') }}
- platform: history_stats
name: greenhouse_valve_2_history_today
entity_id: switch.greenhouse_valve_2
state: 'on'
type: time
start: '{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: greenhouse_valve_2_history_yesterday
entity_id: switch.greenhouse_valve_2
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
hours: 24
- platform: history_stats
name: greenhouse_valve_2_history_week
entity_id: switch.greenhouse_valve_2
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 7
- platform: history_stats
name: greenhouse_valve_2_history_month
entity_id: switch.greenhouse_valve_2
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 30
- platform: history_stats
name: greenhouse_valve_2_history_year
entity_id: switch.greenhouse_valve_2
state: 'on'
type: time
start: '{{ now().replace(month=1).replace(day=1).replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: greenhouse_valve_2_history_alltime
entity_id: switch.greenhouse_valve_2
state: 'on'
type: time
start: '{{ 0 }}'
end: '{{ now() }}'
- platform: template
sensors:
greenhouse_valve_2_stats:
icon_template: >-
{% if is_state('switch.greenhouse_valve_2', 'on') %}
mdi:chart-line-stacked
{% else %}
mdi:chart-line
{% endif %}
value_template: >-
{{ state_attr('sensor.greenhouse_valve_2_history_today', 'value') }}
attribute_templates:
today: >-
{{ state_attr('sensor.greenhouse_valve_2_history_today', 'value') }}
yesterday: >-
{{ state_attr('sensor.greenhouse_valve_2_history_yesterday', 'value') }}
week: >-
{{ state_attr('sensor.greenhouse_valve_2_history_week', 'value') }}
month: >-
{{ state_attr('sensor.greenhouse_valve_2_history_month', 'value') }}
year: >-
{{ states('sensor.greenhouse_valve_2_history_year') + state_attr('sensor.greenhouse_valve_2_history_year', 'unit_of_measurement') }}
all: >-
{{ states('sensor.greenhouse_valve_2_history_alltime') + state_attr('sensor.greenhouse_valve_2_history_year', 'unit_of_measurement') }}
- platform: history_stats
name: greenhouse_valve_3_history_today
entity_id: switch.greenhouse_valve_3
state: 'on'
type: time
start: '{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: greenhouse_valve_3_history_yesterday
entity_id: switch.greenhouse_valve_3
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
hours: 24
- platform: history_stats
name: greenhouse_valve_3_history_week
entity_id: switch.greenhouse_valve_3
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 7
- platform: history_stats
name: greenhouse_valve_3_history_month
entity_id: switch.greenhouse_valve_3
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 30
- platform: history_stats
name: greenhouse_valve_3_history_year
entity_id: switch.greenhouse_valve_3
state: 'on'
type: time
start: '{{ now().replace(month=1).replace(day=1).replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: greenhouse_valve_3_history_alltime
entity_id: switch.greenhouse_valve_3
state: 'on'
type: time
start: '{{ 0 }}'
end: '{{ now() }}'
- platform: template
sensors:
greenhouse_valve_3_stats:
icon_template: >-
{% if is_state('switch.greenhouse_valve_3', 'on') %}
mdi:chart-line-stacked
{% else %}
mdi:chart-line
{% endif %}
value_template: >-
{{ state_attr('sensor.greenhouse_valve_3_history_today', 'value') }}
attribute_templates:
today: >-
{{ state_attr('sensor.greenhouse_valve_3_history_today', 'value') }}
yesterday: >-
{{ state_attr('sensor.greenhouse_valve_3_history_yesterday', 'value') }}
week: >-
{{ state_attr('sensor.greenhouse_valve_3_history_week', 'value') }}
month: >-
{{ state_attr('sensor.greenhouse_valve_3_history_month', 'value') }}
year: >-
{{ states('sensor.greenhouse_valve_3_history_year') + state_attr('sensor.greenhouse_valve_3_history_year', 'unit_of_measurement') }}
all: >-
{{ states('sensor.greenhouse_valve_3_history_alltime') + state_attr('sensor.greenhouse_valve_3_history_year', 'unit_of_measurement') }}
- platform: history_stats
name: greenhouse_valve_4_history_today
entity_id: switch.greenhouse_valve_4
state: 'on'
type: time
start: '{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: greenhouse_valve_4_history_yesterday
entity_id: switch.greenhouse_valve_4
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
hours: 24
- platform: history_stats
name: greenhouse_valve_4_history_week
entity_id: switch.greenhouse_valve_4
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 7
- platform: history_stats
name: greenhouse_valve_4_history_month
entity_id: switch.greenhouse_valve_4
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 30
- platform: history_stats
name: greenhouse_valve_4_history_year
entity_id: switch.greenhouse_valve_4
state: 'on'
type: time
start: '{{ now().replace(month=1).replace(day=1).replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: greenhouse_valve_4_history_alltime
entity_id: switch.greenhouse_valve_4
state: 'on'
type: time
start: '{{ 0 }}'
end: '{{ now() }}'
- platform: template
sensors:
greenhouse_valve_4_stats:
icon_template: >-
{% if is_state('switch.greenhouse_valve_4', 'on') %}
mdi:chart-line-stacked
{% else %}
mdi:chart-line
{% endif %}
value_template: >-
{{ state_attr('sensor.greenhouse_valve_4_history_today', 'value') }}
attribute_templates:
today: >-
{{ state_attr('sensor.greenhouse_valve_4_history_today', 'value') }}
yesterday: >-
{{ state_attr('sensor.greenhouse_valve_4_history_yesterday', 'value') }}
week: >-
{{ state_attr('sensor.greenhouse_valve_4_history_week', 'value') }}
month: >-
{{ state_attr('sensor.greenhouse_valve_4_history_month', 'value') }}
year: >-
{{ states('sensor.greenhouse_valve_4_history_year') + state_attr('sensor.greenhouse_valve_4_history_year', 'unit_of_measurement') }}
all: >-
{{ states('sensor.greenhouse_valve_4_history_alltime') + state_attr('sensor.greenhouse_valve_4_history_year', 'unit_of_measurement') }}
- platform: history_stats
name: greenhouse_valve_5_history_today
entity_id: switch.greenhouse_valve_5
state: 'on'
type: time
start: '{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: greenhouse_valve_5_history_yesterday
entity_id: switch.greenhouse_valve_5
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
hours: 25
- platform: history_stats
name: greenhouse_valve_5_history_week
entity_id: switch.greenhouse_valve_5
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 7
- platform: history_stats
name: greenhouse_valve_5_history_month
entity_id: switch.greenhouse_valve_5
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 30
- platform: history_stats
name: greenhouse_valve_5_history_year
entity_id: switch.greenhouse_valve_5
state: 'on'
type: time
start: '{{ now().replace(month=1).replace(day=1).replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: greenhouse_valve_5_history_alltime
entity_id: switch.greenhouse_valve_5
state: 'on'
type: time
start: '{{ 0 }}'
end: '{{ now() }}'
- platform: template
sensors:
greenhouse_valve_5_stats:
icon_template: >-
{% if is_state('switch.greenhouse_valve_5', 'on') %}
mdi:chart-line-stacked
{% else %}
mdi:chart-line
{% endif %}
value_template: >-
{{ state_attr('sensor.greenhouse_valve_5_history_today', 'value') }}
attribute_templates:
today: >-
{{ state_attr('sensor.greenhouse_valve_5_history_today', 'value') }}
yesterday: >-
{{ state_attr('sensor.greenhouse_valve_5_history_yesterday', 'value') }}
week: >-
{{ state_attr('sensor.greenhouse_valve_5_history_week', 'value') }}
month: >-
{{ state_attr('sensor.greenhouse_valve_5_history_month', 'value') }}
year: >-
{{ states('sensor.greenhouse_valve_5_history_year') + state_attr('sensor.greenhouse_valve_5_history_year', 'unit_of_measurement') }}
all: >-
{{ states('sensor.greenhouse_valve_5_history_alltime') + state_attr('sensor.greenhouse_valve_5_history_year', 'unit_of_measurement') }}
- platform: template
sensors:
vacuum_status:
friendly_name: Status
value_template: 'Status: {{ state_attr("vacuum.dalek", "status") }}'
icon_template: >
{% set val = state_attr("vacuum.dalek", "status") %}
{% if val == 'Charging' %}
mdi:battery-charging
{% elif val == 'Cleaning' %}
mdi:move-resize
{% elif val == 'Returning home' %}
mdi:keyboard-return
{% elif val == 'Idle' %}
mdi:dots-horizontal
{% elif val == 'Paused' %}
mdi:pause-circle
{% else %}
mdi:help-circle
{% endif %}
vacuum_fan_speed:
value_template: 'Mode: {{ state_attr("vacuum.dalek", "fan_speed") }}'
icon_template: 'mdi:speedometer'
vacuum_battery:
friendly_name: Vacuum Battery
value_template: 'Battery: {{ state_attr("vacuum.dalek", "battery_level") }}'
unit_of_measurement: '%'
icon_template: '{{ state_attr("vacuum.dalek", "battery_icon") }}'
vacuum_cleaning_time:
friendly_name: Time of Last Cycle
value_template: >-
{% set s = states('sensor.dalek_last_clean_duration')|int(0) %}
{{ '%02d:%02d' % ((s/3600)|int(0), (s%3600)/60) }}
icon_template: 'mdi:timer'
vacuum_cleaned_area:
friendly_name: Area of Last Cycle
unit_of_measurement: 'm ²'
value_template: '{{ state_attr("vacuum.dalek", "cleaned_area") }}'
icon_template: 'mdi:ruler'
vacuum_cleanmainbrush:
friendly_name: Replace main brush
unit_of_measurement: 'h'
value_template: >-
Main Brush:
{% set s = states('sensor.dalek_main_brush_left')|int(0) %}
{{ '%02d:%02d' % ((s/3600)|int(0), (s%3600)/60) }}
icon_template: 'mdi:screwdriver'
vacuum_cleansidebrush:
friendly_name: Replace side brush
unit_of_measurement: 'h'
value_template: >-
Side Brush:
{% set s = states('sensor.dalek_side_brush_left')|int(0) %}
{{ '%02d:%02d' % ((s/3600)|int(0), (s%3600)/60) }}
icon_template: 'mdi:screwdriver'
vacuum_cleanfilter:
friendly_name: Replace filter
unit_of_measurement: 'h'
value_template: >-
Filter:
{% set s = states('sensor.dalek_filter_left')|int(0) %}
{{ '%02d:%02d' % ((s/3600)|int(0), (s%3600)/60) }}
icon_template: 'mdi:screwdriver'
vacuum_sensordirtyleft:
friendly_name: Replace filter
unit_of_measurement: 'h'
value_template: >-
Filter:
{% set s = states('sensor.dalek_sensor_dirty_left')|int(0) %}
{{ '%02d:%02d' % ((s/3600)|int(0), (s%3600)/60) }}
icon_template: 'mdi:screwdriver'
vacuum_do_not_disturb:
friendly_name: Do Not Disturb
value_template: '{{ state_attr("vacuum.dalek", "do_not_disturb") }}'
icon_template: >
{% set val = state_attr("vacuum.dalek", "do_not_disturb") %}
{% if val == 'on' %}
mdi:do-not-disturb
{% else %}
mdi:do-not-disturb-off
{% endif %}
vacuum_operation:
value_template: 'Operation'
vacuum_accessories:
value_template: 'Maintenance'
- platform: template
sensors:
next_run_zone_1:
friendly_name: 'Next Run'
value_template: >-
{% if states('input_select.zone_1_schedule') != 'Zone Off' %}
{{ (as_timestamp(states.input_datetime.zone_1_next_run_time.state)) | timestamp_custom("%a %d %h at %H:%M") }}
{% else %}
None
{% endif %}
next_run_zone_2:
friendly_name: 'Next Run'
value_template: >-
{% if states('input_select.zone_2_schedule') != 'Zone Off' %}
{{ (as_timestamp(states.input_datetime.zone_2_next_run_time.state)) | timestamp_custom("%a %d %h at %H:%M") }}
{% else %}
None
{% endif %}
next_run_zone_3:
friendly_name: 'Next Run'
value_template: >-
{% if states('input_select.zone_3_schedule') != 'Zone Off' %}
{{ (as_timestamp(states.input_datetime.zone_3_next_run_time.state)) | timestamp_custom("%a %d %h at %H:%M") }}
{% else %}
None
{% endif %}
next_run_zone_4:
friendly_name: 'Next Run'
value_template: >-
{% if states('input_select.zone_4_schedule') != 'Zone Off' %}
{{ (as_timestamp(states.input_datetime.zone_4_next_run_time.state)) | timestamp_custom("%a %d %h at %H:%M") }}
{% else %}
None
{% endif %}
#- platform: zoneminder
- platform: afvalbeheer
wastecollector: RecycleApp
resources:
- gft
- groenafval
- grofvuil
- kga mobiel
- papier
- pmd
- restafval
postcode: !secret ophaalkalender_postcode
streetname: !secret ophaalkalender_streetname
upcomingsensor: 1
builtinicons: 1
- platform: template
sensors:
house_mode:
friendly_name: House Mode
value_template: >-
{% if is_state('input_boolean.kids_home_alone', 'on') %}
kids home alone
{% elif is_state('binary_sensor.guest_mode', 'on') %}
guest
{% elif is_state('binary_sensor.no_one_home', 'on') %}
away
{% elif is_state('input_boolean.vacation_mode', 'on') %}
vacation
{% elif is_state('binary_sensor.night_mode', 'on') %}
night
{% else %}
home
{% endif %}
icon_template: >-
{% if is_state('input_boolean.kids_home_alone', 'on') %}
mdi:home-circle-outline
{% elif is_state('binary_sensor.guest_mode', 'on') %}
mdi:alpha-g
{% elif is_state('binary_sensor.night_mode', 'on') %}
mdi:weather-night
{% elif is_state('binary_sensor.no_one_home', 'on') %}
mdi:home-outline
{% elif is_state('input_boolean.vacation_mode', 'on') %}
mdi:beach
{% else %}
mdi:home
{% endif %}
oprit_last_motion:
friendly_name: Oprit Last Motion
value_template: >-
{{ (as_timestamp(states.input_datetime.oprit_last_motion.state)) | timestamp_custom('%a %d %h at %H:%M') }}
oprit_last_motion_event:
friendly_name: Oprit Last Motion Event
value_template: >-
{{ "%02d" % (states('input_number.oprit_last_motion_event') |int (0) ) }}
oprit_last_cctv_motion:
friendly_name: Oprit Last CCTV Motion
value_template: >-
{{ (as_timestamp(states.input_datetime.oprit_last_cctv_motion.state)) | timestamp_custom('%a %d %h at %H:%M') }}
oprit_last_cctv_motion_event:
friendly_name: Oprit Last CCTV Motion Event
value_template: >-
{{ "%02d" % (states('input_number.oprit_last_cctv_motion_event') |int (0) ) }}
- platform: history_stats
name: Verwarmen Vandaag
entity_id: sensor.operating_state
state: 'heating'
type: time
start: '{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: Verwarmen Gisteren
entity_id: sensor.operating_state
state: 'heating'
type: time
end: '{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}'
duration:
hours: 24
- platform: history_stats
name: Verwarmen 2 Dagen Geleden
entity_id: sensor.operating_state
state: 'heating'
type: time
end: '{{ as_timestamp( now().replace(hour=0).replace(minute=0).replace(second=0) ) - 86400 }}'
duration:
hours: 24
- platform: history_stats
name: Verwarmen Voorbij Week
entity_id: sensor.operating_state
state: 'heating'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 7
- platform: history_stats
name: flame_active_history_today
entity_id: binary_sensor.10_040239_flame_active
state: 'on'
type: time
start: '{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: flame_active_history_yesterday
entity_id: binary_sensor.10_040239_flame_active
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
hours: 25
- platform: history_stats
name: flame_active_history_week
entity_id: binary_sensor.10_040239_flame_active
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 7
- platform: history_stats
name: flame_active_history_month
entity_id: binary_sensor.10_040239_flame_active
state: 'on'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 30
- platform: history_stats
name: flame_active_history_year
entity_id: binary_sensor.10_040239_flame_active
state: 'on'
type: time
start: '{{ now().replace(month=1).replace(day=1).replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: flame_active_history_alltime
entity_id: binary_sensor.10_040239_flame_active
state: 'on'
type: time
start: '{{ 0 }}'
end: '{{ now() }}'
- platform: history_stats
name: heating_history_today
entity_id: sensor.operating_state
state: 'heating'
type: time
start: '{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: heating_history_yesterday
entity_id: sensor.operating_state
state: 'heating'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
hours: 25
- platform: history_stats
name: heating_history_week
entity_id: sensor.operating_state
state: 'heating'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 7
- platform: history_stats
name: heating_history_month
entity_id: sensor.operating_state
state: 'heating'
type: time
end: '{{ now().replace(hour=0, minute=0, second=0) }}'
duration:
days: 30
- platform: history_stats
name: heating_history_year
entity_id: sensor.operating_state
state: 'heating'
type: time
start: '{{ now().replace(month=1).replace(day=1).replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
- platform: history_stats
name: heating_history_alltime
entity_id: sensor.operating_state
state: 'heating'
type: time
start: '{{ 0 }}'
end: '{{ now() }}'
- platform: template
sensors:
ibbq_probe_1_grill_alert_temp:
value_template: >-
{% if (states('sensor.ibbq_temperature_probe_1') | int > 0) and (states('sensor.ibbq_temperature_probe_1') |int (0) ) < (states('input_number.grill_alert_low') |int (0) ) or (states('sensor.ibbq_temperature_probe_1') |int (0) ) > (states('input_number.grill_alert_high') |int (0) ) %}
Alert
{% else %}
Normal
{% endif %}
friendly_name: Grill (Probe 1) Target Alert
icon_template: >-
{% if (states('sensor.ibbq_temperature_probe_1') |int (0) ) < (states('input_number.grill_alert_low') |int (0) ) or (states('sensor.ibbq_temperature_probe_1') |int (0) ) > (states('input_number.grill_alert_high') |int (0) ) %}
mdi:alert-circle
{% else %}
mdi:alert-circle-check
{% endif %}
ibbq_probe_2_target_alert_temp:
value_template: >-
{% if (states('sensor.ibbq_temperature_probe_2') |int (0) ) >= (states('input_number.grill_probe_2_target') |int (0) ) %}
Alert
{% else %}
Normal
{% endif %}
friendly_name: Probe 2 Target Alert
icon_template: >-
{% if (states('sensor.ibbq_temperature_probe_2') |int (0) ) >= (states('input_number.grill_probe_2_target') |int (0) ) %}
mdi:alert-circle
{% else %}
mdi:alert-circle-check
{% endif %}
ibbq_probe_3_target_alert_temp:
value_template: >-
{% if (states('sensor.ibbq_temperature_probe_3') |int (0) ) >= (states('input_number.grill_probe_3_target') |int (0) ) %}
Alert
{% else %}
Normal
{% endif %}
friendly_name: Probe 3 Target Alert
icon_template: >-
{% if (states('sensor.ibbq_temperature_probe_3') |int (0) ) >= (states('input_number.grill_probe_3_target') |int (0) ) %}
mdi:alert-circle
{% else %}
mdi:alert-circle-check
{% endif %}
ibbq_probe_4_target_alert_temp:
value_template: >-
{% if (states('sensor.ibbq_temperature_probe_4') |int (0) ) >= (states('input_number.grill_probe_4_target') |int (0) ) %}
Alert
{% else %}
Normal
{% endif %}
friendly_name: Probe 4 Target Alert
icon_template: >-
{% if (states('sensor.ibbq_temperature_probe_4') |int (0) ) >= (states('input_number.grill_probe_4_target') |int (0) ) %}
mdi:alert-circle
{% else %}
mdi:alert-circle-check
{% endif %}
- platform: min_max
name: "Buiten Gemiddelde Temperatuur"
type: mean
round_digits: 1
entity_ids:
- sensor.motion_voordeur_temperature
- sensor.achterdeur_buiten_temperature
- platform: statistics
name: "Current Power Avg Over Last 24 Hours"
entity_id: sensor.current_power
state_characteristic: mean
max_age:
hours: 24
sampling_size: 86400
precision: 3
- platform: sql
db_url: !secret db_url
scan_interval: 3600
queries:
- name: MariaDB Database Size
query: 'SELECT table_schema "homeassistant", Round(Sum(data_length + index_length) / POWER(1024,2), 1) "value" FROM information_schema.tables WHERE table_schema="homeassistant" GROUP BY table_schema;'
column: "value"
unit_of_measurement: MB
- platform: influxdb
host: a0d7b954-influxdb
port: 8086
username: !secret influxdb-username
password: !secret influxdb-password
scan_interval: 3600
queries:
- name: InfluxDB Database Size
unit_of_measurement: MB
value_template: "{{ (value | float(0) / 1024 /1024) | round(1) }}"
group_function: sum
measurement: '"monitor"."shard"'
database: _internal
where: '"database"=''homeassistant'' AND time > now() - 5m'
field: diskBytes