MEB: Improve MEB status output. (#983)

* Add 4 missing status outputs from battery to MEB more battery page.
BMS_fault_performance
BMS_fault_emergency_shutdown_crash
BMS_error_shutdown_request
BMS_error_shutdown
* Adds SOH calculation.
* Fixes: (hopefully) the capacity calculation from Ah to kWh.
* Only update capacity and soh if number of cells is set. Remove incorrect scaling on Wh_max.

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
Marijn van Galen 2025-03-20 16:34:33 +01:00 committed by GitHub
parent f4613ae2d4
commit e6a6ce9925
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 50 additions and 13 deletions

View file

@ -1062,7 +1062,18 @@ String advanced_battery_processor(const String& var) {
default:
content += String("? ") + String(datalayer_extended.meb.status_HV_line);
}
content += "</h4><h4>Warning support: ";
content += "</h4>";
content += datalayer_extended.meb.BMS_fault_performance ? "<h4>BMS fault performance: Active!</h4>"
: "<h4>BMS fault performance: Off</h4>";
content += datalayer_extended.meb.BMS_fault_emergency_shutdown_crash
? "<h4>BMS fault emergency shutdown crash: Active!</h4>"
: "<h4>BMS fault emergency shutdown crash: Off</h4>";
content += datalayer_extended.meb.BMS_error_shutdown_request ? "<h4>BMS error shutdown request: Active!</h4>"
: "<h4>BMS error shutdown request: Inactive</h4>";
content += datalayer_extended.meb.BMS_error_shutdown ? "<h4>BMS error shutdown: Active!</h4>"
: "<h4>BMS error shutdown: Off</h4>";
content += "<h4>Warning support: ";
switch (datalayer_extended.meb.warning_support) {
case 0:
content += String("OK");