Przeglądaj źródła

Merge remote-tracking branch 'origin/Noodoe'

Folus Wen 2 lat temu
rodzic
commit
568996ee4e

BIN
EVSE/Projects/NoodoeAX/Apps/CCS/CsuComm


BIN
EVSE/Projects/NoodoeAX/Apps/CCS/SeccComm


+ 1 - 0
EVSE/Projects/NoodoeAX/Apps/Module_InternalComm.c

@@ -2923,6 +2923,7 @@ int main(void)
 				//========================================
 				if(Query_Power_Consumption(Uart1Fd, (gun_index>0?ADDR_AC_PRIMARY_2:ADDR_AC_PRIMARY_1), &ShmCharger->gun_info[gun_index].powerConsumptionTotal, &ShmCharger->gun_info[gun_index].powerConsumption[0], &ShmCharger->gun_info[gun_index].powerConsumption[1], &ShmCharger->gun_info[gun_index].powerConsumption[2]))
 				{
+					ShmSysConfigAndInfo->SysInfo.AcChargingData[gun_index].PowerConsumption = (ShmCharger->gun_info[gun_index].powerConsumptionTotal.power_consumption/10000.0);
 					failCount[gun_index] = 0;
 				}
 				else

+ 16 - 0
EVSE/Projects/NoodoeAX/Apps/main.c

@@ -6074,6 +6074,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
 			//==========================================
@@ -6187,6 +6200,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;

BIN
EVSE/Projects/NoodoeAX/Images/FactoryDefaultConfig.bin


BIN
EVSE/Projects/NoodoeAX/Images/ramdisk.gz