|
@@ -6296,6 +6296,19 @@ int main(void)
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ //==========================================
|
|
|
+ // Synchronized total power consumption
|
|
|
+ //==========================================
|
|
|
+ if(ShmSysConfigAndInfo->SysConfig.AcPhaseCount==1)
|
|
|
+ ShmSysConfigAndInfo->SysInfo.AcChargingData[gun_index].PowerConsumption = (ShmCharger->gun_info[gun_index].powerConsumptionTotal.power_consumption/10000.0);
|
|
|
+ else
|
|
|
+ {
|
|
|
+ ShmSysConfigAndInfo->SysInfo.AcChargingData[gun_index].PowerConsumption = (ShmCharger->gun_info[gun_index].powerConsumptionTotal.power_consumption/10000.0);
|
|
|
+ //ShmSysConfigAndInfo->SysInfo.AcChargingData[gun_index].PowerConsumption[0] = (ShmCharger->gun_info[gun_index].powerConsumption[0].power_consumption/10000.0);
|
|
|
+ //ShmSysConfigAndInfo->SysInfo.AcChargingData[gun_index].PowerConsumption[1] = (ShmCharger->gun_info[gun_index].powerConsumption[1].power_consumption/10000.0);
|
|
|
+ //ShmSysConfigAndInfo->SysInfo.AcChargingData[gun_index].PowerConsumption[2] = (ShmCharger->gun_info[gun_index].powerConsumption[2].power_consumption/10000.0);
|
|
|
+ }
|
|
|
+
|
|
|
//==========================================
|
|
|
// Connector process
|
|
|
//==========================================
|
|
@@ -6396,6 +6409,11 @@ int main(void)
|
|
|
|
|
|
system ("pkill OcppBackend");
|
|
|
}
|
|
|
+ else
|
|
|
+ {
|
|
|
+ system ("pkill OcppBackend");
|
|
|
+ DEBUG_INFO("Initialization: Kill OcppBackend task. \n");
|
|
|
+ }
|
|
|
|
|
|
// If rotate switch equal zero, the system needs to change Debug mode
|
|
|
if(ShmCharger->gun_info[gun_index].primaryMcuState.rotatory_switch == 0)
|
|
@@ -6441,6 +6459,9 @@ int main(void)
|
|
|
// Refresh PTB resend timer
|
|
|
if(ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'P')
|
|
|
refreshStartTimer(&startTime[gun_index][TMR_IDX_PTB_METER_SEND]);
|
|
|
+
|
|
|
+ DEBUG_INFO("System memory power consumption: %.4f \n",(ShmCharger->gun_info[gun_index].powerConsumptionTotal.power_consumption/10000.0));
|
|
|
+ DEBUG_INFO("Share memory power consumption: %.4f \n",ShmSysConfigAndInfo->SysInfo.AcChargingData[gun_index].PowerConsumption);
|
|
|
}
|
|
|
|
|
|
break;
|