Fix pollstates

This commit is contained in:
Carsten Schmiemann 2022-04-18 01:18:02 +02:00
parent f4c78f831e
commit 6a2e6dd765
1 changed files with 4 additions and 4 deletions

View File

@ -52,7 +52,7 @@ void OvmsVehicleRenaultZoePh2::IncomingEVC(uint16_t type, uint16_t pid, const ch
if (CAN_NIBL(0) == 1) {
mt_inv_status->SetValue("Inverter off");
StandardMetrics.ms_v_env_on->SetValue(false);
POLLSTATE_ON;
if (!CarIsCharging) { POLLSTATE_ON; }
} else if (CAN_NIBL(0) == 2) {
mt_inv_status->SetValue("Inverter on");
StandardMetrics.ms_v_env_on->SetValue(true);
@ -60,15 +60,15 @@ void OvmsVehicleRenaultZoePh2::IncomingEVC(uint16_t type, uint16_t pid, const ch
} else if (CAN_NIBL(0) == 3) {
mt_inv_status->SetValue("Inverter decharging");
StandardMetrics.ms_v_env_on->SetValue(false);
POLLSTATE_ON;
if (!CarIsCharging) { POLLSTATE_ON; }
} else if (CAN_NIBL(0) == 4) {
mt_inv_status->SetValue("Inverter alternator mode");
StandardMetrics.ms_v_env_on->SetValue(false);
POLLSTATE_ON;
if (!CarIsCharging) { POLLSTATE_ON; }
} else if (CAN_NIBL(0) == 5) {
mt_inv_status->SetValue("Inverter ready to sleep");
StandardMetrics.ms_v_env_on->SetValue(false);
POLLSTATE_ON;
if (!CarIsCharging) { POLLSTATE_ON; }
} else {
mt_inv_status->SetValue("Inverter state unknown");
}