forked from byte4geek/SEPLOS_MQTT
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfiguration.yaml
332 lines (294 loc) · 11.3 KB
/
configuration.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
# MQTT
sensor:
- platform: template
sensors:
bms_residual_capacity_kwh:
friendly_name: "BMS Residual Capacity(Kwh)"
value_template: "{{(((states('sensor.bms_residual_capacity')| float(0) * states('sensor.bms_total_voltage')| float(0))) | round(3)| float * 0.001) | round(3) }}"
unit_of_measurement: "Kwh"
device_class: power
# icon: mdi:home-battery
unique_id: "bmsresidual_capacity_kw999"
- platform: template
sensors:
bms_seplos_battery_status:
friendly_name: 'BMS Battery Status'
# icon_template: mdi:information-outline
unique_id: 'bmsseplosstatus66'
value_template: >
{% set status = states('sensor.bms_charge_discharge') | float(0) %}
{% if status > 0 %}
Charging
{% elif status < 0 %}
Discharge
{% elif status == 0 %}
Standby
{% else %}
N/A
{% endif %}
mqtt:
sensor:
- name: "BMS Cell 01"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell01"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell01_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 02"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell02"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell02_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 03"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell03"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell03_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 04"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell04"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell04_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 05"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell05"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell05_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 06"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell06"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell06_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 07"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell07"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell07_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 08"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell08"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell08_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 09"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell09"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell09_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 10"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell10"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell10_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 11"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell11"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell11_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 12"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell12"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell12_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 13"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell13"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell13_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 14"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell14"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell14_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 15"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell15"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell15_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
- name: "BMS Cell 16"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell16"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_cell16_364715398511"
icon: mdi:car-battery
device_class: voltage
expire_after: 600
# - name: "BMS Lowest Cell"
# state_topic: "homeassistant/sensor/seplos_364715398511"
# value_template: '{{ value_json["lowest_cell"] }}'
# unique_id: "seplos_lowest_cell_364715398511"
# icon: mdi:car-battery
# expire_after: 600
- name: "BMS Lowest Cell V"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["lowest_cell_v"] }}'
unique_id: "seplos_lowest_cell_V_364715398511"
unit_of_measurement: "mV"
icon: mdi:car-battery
expire_after: 600
- name: "BMS Lowest Cell N"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["lowest_cell_n"] }}'
unique_id: "seplos_lowest_cell_N_364715398511"
icon: mdi:battery-outline
expire_after: 600
# - name: "BMS Highest Cell"
# state_topic: "homeassistant/sensor/seplos_364715398511"
# value_template: '{{ value_json["highest_cell"] }}'
# unique_id: "seplos_highest_cell_364715398511"
# icon: mdi:car-battery
# expire_after: 600
- name: "BMS Highest Cell V"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["highest_cell_v"] }}'
unique_id: "seplos_highest_cell_V_364715398511"
unit_of_measurement: "mV"
icon: mdi:car-battery
expire_after: 600
- name: "BMS Highest Cell N"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["highest_cell_n"] }}'
unique_id: "seplos_highest_cell_N_364715398511"
icon: mdi:battery-outline
expire_after: 600
- name: "BMS Difference"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["difference"] }}'
unit_of_measurement: "mV"
unique_id: "seplos_difference_364715398511"
icon: mdi:vector-difference
device_class: voltage
expire_after: 600
- name: "BMS Cell Temp 1"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell_temp1"] }}'
unit_of_measurement: "°C"
unique_id: "seplos_cell_temp1_364715398511"
device_class: temperature
expire_after: 600
- name: "BMS Cell Temp 2"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell_temp2"] }}'
unit_of_measurement: "°C"
unique_id: "seplos_cell_temp2_364715398511"
device_class: temperature
expire_after: 600
- name: "BMS Cell Temp 3"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell_temp3"] }}'
unit_of_measurement: "°C"
unique_id: "seplos_cell_temp3_364715398511"
device_class: temperature
expire_after: 600
- name: "BMS Cell Temp 4"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cell_temp4"] }}'
unit_of_measurement: "°C"
unique_id: "seplos_cell_temp4_364715398511"
device_class: temperature
expire_after: 600
- name: "BMS Port Voltage"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["port_voltage"] }}'
unit_of_measurement: "V"
unique_id: "seplos_port_voltage_364715398511"
device_class: voltage
expire_after: 600
- name: "BMS Cycles"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["cycles"] }}'
unique_id: "seplos_cycles_364715398511"
icon: mdi:counter
expire_after: 600
- name: "BMS Env Temp"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["env_temp"] }}'
unit_of_measurement: "°C"
unique_id: "seplos_env_temp_364715398511"
device_class: temperature
expire_after: 600
- name: "BMS Power Temp"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["power_temp"] }}'
unit_of_measurement: "°C"
unique_id: "seplos_power_temp_364715398511"
device_class: temperature
expire_after: 600
- name: "BMS Charge Discharge"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["charge_discharge"] }}'
unit_of_measurement: "A"
unique_id: "seplos_charge_discharge_364715398511"
device_class: current
expire_after: 600
- name: "BMS Total Voltage"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["total_voltage"] }}'
unit_of_measurement: "V"
unique_id: "seplos_total_voltage_364715398511"
device_class: voltage
expire_after: 600
- name: "BMS Residual Capacity"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["residual_capacity"] }}'
unit_of_measurement: "Ah"
unique_id: "seplos_residual_capacity_364715398511"
icon: mdi:alpha-a-box
expire_after: 600
- name: "BMS SOC"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["soc"] }}'
unit_of_measurement: "%"
unique_id: "seplos_soc_364715398511"
icon: mdi:battery-high
expire_after: 600
- name: "BMS SOH"
state_topic: "homeassistant/sensor/seplos_364715398511"
value_template: '{{ value_json["soh"] }}'
unit_of_measurement: "%"
unique_id: "seplos_soh_364715398511"
icon: mdi:percent-box
expire_after: 600