mirror of
https://github.com/dalathegreat/Battery-Emulator.git
synced 2025-10-04 18:29:48 +02:00
Update KIA-E-GMP-BATTERY.cpp
Removed cells with voltage below 1000mv in the set_cell_voltages routine
This commit is contained in:
parent
67fc8c7af0
commit
dfee45cbaf
1 changed files with 2 additions and 0 deletions
|
@ -51,9 +51,11 @@ CANFDMessage EGMP_7E4_ack;
|
|||
|
||||
void set_cell_voltages(CANFDMessage frame, int start, int length, int startCell) {
|
||||
for (size_t i = 0; i < length; i++) {
|
||||
if ((frame.data[start + i] * 20) > 1000) {
|
||||
datalayer.battery.status.cell_voltages_mV[startCell + i] = (frame.data[start + i] * 20);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void update_values_battery() { //This function maps all the values fetched via CAN to the correct parameters used for modbus
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue