-
Notifications
You must be signed in to change notification settings - Fork 11
/
heatingpump_en_prod.yaml
1175 lines (1071 loc) · 33 KB
/
heatingpump_en_prod.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
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
esphome:
name: heatingpump
platform: ESP32
board: nodemcu-32s
includes:
- stiebeltools/ElsterTable.h
- stiebeltools/KElsterTable.h
- stiebeltools/KElsterTable.cpp
- stiebeltools/NUtils.h
- stiebeltools/NUtils.cpp
- stiebeltools/NTypes.h
- stiebeltools/heatingpump.h
api:
encryption:
key: !secret api_encryption_key
logger:
level: INFO
ota:
- platform: esphome
password: !secret ota_password
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
manual_ip:
static_ip: !secret ip_address
gateway: !secret ip_gateway
subnet: !secret ip_mask
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "Heatpump Fallback Hotspot"
password: !secret ap_ssid_fallback
captive_portal: null
# FIXME: Need to translate - Adrien
# select:
# - platform: template
# name: PROGRAMMSCHALTER_SET
# id: PROGRAMMSCHALTER_SET
# options:
# - Notbetrieb
# - Bereitschaft
# - Automatik
# - Tagbetrieb
# - Absenkbetrieb
# - Warmwasser
# - Unbekannt
# initial_option: Unbekannt
# optimistic: true
# on_value:
# then:
# - lambda: |-
# // Prüfe ob Dropdown nicht auf Unbekannt steht
# const char* auswahl = id(PROGRAMMSCHALTER_SET).state.c_str();
# if(strcmp(auswahl, "Unbekannt") != 0) {
# writeSignal(&CanMembers[cm_manager], GetElsterIndex("PROGRAMMSCHALTER"), auswahl);
# readSignal(&CanMembers[cm_manager], GetElsterIndex("PROGRAMMSCHALTER"));
# }
# return;
sensor:
### COP
- platform: template
name: "COP value heating"
id: cop_heater
unit_of_measurement: "a.u."
icon: "mdi:chart-bell-curve-cumulative"
device_class: "power_factor"
state_class: "measurement"
accuracy_decimals: 2
- platform: template
name: "COP value hot water"
id: cop_water
unit_of_measurement: "a.u."
icon: "mdi:chart-bell-curve-cumulative"
device_class: "power_factor"
state_class: "measurement"
accuracy_decimals: 2
- platform: template
name: "Total COP value"
id: cop_total
unit_of_measurement: "a.u."
icon: "mdi:chart-bell-curve-cumulative"
device_class: "power_factor"
state_class: "measurement"
accuracy_decimals: 2
### FROM PUMP
- platform: template
name: OUTSIDE_TEMP
id: OUTSIDE_TEMP
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("OUTSIDE_TEMP"));
return {};
- platform: template
name: RETURN_FLOW_INTERNAL_TEMP
id: RETURN_FLOW_INTERNAL_TEMP
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("RETURN_FLOW_INTERNAL_TEMP"));
return {};
# HK1 - Heating Circuit Basement
- platform: template
name: FLOW_INTERNAL_TEMP_HK1
id: FLOW_INTERNAL_TEMP_HK1
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("FLOW_INTERNAL_TEMP_HK1"));
return {};
# HK1 - Heating Circuit Basement
- platform: template
name: FLOW_SETPOINT_TEMP_HK1
id: FLOW_SETPOINT_TEMP_HK1
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 30sec
lambda: |-
readSignal(&CanMembers[cm_fe7x], GetElsterIndex("FLOW_SETPOINT_TEMP"));
return {};
- platform: template
name: STORAGE_TANK_INTERNAL_TEMP
id: STORAGE_TANK_INTERNAL_TEMP
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("STORAGE_TANK_INTERNAL_TEMP"));
return {};
- platform: template
name: SOURCE_ACTUAL
id: SOURCE_ACTUAL
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("SOURCE_ACTUAL"));
return {};
- platform: template
name: HOT_GAS_TEMP
id: HOT_GAS_TEMP
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("HOT_GAS_TEMP"));
return {};
- platform: template
name: AUXILIARY_BOILER_SETPOINT
id: AUXILIARY_BOILER_SETPOINT
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("AUXILIARY_BOILER_SETPOINT"));
return {};
# Eco Temperature for DHW
- platform: template
name: SET_STORAGE_TANK_SETPOINT_ECO
id: SET_STORAGE_TANK_SETPOINT_TEMPERATURE2
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("SET_STORAGE_TANK_SETPOINT_TEMPERATURE2"));
return {};
- platform: template
name: HEATING_RETURN_ACTUAL
id: HEATING_RETURN_ACTUAL
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("HEATING_RETURN_ACTUAL"));
return {};
# Température Ballon Tampon cible
- platform: template
name: BUFFER_SETPOINT
id: BUFFER_SETPOINT
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("BUFFER_SETPOINT"));
return {};
# Température Ballon Tampon réel
- platform: template
name: BUFFER_TEMP_BOTTOM1
id: BUFFER_TEMP_BOTTOM1
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("BUFFER_TEMP_BOTTOM1"));
return {};
- platform: template
name: CIRCUIT_PRESSURE
id: CIRCUIT_PRESSURE
unit_of_measurement: bar
device_class: pressure
state_class: measurement
accuracy_decimals: 2
update_interval: 1min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("CIRCUIT_PRESSURE"));
return {};
- platform: template
name: SOURCE_PRESSURE
id: SOURCE_PRESSURE
unit_of_measurement: bar
device_class: pressure
state_class: measurement
accuracy_decimals: 2
update_interval: 1min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("SOURCE_PRESSURE"));
return {};
- platform: template
name: FLOW_RATE
id: FLOW_RATE
icon: mdi:waves-arrow-right
unit_of_measurement: l/min
state_class: measurement
accuracy_decimals: 2
update_interval: 1min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("FLOW_RATE"));
return {};
## POWER METRICS HEATING
- platform: template
name: ELECTRICITY_INTAKE_HEATING_DAY_WH
id: ELECTRICITY_INTAKE_HEATING_DAY_WH
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("ELECTRICITY_INTAKE_HEATING_DAY_WH"));
return {};
- platform: template
name: ELECTRICITY_INTAKE_HEATING_DAY_KWH
id: ELECTRICITY_INTAKE_HEATING_DAY_KWH
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("ELECTRICITY_INTAKE_HEATING_DAY_KWH"));
return {};
- platform: template
name: ELECTRICITY_INTAKE_HEATING_DAY_SUM
id: ELECTRICITY_INTAKE_HEATING_DAY_SUM
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
state_class: total_increasing
- platform: template
name: ELECTRICITY_INTAKE_HEATING_SUM_KWH
id: ELECTRICITY_INTAKE_HEATING_SUM_KWH
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("ELECTRICITY_INTAKE_HEATING_SUM_KWH"));
return {};
- platform: template
name: ELECTRICITY_INTAKE_HEATING_SUM_MWH
id: ELECTRICITY_INTAKE_HEATING_SUM_MWH
unit_of_measurement: MWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("ELECTRICITY_INTAKE_HEATING_SUM_MWH"));
return {};
- platform: template
name: ELECTRICITY_INTAKE_HEATING_SUM
id: ELECTRICITY_INTAKE_HEATING_SUM
unit_of_measurement: MWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
state_class: total_increasing
- platform: template
name: HEAT_YIELD_HEATING_DAY_WH
id: HEAT_YIELD_HEATING_DAY_WH
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("HEAT_YIELD_HEATING_DAY_WH"));
return {};
- platform: template
name: HEAT_YIELD_HEATING_DAY_KWH
id: HEAT_YIELD_HEATING_DAY_KWH
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("HEAT_YIELD_HEATING_DAY_KWH"));
return {};
- platform: template
name: HEAT_YIELD_HEATING_DAY_SUM
id: HEAT_YIELD_HEATING_DAY_SUM
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
state_class: total_increasing
- platform: template
name: HEAT_YIELD_HEATING_SUM_KWH
id: HEAT_YIELD_HEATING_SUM_KWH
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("HEAT_YIELD_HEATING_SUM_KWH"));
return {};
- platform: template
name: HEAT_YIELD_HEATING_SUM_MWH
id: HEAT_YIELD_HEATING_SUM_MWH
unit_of_measurement: MWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("HEAT_YIELD_HEATING_SUM_MWH"));
return {};
- platform: template
name: HEAT_YIELD_HEATING_SUM
id: HEAT_YIELD_HEATING_SUM
unit_of_measurement: MWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
state_class: total_increasing
## POWER METRICS DHW
- platform: template
name: ELECTRICITY_INTAKE_DHW_DAY_WH
id: ELECTRICITY_INTAKE_DHW_DAY_WH
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("ELECTRICITY_INTAKE_DHW_DAY_WH"));
return {};
- platform: template
name: ELECTRICITY_INTAKE_DHW_DAY_KWH
id: ELECTRICITY_INTAKE_DHW_DAY_KWH
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("ELECTRICITY_INTAKE_DHW_DAY_KWH"));
return {};
- platform: template
name: ELECTRICITY_INTAKE_DHW_DAY_SUM
id: ELECTRICITY_INTAKE_DHW_DAY_SUM
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
state_class: total_increasing
- platform: template
name: ELECTRICITY_INTAKE_DHW_SUM_KWH
id: ELECTRICITY_INTAKE_DHW_SUM_KWH
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("ELECTRICITY_INTAKE_DHW_SUM_KWH"));
return {};
- platform: template
name: ELECTRICITY_INTAKE_DHW_SUM_MWH
id: ELECTRICITY_INTAKE_DHW_SUM_MWH
unit_of_measurement: MWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("ELECTRICITY_INTAKE_DHW_SUM_MWH"));
return {};
- platform: template
name: ELECTRICITY_INTAKE_DHW_SUM
id: ELECTRICITY_INTAKE_DHW_SUM
unit_of_measurement: MWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
state_class: total_increasing
- platform: template
name: HEATING_DHW_DAY_WH
id: HEATING_DHW_DAY_WH
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("HEATING_DHW_DAY_WH"));
return {};
- platform: template
name: HEATING_DHW_DAY_KWH
id: HEATING_DHW_DAY_KWH
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("HEATING_DHW_DAY_KWH"));
return {};
- platform: template
name: HEATING_DHW_DAY_SUM
id: HEATING_DHW_DAY_SUM
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
state_class: total_increasing
- platform: template
name: HEATING_DHW_SUM_KWH
id: HEATING_DHW_SUM_KWH
unit_of_measurement: kWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("HEATING_DHW_SUM_KWH"));
return {};
- platform: template
name: HEATING_DHW_SUM_MWH
id: HEATING_DHW_SUM_MWH
unit_of_measurement: MWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_pump], GetElsterIndex("HEATING_DHW_SUM_MWH"));
return {};
- platform: template
name: HEATING_DHW_SUM
id: HEATING_DHW_SUM
unit_of_measurement: MWh
device_class: energy
icon: mdi:transmission-tower
accuracy_decimals: 3
state_class: total_increasing
## FROM FEK (can't read - just listen)
- platform: template
name: HUMIDITY
id: HUMIDITY
unit_of_measurement: "%"
icon: "mdi:water-percent"
device_class: "humidity"
state_class: measurement
accuracy_decimals: 1
- platform: template
name: ADJUSTED_ROOM_SET_TEMP
id: ADJUSTED_ROOM_SET_TEMP
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
- platform: template
name: ROOM_INTERNAL_TEMP
id: ROOM_INTERNAL_TEMP
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
- platform: template
name: FLOW_INTERNAL_TEMP
id: FLOW_INTERNAL_TEMP
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
- platform: template
name: BOILER_SET_TEMP
id: BOILER_SET_TEMP
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
## FROM FE7
- platform: template
name: FLOW_INTERNAL_TEMP_BASEMENT
id: FLOW_INTERNAL_TEMP_BASEMENT
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
- platform: template
name: ADJUSTED_ROOM_SET_TEMP_BASEMENT
id: ADJUSTED_ROOM_SET_TEMP_BASEMENT
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
- platform: template
name: MAX_TEMP_BOILER
id: MAX_TEMP_BOILER
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
- platform: template
name: ROOM_INTERNAL_TEMP_BASEMENT
id: ROOM_INTERNAL_TEMP_BASEMENT
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_fe7], GetElsterIndex("ROOM_INTERNAL_TEMP"));
return {};
- platform: template
name: FLOW_INTERNAL_TEMP_HK2
id: FLOW_INTERNAL_TEMP_HK2
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_fe7], GetElsterIndex("FLOW_INTERNAL_TEMP"));
return {};
- platform: template
name: FLOW_SETPOINT_TEMP_HK2
id: FLOW_SETPOINT_TEMP_HK2
unit_of_measurement: °C
icon: mdi:thermometer-lines
device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 10min
lambda: |-
readSignal(&CanMembers[cm_fe7], GetElsterIndex("FLOW_SETPOINT_TEMP"));
return {};
# TEST
## FROM Manager
- platform: template
name: FATAL_ERROR
id: FATAL_ERROR
# unit_of_measurement: °C
# icon: mdi:thermometer-lines
# device_class: temperature
state_class: measurement
accuracy_decimals: 1
update_interval: 5min
lambda: |-
readSignal(&CanMembers[cm_manager], GetElsterIndex("FATAL_ERROR"));
return {};
- platform: wifi_signal
name: WiFi Signal dBm
icon: mdi:wifi
update_interval: 60s
id: wifi_dbm
- platform: template
name: WiFi Signal
icon: mdi:signal
unit_of_measurement: '%'
update_interval: 60s
id: wifi_percentage
lambda: |-
float dBm = id(wifi_dbm).state;
float MIN_DBM = -100.0; // Minimum RSSI in dBm
float MAX_DBM = -30.0; // Maximum RSSI in dBm
if (dBm < MIN_DBM) dBm = MIN_DBM;
if (dBm > MAX_DBM) dBm = MAX_DBM;
return ((dBm - MIN_DBM) / (MAX_DBM - MIN_DBM)) * 100;
# text_sensor:
# - platform: homeassistant
# name: Heat Pump Date Setpoint
# id: warmepumpe_datum
# entity_id: input_datetime.warmepumpe_datum
# - platform: homeassistant
# name: Heat Pump Time Setpoint
# id: warmepumpe_uhrzeit
# entity_id: input_datetime.warmepumpe_uhrzeit
# - platform: homeassistant
# name: ADJUST_STORAGE_TARGET_TEMP_SET
# id: EINSTELL_SPEICHERSOLLTEMP_SET
# entity_id: input_number.speichersolltemp_set
# on_value:
# then:
# lambda: |-
# if(atoi(x.c_str()) != 20) {
# char temp[3];
# strncpy(temp, x.c_str(), sizeof(temp)-1);
# temp[2] ='\0';
# const char* ctemp = temp;
# writeSignal(&CanMembers[cm_manager], GetElsterIndex("EINSTELL_SPEICHERSOLLTEMP"), ctemp);
# id(EINSTELL_SPEICHERSOLLTEMP).update();
# id(SPEICHERISTTEMP).update();
# id(SPEICHERSOLLTEMP).update();
# }
# return;
# - platform: homeassistant
# name: ADJUST_STORAGE_TARGET_TEMP2_SET
# id: EINSTELL_SPEICHERSOLLTEMP2_SET
# entity_id: input_number.speichersolltemp2_set
# on_value:
# then:
# lambda: |-
# if(atoi(x.c_str()) != 20) {
# char temp[3];
# strncpy(temp, x.c_str(), sizeof(temp)-1);
# temp[2] ='\0';
# const char* ctemp = temp;
# writeSignal(&CanMembers[cm_manager], GetElsterIndex("EINSTELL_SPEICHERSOLLTEMP2"), ctemp);
# id(EINSTELL_SPEICHERSOLLTEMP2).update();
# id(SPEICHERISTTEMP).update();
# id(SPEICHERSOLLTEMP).update();
# }
# return;
# - platform: template
# name: DEVICE_ID_MANAGER
# id: GERAETE_ID_MANAGER
# icon: mdi:description
# - platform: template
# name: PROGRAM_SWITCH
# id: PROGRAMMSCHALTER
# icon: mdi:switch
# lambda: |-
# readSignal(&CanMembers[cm_manager], GetElsterIndex("PROGRAMMSCHALTER"));
# return {};
# - platform: template
# name: SUMMER_OPERATION
# id: SOMMERBETRIEB
# icon: mdi:weather-sunny
# lambda: |-
# readSignal(&CanMembers[cm_manager], GetElsterIndex("SOMMERBETRIEB"));
# return {};
# - platform: template
# name: DHW_ECO
# id: WW_ECO
# icon: mdi:leaf-circle-outline
# lambda: |-
# readSignal(&CanMembers[cm_manager], GetElsterIndex("WW_ECO"));
# return {};
# - platform: template
# name: DEVICE_ID_HEATING_MODULE
# id: GERAETE_ID_HEIZMODUL
# icon: mdi:description
# - platform: template
# name: DATE
# id: DATUM
# icon: mdi:calendar
# - platform: template
# name: TIME
# id: ZEIT
# icon: mdi:clock
switch:
# Restart ESP device
- platform: restart
name: "Boiler room ESP restart"
id: restart_esp_heatpump
time:
- platform: sntp
on_time:
- seconds: 0
minutes: 0
hours: 4
days_of_week: 1
then:
- switch.toggle: restart_esp_heatpump
# button:
# - platform: template
# name: Update Time
# id: update_uhrzeit
# on_press:
# then:
# lambda: |-
# ESP_LOGI("WRITE UHRZEIT VIA BUTTON", "%s", id(warmepumpe_datum).state.c_str());
# char stunde[3];
# char minute[3];
# char sekunde[3];
# strncpy(stunde, id(warmepumpe_uhrzeit).state.c_str(), sizeof(stunde)-1);
# stunde[2] ='\0';
# strncpy(minute, id(warmepumpe_uhrzeit).state.c_str()+3, sizeof(minute)-1);
# minute[2] ='\0';
# strncpy(sekunde, id(warmepumpe_uhrzeit).state.c_str()+6, sizeof(sekunde)-1);
# sekunde[2] ='\0';
# const char* cstunde = stunde;
# const char* cminute = minute;
# const char* csekunde = sekunde;
# ESP_LOGI("WRITE", "Stunde: %s, Minute: %s, Sekunde: %s", cstunde, cminute, csekunde);
# writeSignal(&CanMembers[cm_manager], GetElsterIndex("STUNDE"), cstunde);
# id(STUNDE).update();
# writeSignal(&CanMembers[cm_manager], GetElsterIndex("MINUTE"), cminute);
# id(MINUTE).update();
# writeSignal(&CanMembers[cm_manager], GetElsterIndex("SEKUNDE"), csekunde);
# id(SEKUNDE).update();
# - platform: template
# name: Update Date
# id: update_datum
# on_press:
# then:
# lambda: |-
# ESP_LOGI("WRITE DATUM VIA BUTTON", "%s", id(warmepumpe_datum).state.c_str());
# char year[3];
# char month[3];
# char day[3];
# strncpy(year, id(warmepumpe_datum).state.c_str()+2, sizeof(year)-1);
# year[2] ='\0';
# strncpy(month, id(warmepumpe_datum).state.c_str()+5, sizeof(month)-1);
# month[2] ='\0';
# strncpy(day, id(warmepumpe_datum).state.c_str()+8, sizeof(day)-1);
# day[2] ='\0';
# const char* cyear = year;
# const char* cmonth = month;
# const char* cday = day;
# ESP_LOGI("WRITE", "Year: %s, Month: %s, Day: %s", cyear, cmonth, cday);
# writeSignal(&CanMembers[cm_manager], GetElsterIndex("JAHR"), cyear);
# id(JAHR).update();
# writeSignal(&CanMembers[cm_manager], GetElsterIndex("MONAT"), cmonth);
# id(MONAT).update();
# writeSignal(&CanMembers[cm_manager], GetElsterIndex("TAG"), cday);
# id(TAG).update();
spi:
id: McpSpi
clk_pin: GPIO18
mosi_pin: GPIO23
miso_pin: GPIO19
canbus:
- platform: mcp2515
id: my_mcp2515
spi_id: McpSpi
cs_pin: GPIO17
can_id: 0x680
use_extended_id: false
bit_rate: 20kbps
on_frame:
- can_id: 0x180
then:
- lambda: |-
unsigned short canId = 180;
std::string value;
const ElsterIndex* ei = processCanMessage(canId, value, x);
if(ei->EnglishName == "OUTSIDE_TEMP") {
id(OUTSIDE_TEMP).publish_state(std::stof(value));
return;
}
if(ei->EnglishName == "RETURN_FLOW_INTERNAL_TEMP") {
id(RETURN_FLOW_INTERNAL_TEMP).publish_state(std::stof(value));
return;
}
if(ei->EnglishName == "FLOW_INTERNAL_TEMP_HK1") {
id(FLOW_INTERNAL_TEMP_HK1).publish_state(std::stof(value));
return;
}
if(ei->EnglishName == "STORAGE_TANK_INTERNAL_TEMP") {
id(STORAGE_TANK_INTERNAL_TEMP).publish_state(std::stof(value) + 3);
return;
}
if(ei->EnglishName == "SOURCE_ACTUAL") {
id(SOURCE_ACTUAL).publish_state(std::stof(value));
return;
}
if(ei->EnglishName == "HOT_GAS_TEMP") {
id(HOT_GAS_TEMP).publish_state(std::stof(value));
return;
}
if(ei->EnglishName == "AUXILIARY_BOILER_SETPOINT") {
id(AUXILIARY_BOILER_SETPOINT).publish_state(std::stof(value));
return;
}
if(ei->EnglishName == "HEATING_RETURN_ACTUAL") {
id(HEATING_RETURN_ACTUAL).publish_state(std::stof(value));
return;
}
if(ei->EnglishName == "BUFFER_SETPOINT") {
id(BUFFER_SETPOINT).publish_state(std::stof(value));
return;
}
if(ei->EnglishName == "BUFFER_TEMP_BOTTOM1") {
id(BUFFER_TEMP_BOTTOM1).publish_state(std::stof(value));
return;
}
if(ei->EnglishName == "FLOW_RATE") {
id(FLOW_RATE).publish_state(std::stod(value) / 100);
return;
}
if(ei->EnglishName == "CIRCUIT_PRESSURE") {
id(CIRCUIT_PRESSURE).publish_state(std::stod(value) / 100 );
return;
}
if(ei->EnglishName == "SOURCE_PRESSURE") {
id(SOURCE_PRESSURE).publish_state(std::stod(value) / 100);
return;
}
// POWER HEATING
if(ei->EnglishName == "ELECTRICITY_INTAKE_HEATING_DAY_WH") {
id(ELECTRICITY_INTAKE_HEATING_DAY_WH).publish_state(std::stod(value) / 1000);
return;
}
if(ei->EnglishName == "ELECTRICITY_INTAKE_HEATING_DAY_KWH") {
id(ELECTRICITY_INTAKE_HEATING_DAY_KWH).publish_state(std::stod(value) + id(ELECTRICITY_INTAKE_HEATING_DAY_WH).state);
id(ELECTRICITY_INTAKE_HEATING_DAY_SUM).publish_state(id(ELECTRICITY_INTAKE_HEATING_DAY_KWH).state);
update_COP_HEATER();
update_COP_TOTAL();
return;
}
if(ei->EnglishName == "ELECTRICITY_INTAKE_HEATING_SUM_KWH") {
id(ELECTRICITY_INTAKE_HEATING_SUM_KWH).publish_state(std::stod(value));
return;
}
if(ei->EnglishName == "ELECTRICITY_INTAKE_HEATING_SUM_MWH") {
id(ELECTRICITY_INTAKE_HEATING_SUM_MWH).publish_state(std::stod(value));
id(ELECTRICITY_INTAKE_HEATING_SUM).publish_state(id(ELECTRICITY_INTAKE_HEATING_SUM_KWH).state / 1000 + id(ELECTRICITY_INTAKE_HEATING_SUM_MWH).state);
return;
}
if(ei->EnglishName == "HEAT_YIELD_HEATING_DAY_WH") {
id(HEAT_YIELD_HEATING_DAY_WH).publish_state(std::stod(value) / 1000);
return;
}
if(ei->EnglishName == "HEAT_YIELD_HEATING_DAY_KWH") {
id(HEAT_YIELD_HEATING_DAY_KWH).publish_state(std::stod(value) + id(HEAT_YIELD_HEATING_DAY_WH).state);
update_COP_HEATER();
update_COP_TOTAL();
return;
}
if(ei->EnglishName == "HEAT_YIELD_HEATING_SUM_KWH") {
id(HEAT_YIELD_HEATING_SUM_KWH).publish_state(std::stod(value));
return;
}
if(ei->EnglishName == "HEAT_YIELD_HEATING_SUM_MWH") {
id(HEAT_YIELD_HEATING_SUM_MWH).publish_state(std::stod(value));
id(HEAT_YIELD_HEATING_SUM).publish_state(id(HEAT_YIELD_HEATING_SUM_KWH).state / 1000 + id(HEAT_YIELD_HEATING_SUM_MWH).state);
return;
}
// POWER DHW
if(ei->EnglishName == "ELECTRICITY_INTAKE_DHW_DAY_WH") {
id(ELECTRICITY_INTAKE_DHW_DAY_WH).publish_state(std::stod(value) / 1000);
return;
}
if(ei->EnglishName == "ELECTRICITY_INTAKE_DHW_DAY_KWH") {
id(ELECTRICITY_INTAKE_DHW_DAY_KWH).publish_state(std::stod(value) + id(ELECTRICITY_INTAKE_DHW_DAY_WH).state);
update_COP_DHW();
update_COP_TOTAL();
return;
}