|
@@ -5000,7 +5000,10 @@ void checkHandshakeCountdown(uint8_t gun_index)
|
|
|
break;
|
|
|
case SYS_MODE_PREPARING:
|
|
|
|
|
|
- ShmCharger->timeoutSpec.Handshake_Timeout = ((ocpp_get_connection_timeout()) - getDiffSecNow(startTime[gun_index][TMR_IDX_HANDSHAKING]));
|
|
|
+ if(ShmCharger->gun_info[ShmCharger->gun_selectd].isHandshakeTimerRefresh == YES)
|
|
|
+ refreshStartTimer(&startTime[gun_index][TMR_IDX_HANDSHAKING]);
|
|
|
+ else
|
|
|
+ ShmCharger->timeoutSpec.Handshake_Timeout = ((ocpp_get_connection_timeout()) - getDiffSecNow(startTime[gun_index][TMR_IDX_HANDSHAKING]));
|
|
|
|
|
|
break;
|
|
|
case SYS_MODE_RESERVATION:
|
|
@@ -5191,6 +5194,7 @@ void checkRfidAuthrize()
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+
|
|
|
for(int gun_index = 0;gun_index<modelnameInfo.GetGunCount;gun_index++)
|
|
|
checkHandshakeCountdown(gun_index);
|
|
|
|
|
@@ -5908,6 +5912,7 @@ int main(void)
|
|
|
previousData[gun_index].current_limit = 0;
|
|
|
}
|
|
|
|
|
|
+
|
|
|
checkHandshakeCountdown(gun_index);
|
|
|
|
|
|
|
|
@@ -6646,7 +6651,9 @@ int main(void)
|
|
|
ShmCharger->gun_info[gun_index].rfidReq = OFF;
|
|
|
}
|
|
|
|
|
|
+
|
|
|
checkHandshakeCountdown(gun_index);
|
|
|
+
|
|
|
if(getDiffSecNow(startTime[gun_index][TMR_IDX_HANDSHAKING]) > ShmCharger->timeoutSpec.Present_Timeout_Spec)
|
|
|
{
|
|
|
setLedMotion(gun_index, LED_ACTION_HANDSHAKE_FAIL);
|