|
@@ -1635,7 +1635,7 @@ int DB_cbVariableIsCreate(void *para, int columnCount, char **columnValue, char
|
|
|
sprintf((char*)ShmOCPP20Data->ControllerComponentVariable[AuthCtrlr_Enabled].variableAttribute[0].value, ShmSysConfigAndInfo->SysConfig.AuthorisationMode == AUTH_MODE_ENABLE?"true":"false");
|
|
|
DB_variableSaveToDb(&ShmOCPP20Data->ControllerComponentVariable[AuthCtrlr_Enabled]);
|
|
|
|
|
|
- sprintf((char*)ShmOCPP20Data->ControllerComponentVariable[AuthCtrlr_AdditionalInfoItemsPerMessage].component.name, "AlignedDataCtrlr");
|
|
|
+ sprintf((char*)ShmOCPP20Data->ControllerComponentVariable[AuthCtrlr_AdditionalInfoItemsPerMessage].component.name, "AuthCtrlr");
|
|
|
sprintf((char*)ShmOCPP20Data->ControllerComponentVariable[AuthCtrlr_AdditionalInfoItemsPerMessage].variable.name, "AdditionalInfoItemsPerMessage");
|
|
|
sprintf((char*)ShmOCPP20Data->ControllerComponentVariable[AuthCtrlr_AdditionalInfoItemsPerMessage].variableCharacteristics.dataType, "%s", DataEnumTypeStr[DataEnumType_integer]);
|
|
|
sprintf((char*)ShmOCPP20Data->ControllerComponentVariable[AuthCtrlr_AdditionalInfoItemsPerMessage].variableAttribute[0].type, "%s", AttributeEnumTypeStr[AttributeEnumType_Actual]);
|
|
@@ -6995,6 +6995,7 @@ void CheckSystemValue(void)
|
|
|
sendNotifyReportRequest();
|
|
|
memset(&ShmOCPP20Data->NotifyReport.reportData[0], 0x00, ARRAY_SIZE(ShmOCPP20Data->NotifyReport.reportData)*sizeof(struct ReportDataType));
|
|
|
reportIdx = 0;
|
|
|
+ idx_var--;
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -7018,6 +7019,7 @@ void CheckSystemValue(void)
|
|
|
sendNotifyReportRequest();
|
|
|
memset(&ShmOCPP20Data->NotifyReport.reportData[0], 0x00, ARRAY_SIZE(ShmOCPP20Data->NotifyReport.reportData)*sizeof(struct ReportDataType));
|
|
|
reportIdx = 0;
|
|
|
+ idx_var--;
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -7478,9 +7480,6 @@ void CheckSystemValue(void)
|
|
|
{
|
|
|
if((ShmSysConfigAndInfo->SysInfo.AcChargingData[index].SystemStatus != AcPreviousSystemStatus[index]) || (ShmSysConfigAndInfo->SysInfo.AcChargingData[index].PilotState != AcPreviousConnectorPlugIn[index]) )
|
|
|
{
|
|
|
- AcPreviousSystemStatus[index] = ShmSysConfigAndInfo->SysInfo.AcChargingData[index].SystemStatus;
|
|
|
- AcPreviousConnectorPlugIn[index] = ShmSysConfigAndInfo->SysInfo.AcChargingData[index].PilotState;
|
|
|
-
|
|
|
if(ShmSysConfigAndInfo->SysInfo.AcChargingData[index].SystemStatus != SYS_MODE_AUTHORIZING)
|
|
|
cpinitateMsg.bits[gun_index].StatusNotificationReq = ON;
|
|
|
|
|
@@ -7491,6 +7490,9 @@ void CheckSystemValue(void)
|
|
|
ShmOCPP20Data->CpMsg.bits[gun_index].TransactionEventReq = ON;
|
|
|
}
|
|
|
|
|
|
+ AcPreviousSystemStatus[index] = ShmSysConfigAndInfo->SysInfo.AcChargingData[index].SystemStatus;
|
|
|
+ AcPreviousConnectorPlugIn[index] = ShmSysConfigAndInfo->SysInfo.AcChargingData[index].PilotState;
|
|
|
+
|
|
|
if((ShmSysConfigAndInfo->SysInfo.AcChargingData[index].Index == tempIndex) && ((ShmSysConfigAndInfo->SysInfo.AcChargingData[index].SystemStatus == SYS_MODE_COMPLETE) || (ShmSysConfigAndInfo->SysInfo.AcChargingData[index].SystemStatus <= SYS_MODE_IDLE))) // complete
|
|
|
{
|
|
|
sprintf(filenmae,"/Storage/OCPP/TxProfile_%d_OCPP20.json",(gun_index+1));
|
|
@@ -16755,6 +16757,7 @@ int handleResetRequest(char *uuid, char *payload)
|
|
|
|
|
|
DEBUG_INFO("handleResetRequest...\n");
|
|
|
Reset = json_tokener_parse(payload);
|
|
|
+ ShmOCPP20Data->Reset.evseId = 0;
|
|
|
|
|
|
if(!is_error(Reset))
|
|
|
{
|
|
@@ -16771,7 +16774,7 @@ int handleResetRequest(char *uuid, char *payload)
|
|
|
}
|
|
|
json_object_put(Reset);
|
|
|
|
|
|
- if((strcmp((char*)ShmOCPP20Data->Reset.type, ResetEnumTypeStr[ResetEnumType_Immediate])==0) || (strcmp((char*)ShmOCPP20Data->Reset.type, ResetEnumTypeStr[ResetEnumType_OnIdle])==0))
|
|
|
+ if((ShmOCPP20Data->Reset.evseId == 0) && ((strcmp((char*)ShmOCPP20Data->Reset.type, ResetEnumTypeStr[ResetEnumType_Immediate])==0) || (strcmp((char*)ShmOCPP20Data->Reset.type, ResetEnumTypeStr[ResetEnumType_OnIdle])==0)))
|
|
|
{
|
|
|
strcpy((char *)ShmOCPP20Data->Reset.guid, uuid);
|
|
|
strcpy((char*)ShmOCPP20Data->Reset.Response_status, ResetStatusEnumTypeStr[ResetStatusEnumType_Accepted]);
|