-
-
Notifications
You must be signed in to change notification settings - Fork 172
/
esp32-jk-pb-modbus-example.yaml
1120 lines (1036 loc) · 30.7 KB
/
esp32-jk-pb-modbus-example.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
substitutions:
name: jk-bms
device_description: "Monitor a JK-BMS (JK-PB series) via Modbus"
external_components_source: github://syssi/esphome-jk-bms@main
tx_pin: GPIO16
rx_pin: GPIO17
esphome:
name: ${name}
comment: ${device_description}
min_version: 2024.6.0
project:
name: "syssi.esphome-jk-bms"
version: 1.5.0
esp32:
board: wemos_d1_mini32
framework:
type: esp-idf
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
ota:
platform: esphome
logger:
level: DEBUG
# If you use Home Assistant please remove this `mqtt` section and uncomment the `api` component!
# The native API has many advantages over MQTT: https://esphome.io/components/api.html#advantages-over-mqtt
mqtt:
broker: !secret mqtt_host
username: !secret mqtt_username
password: !secret mqtt_password
id: mqtt_client
# api:
uart:
- id: uart_0
baud_rate: 115200
rx_buffer_size: 384
tx_pin: ${tx_pin}
rx_pin: ${rx_pin}
modbus:
- id: modbus0
uart_id: uart_0
flow_control_pin: GPIO12
modbus_controller:
- id: bms0
# Dip switch configuration of a single pack setup / address 0x01
# 1 2 4 5
# on, off, off, off (0x01)
#
# Don't turn off all dip switches / don't use device address 0x00.
# This is the Modbus Master mode. You must select a device address
# between 0x01 and 0x0f so the BMS acts as Modbus Slave.
address: 0x01
modbus_id: modbus0
setup_priority: -10
update_interval: 5s
command_throttle: 50ms
sensor:
# 0x1200 0 UINT16 2 R CellVol0 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 1"
address: 0x1200
register_type: holding
value_type: U_WORD
register_count: 32 # read up to CellVol31
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1202 2 UINT16 2 R CellVol1 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 2"
address: 0x1202
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1204 4 UINT16 2 R CellVol2 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 3"
address: 0x1204
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1206 6 UINT16 2 R CellVol3 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 4"
address: 0x1206
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1208 8 UINT16 2 R CellVol4 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 5"
address: 0x1208
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x120A 10 UINT16 2 R CellVol5 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 6"
address: 0x120A
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x120C 12 UINT16 2 R CellVol6 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 7"
address: 0x120C
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x120E 14 UINT16 2 R CellVol7 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 8"
address: 0x120E
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1210 16 UINT16 2 R CellVol8 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 9"
address: 0x1210
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1212 18 UINT16 2 R CellVol9 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 10"
address: 0x1212
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1214 20 UINT16 2 R CellVol10 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 11"
address: 0x1214
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1216 22 UINT16 2 R CellVol11 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 12"
address: 0x1216
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1218 24 UINT16 2 R CellVol12 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 13"
address: 0x1218
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x121A 26 UINT16 2 R CellVol13 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 14"
address: 0x121A
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x121C 28 UINT16 2 R CellVol14 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 15"
address: 0x121C
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x121E 30 UINT16 2 R CellVol15 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 16"
address: 0x121E
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1220 32 UINT16 2 R CellVol16 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 17"
address: 0x1220
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1222 34 UINT16 2 R CellVol17 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 18"
address: 0x1222
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1224 36 UINT16 2 R CellVol18 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 19"
address: 0x1224
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1226 38 UINT16 2 R CellVol19 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 20"
address: 0x1226
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1228 40 UINT16 2 R CellVol20 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 21"
address: 0x1228
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x122A 42 UINT16 2 R CellVol21 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 22"
address: 0x122A
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x122C 44 UINT16 2 R CellVol22 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 23"
address: 0x122C
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x122E 46 UINT16 2 R CellVol23 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 24"
address: 0x122E
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1230 48 UINT16 2 R CellVol24 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 25"
address: 0x1230
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1232 50 UINT16 2 R CellVol25 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 26"
address: 0x1232
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1234 52 UINT16 2 R CellVol26 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 27"
address: 0x1234
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1236 54 UINT16 2 R CellVol27 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 28"
address: 0x1236
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1238 56 UINT16 2 R CellVol28 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 29"
address: 0x1238
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x123A 58 UINT16 2 R CellVol29 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 30"
address: 0x123A
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x123C 60 UINT16 2 R CellVol30 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 31"
address: 0x123C
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x123E 62 UINT16 2 R CellVol31 mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell voltage 32"
address: 0x123E
register_type: holding
value_type: U_WORD
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1240 64 UINT32 4 R CellStatus (each bit indicates a attached cell)
# 0x1244 68 UINT16 2 R CellVolAverage mV
# 0x1246 70 UINT16 2 R CellVoltageDifferenceMax mV
# 0x1248 72 UINT8/UINT8 2 R MaxVolCellNbr / MinVolCellNbr
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} max voltage cell number"
address: 0x1248
register_type: holding
value_type: U_WORD
unit_of_measurement: ""
state_class: measurement
accuracy_decimals: 0
bitmask: 0xFF00
filters:
- offset: 1.0
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} min voltage cell number"
address: 0x1248
register_type: holding
value_type: U_WORD
unit_of_measurement: ""
state_class: measurement
accuracy_decimals: 0
bitmask: 0x00FF
filters:
- offset: 1.0
# 0x124A 74 UINT16 2 R CellWireRes0 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 1 wire resistance"
address: 0x124A
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x124C 76 UINT16 2 R CellWireRes1 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 2 wire resistance"
address: 0x124C
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x124E 78 UINT16 2 R CellWireRes2 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 3 wire resistance"
address: 0x124E
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1250 80 UINT16 2 R CellWireRes3 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 4 wire resistance"
address: 0x1250
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1252 82 UINT16 2 R CellWireRes4 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 5 wire resistance"
address: 0x1252
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1254 84 UINT16 2 R CellWireRes5 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 6 wire resistance"
address: 0x1254
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1256 86 UINT16 2 R CellWireRes6 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 7 wire resistance"
address: 0x1256
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1258 88 UINT16 2 R CellWireRes7 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 8 wire resistance"
address: 0x1258
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x125A 90 UINT16 2 R CellWireRes8 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 9 wire resistance"
address: 0x125A
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x125C 92 UINT16 2 R CellWireRes9 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 10 wire resistance"
address: 0x125C
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x125E 94 UINT16 2 R CellWireRes10 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 11 wire resistance"
address: 0x125E
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1260 96 UINT16 2 R CellWireRes11 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 12 wire resistance"
address: 0x1260
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1262 98 UINT16 2 R CellWireRes12 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 13 wire resistance"
address: 0x1262
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1264 100 UINT16 2 R CellWireRes13 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 14 wire resistance"
address: 0x1264
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1266 102 UINT16 2 R CellWireRes14 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 15 wire resistance"
address: 0x1266
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1268 104 UINT16 2 R CellWireRes15 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 16 wire resistance"
address: 0x1268
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x126A 106 UINT16 2 R CellWireRes16 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 17 wire resistance"
address: 0x126A
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x126C 108 UINT16 2 R CellWireRes17 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 18 wire resistance"
address: 0x126C
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x126E 110 UINT16 2 R CellWireRes18 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 19 wire resistance"
address: 0x126E
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1270 112 UINT16 2 R CellWireRes19 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 20 wire resistance"
address: 0x1270
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1272 114 UINT16 2 R CellWireRes20 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 21 wire resistance"
address: 0x1272
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1274 116 UINT16 2 R CellWireRes21 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 22 wire resistance"
address: 0x1274
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1276 118 UINT16 2 R CellWireRes22 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 23 wire resistance"
address: 0x1276
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1278 120 UINT16 2 R CellWireRes23 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 24 wire resistance"
address: 0x1278
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x127A 122 UINT16 2 R CellWireRes24 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 25 wire resistance"
address: 0x127A
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x127C 124 UINT16 2 R CellWireRes25 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 26 wire resistance"
address: 0x127C
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x127E 126 UINT16 2 R CellWireRes26 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 27 wire resistance"
address: 0x127E
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1280 128 UINT16 2 R CellWireRes27 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 28 wire resistance"
address: 0x1280
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1282 130 UINT16 2 R CellWireRes28 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 29 wire resistance"
address: 0x1282
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1284 132 UINT16 2 R CellWireRes29 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 30 wire resistance"
address: 0x1284
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1286 134 UINT16 2 R CellWireRes30 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 31 wire resistance"
address: 0x1286
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1288 136 UINT16 2 R CellWireRes31 mΩ
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} cell 32 wire resistance"
address: 0x1288
register_type: holding
value_type: U_WORD
unit_of_measurement: "Ω"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x128A 138 INT16 2 R TempMos 0.1 °C
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} mosfet temperature"
address: 0x128A
register_type: holding
value_type: S_WORD
unit_of_measurement: "°C"
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.1
# 0x128C 140 UINT32 4 R CellWireResSta Bit per Cell
# 0x1290 144 UINT32 4 R BatVol mV
- platform: modbus_controller
modbus_controller_id: bms0
name: "${name} total voltage"
address: 0x1290
register_type: holding
value_type: U_DWORD_R
unit_of_measurement: "V"
device_class: voltage
state_class: measurement
accuracy_decimals: 3
filters:
- multiply: 0.001
# 0x1294 148 UINT32 4 R BatWatt mW
# 0x1298 152 INT32 4 R BatCurrent mA
# 0x129C 156 INT16 2 R TempBat 1 0.1 °C
# 0x129E 158 INT16 2 R TempBat 2 0.1 °C
# 0x12A0 160 UINT32 4 R AlarmBitmask
# 0x12A4 164 INT16 2 R BalanCurrent mA
# 0x12A6 166 UINT8+UINT8 2 R BalanStatatus (2:放电; 1:充电 ; 0:关闭) / SOCStateOfcharge %
# 0x12A8 168 INT32 2 R SOCCapRemain mAH
# 0x12AC 172 UINT32 4 R SOCFullChargeCap mAH