1- # Updated : 2026.02.05
2- # Version : 1.1.10
1+ # Updated : 2026.02.21
2+ # Version : 1.1.11
33# GitHub : https://github.com/GHswitt/esphome-yambms
44
55# YamBMS ( Yet another multi-BMS Merging Solution )
@@ -166,9 +166,10 @@ sensor:
166166 state_class : ' measurement'
167167 accuracy_decimals : 2
168168 filters :
169- - timeout :
170- timeout : 60s
171- value : !lambda return 0;
169+ - timeout :
170+ timeout : 60s
171+ value : !lambda return 0;
172+ - throttle : ${bms_update_interval}
172173
173174 # Current
174175 - platform : template
@@ -179,6 +180,8 @@ sensor:
179180 device_class : ' current'
180181 state_class : ' measurement'
181182 accuracy_decimals : 1
183+ filters :
184+ - throttle : ${bms_update_interval}
182185
183186 # Battery power (calculated)
184187 - platform : template
@@ -191,6 +194,8 @@ sensor:
191194 accuracy_decimals : 0
192195 lambda : |-
193196 return id(bms${bms_id}_total_voltage).state * id(bms${bms_id}_current).state;
197+ filters :
198+ - throttle : ${bms_update_interval}
194199
195200 # Charging power: Calculated from voltage and current
196201 - platform : template
@@ -204,6 +209,8 @@ sensor:
204209 lambda : |-
205210 if (id(bms${bms_id}_current).state > 0) return id(bms${bms_id}_total_voltage).state * id(bms${bms_id}_current).state;
206211 else return 0;
212+ filters :
213+ - throttle : ${bms_update_interval}
207214
208215 # Discharging power: Calculated from voltage and current
209216 - platform : template
@@ -217,6 +224,8 @@ sensor:
217224 lambda : |-
218225 if (id(bms${bms_id}_current).state < 0) return id(bms${bms_id}_total_voltage).state * -id(bms${bms_id}_current).state;
219226 else return 0;
227+ filters :
228+ - throttle : ${bms_update_interval}
220229
221230 # SoC
222231 - platform : template
@@ -227,6 +236,8 @@ sensor:
227236 device_class : ' battery'
228237 state_class : ' measurement'
229238 accuracy_decimals : 1
239+ filters :
240+ - throttle : ${bms_update_interval}
230241
231242 # Battery capacity
232243 - platform : template
@@ -241,22 +252,24 @@ sensor:
241252 uint8_t module_count = id(deye${deye_id}_module_amount).state;
242253 if (module_count < 1) module_count = 1;
243254 return id(deye${deye_id}_battery_capacity).state / module_count;
255+ filters :
256+ - throttle : ${bms_update_interval}
244257
245- # Remaining capacity: Calculated from capacity and SoC
258+ # Remaining capacity - Calculated from SoC and battery capacity
246259 - platform : template
260+ # name: "battery capacity remaining"
261+ id : bms${bms_id}_capacity_remaining_ah
262+ device_id : bms_${bms_id}
247263 unit_of_measurement : ' Ah'
248264 device_class : ' battery'
249265 state_class : ' measurement'
250266 accuracy_decimals : 0
251- id : bms${bms_id}_capacity_remaining_ah
252- device_id : bms_${bms_id}
253- # name: "battery capacity remaining"
254- lambda : |-
255- return (id(bms${bms_id}_state_of_charge).state * id(bms${bms_id}_battery_capacity).state) / 100;
256267 filters :
257268 - or :
258- - throttle : 10s
269+ - throttle : ${bms_update_interval}
259270 - delta : 1
271+ lambda : |-
272+ return (id(bms${bms_id}_state_of_charge).state * id(bms${bms_id}_battery_capacity).state) / 100;
260273
261274 # Charging cycles
262275 - platform : template
@@ -296,6 +309,8 @@ sensor:
296309 device_class : ' current'
297310 state_class : ' measurement'
298311 accuracy_decimals : 0
312+ filters :
313+ - throttle : ${bms_update_interval}
299314
300315 # Max. discharge current
301316 - platform : template
@@ -306,6 +321,8 @@ sensor:
306321 device_class : ' current'
307322 state_class : ' measurement'
308323 accuracy_decimals : 0
324+ filters :
325+ - throttle : ${bms_update_interval}
309326
310327 # Max. cell voltage
311328 - platform : template
@@ -316,6 +333,8 @@ sensor:
316333 device_class : ' voltage'
317334 state_class : ' measurement'
318335 accuracy_decimals : 3
336+ filters :
337+ - throttle : ${bms_update_interval}
319338
320339 # Max. voltage cell: Only with InterCAN enabled
321340 - platform : template
@@ -324,8 +343,7 @@ sensor:
324343 id : bms${bms_id}_max_voltage_cell
325344 device_id : bms_${bms_id}
326345 name : " cell voltage max cell number"
327- filters :
328- - lambda : return 0;
346+ lambda : return 0;
329347
330348 # Min. cell voltage
331349 - platform : template
@@ -339,6 +357,8 @@ sensor:
339357 on_value :
340358 then :
341359 - component.update : bms${bms_id}_imbalance
360+ filters :
361+ - throttle : ${bms_update_interval}
342362
343363 # Min. voltage cell: Only with InterCAN enabled
344364 - platform : template
@@ -347,8 +367,7 @@ sensor:
347367 id : bms${bms_id}_min_voltage_cell
348368 device_id : bms_${bms_id}
349369 name : " cell voltage min cell number"
350- filters :
351- - lambda : return 0;
370+ lambda : return 0;
352371
353372 # Min. temperature
354373 - platform : template
@@ -359,6 +378,12 @@ sensor:
359378 device_class : ' temperature'
360379 state_class : ' measurement'
361380 accuracy_decimals : 1
381+ filters :
382+ - exponential_moving_average :
383+ alpha : 0.1
384+ send_every : 4
385+ - delta : 1
386+ - throttle : ${bms_update_interval}
362387
363388 # Min. temperature sensor (fixed)
364389 - platform : template
@@ -380,6 +405,12 @@ sensor:
380405 device_class : ' temperature'
381406 state_class : ' measurement'
382407 accuracy_decimals : 1
408+ filters :
409+ - exponential_moving_average :
410+ alpha : 0.1
411+ send_every : 4
412+ - delta : 1
413+ - throttle : ${bms_update_interval}
383414
384415 # Max. temperature sensor (fixed)
385416 - platform : template
@@ -395,6 +426,7 @@ sensor:
395426 # Cell OVP: Unsupported
396427 - platform : template
397428 unit_of_measurement : ' V'
429+ device_class : ' voltage'
398430 state_class : ' measurement'
399431 accuracy_decimals : 2
400432 id : bms${bms_id}_cell_ovp
@@ -406,6 +438,7 @@ sensor:
406438 # Cell UVP: Unsupported
407439 - platform : template
408440 unit_of_measurement : ' V'
441+ device_class : ' voltage'
409442 state_class : ' measurement'
410443 accuracy_decimals : 2
411444 id : bms${bms_id}_cell_uvp
@@ -417,6 +450,7 @@ sensor:
417450 # Cell balance trigger voltage: Unsupported
418451 - platform : template
419452 unit_of_measurement : ' V'
453+ device_class : ' voltage'
420454 state_class : ' measurement'
421455 accuracy_decimals : 2
422456 id : bms${bms_id}_bms_balance_trigger_voltage
@@ -455,7 +489,7 @@ sensor:
455489 state_class : ' total_increasing'
456490 accuracy_decimals : 3
457491 filters :
458- - throttle : 1s
492+ - throttle : ${bms_update_interval}
459493
460494 - platform : template
461495 name : " discharged"
@@ -466,7 +500,7 @@ sensor:
466500 state_class : ' total_increasing'
467501 accuracy_decimals : 3
468502 filters :
469- - throttle : 1s
503+ - throttle : ${bms_update_interval}
470504
471505text_sensor :
472506 - platform : template
0 commit comments