Эх сурвалжийг харах

2021.04.08 / Amos
Actions:
1. ATE add file for previous commit.

Files:
1. As follow commit history

amos 4 жил өмнө
parent
commit
4591b42ad5

+ 28 - 10
EVSE/Projects/ATE/Apps/Module_EvComm.c

@@ -415,11 +415,12 @@ void CANReceiver()
 							//memcpy(&ShmSysConfigAndInfo->ate.vccu.controlPilotStatus, &frame.data, frame.can_dlc);
 							ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.ControlPilot_Frequency.bits.VCCU_ControlPilot_Frequency = ((short) frame.data[1] << 8) + (short) frame.data[0];
 							ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.ControlPilot_DutyCycle.bits.value = ((short) frame.data[2] ) ;
-							ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.ControlPilot_Voltage.bits.value = ((short) frame.data[3] << 8) + (short) frame.data[4];
+							ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.ControlPilot_Voltage.bits.value = ((short) frame.data[4] << 8) + (short) frame.data[3];
 							ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.DATA.bits.VCCU_ControlPilot_Wakeup = bitextract(((short) (frame.data[5])), 0, 2);
 							ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.DATA.bits.VCCU_ChargeUnit_Mode = bitextract(frame.data[5],2, 5);
 							ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.DATA.bits.VCCU_ChargeUnit_State = bitextract(((short) (frame.data[5])), 5, 8);
 							ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.ChargeUnit_MaxCurrent = ((short) frame.data[6] );
+							//printf("ControlPilot_Voltage===== %d %02x %02x\n", (32000-ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.ControlPilot_Voltage.bits.value), frame.data[4], frame.data[3]);
 							//memset(&ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.ControlPilot_Voltage,frame.data[5], frame.can_dlc);
 							break;
 						}
@@ -1391,7 +1392,7 @@ int main(int argc, char *argv[])
 				}
 				case V_VOLTAGEDIFFERENCE:{
 					if (status){
-						printf("CCS VOLTAGEDIFFERENCE Processing 10....................\n");
+						printf("CCS VOLTAGEDIFFERENCE Processing 10 VCCU_V2G_EVSEPresentVoltage_Va = %d ....................\n", ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va);
 					}
 					setEVStatus1(evstaus[1]);
 					/*
@@ -1425,8 +1426,14 @@ int main(int argc, char *argv[])
 
 
 					}
+					//
 					setEVStatus1(evstaus[1]);
-					VCCU_ChargeFromVehicle(CanFd, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va, Allowed, Not_Active, Allowed, Not_allowed, Closed);
+					if(ShmSysConfigAndInfo->ate.vccu.chargeToVehicle.bits.VCCU_Vehicle_ContactorRequest == Closed){
+						VCCU_ChargeFromVehicle(CanFd, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va, Allowed, Not_Active, Allowed, Not_allowed, Closed);
+					}else{
+						VCCU_ChargeFromVehicle(CanFd, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va, Allowed, Not_Active, Allowed, Not_allowed, Opened);
+
+					}
 					VCCU_V2G_VehicleStatus(CanFd, VCCU_V2G_StateM_EnergyTra_0000_DC_DC_extended, 0,
 							3, soc,
 							3, 3, TRUE,
@@ -1443,8 +1450,9 @@ int main(int argc, char *argv[])
 				case V_POWERDELIVERY:{
 					if (status){
 						printf("CCS POWERDELIVERY Processing 12....................\n");
+						//usleep(50000);
 					}
-					VCCU_ChargeFromVehicle(CanFd, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.linkVoltage, Allowed, Not_Active, Allowed, Not_allowed, Closed);
+					VCCU_ChargeFromVehicle(CanFd, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va, Allowed, Not_Active, Allowed, Not_allowed, Closed);
 					/*
 					if(ShmSysConfigAndInfo->ate.ATEStatus == 0){
 						VCCU_ChargeFromVehicle(CanFd, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va, Allowed, Not_Active, Allowed, Not_allowed, Closed);
@@ -1470,16 +1478,21 @@ int main(int argc, char *argv[])
 				}
 				case V_CURRENTDEMAND:{
 					if (status){
-						printf("CCS CURRENTDEMAND Processing 13 %d....................\n", ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va);
+						printf("CCS CURRENTDEMAND Processing 13 %d %d %d %d....................\n", ShmSysConfigAndInfo->ate.targetCurrent_Value, ShmSysConfigAndInfo->ate.targetVoltage_Value, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va);
 						//ShmSysConfigAndInfo->ate.linkVoltage = ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va;
 						//printf("maximumVoltage_value = %d  Voltage = %d  maximumCurrent_value = %d  Current = %d....................\n", ShmSysConfigAndInfo->ate.maximumVoltage_value, ShmSysConfigAndInfo->ate.targetVoltage_Value, ShmSysConfigAndInfo->ate.maximumCurrent_value, ShmSysConfigAndInfo->ate.targetCurrent_Value);
+						//usleep(50000);
 					}
+
 					setEVStatus1(evstaus[2]);
-					if(ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va <= 1){
-						VCCU_ChargeFromVehicle(CanFd, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va, Not_allowed, Not_Active, Allowed, Not_allowed, Closed);
+					if(ShmSysConfigAndInfo->ate.vccu.chargeToVehicle.bits.VCCU_Vehicle_ContactorRequest == Opened){
+						printf("CCS CURRENTDEMAND Processing  %d %d %d %d....................\n", ShmSysConfigAndInfo->ate.targetCurrent_Value, ShmSysConfigAndInfo->ate.targetVoltage_Value, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va);
+
+						//VCCU_ChargeFromVehicle(CanFd, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va, Not_allowed, Not_Active, Allowed, Not_allowed, Opened);
 					}else{
-						VCCU_ChargeFromVehicle(CanFd, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va, Allowed, Not_Active, Allowed, Not_allowed, Closed);
+						//VCCU_ChargeFromVehicle(CanFd, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va, Allowed, Not_Active, Allowed, Not_allowed, Closed);
 					}
+					VCCU_ChargeFromVehicle(CanFd, ShmSysConfigAndInfo->ate.linkVoltage, ShmSysConfigAndInfo->ate.vccu.v2g_EVSEPresentVoltage.VCCU_V2G_EVSEPresentVoltage_Va, Allowed, Not_Active, Allowed, Not_allowed, Closed);
 					/*
 					if(ShmSysConfigAndInfo->ate.ATEStatus == 0){
 						//VCCU_ChargeFromVehicle(CanFd, 500, 500, Allowed, Not_Active, Allowed, Not_allowed, Closed);
@@ -1559,6 +1572,8 @@ int main(int argc, char *argv[])
 				setMisc(1, ShmSysConfigAndInfo->ate.chademo.id0D_req.K1K2Status, ShmSysConfigAndInfo->ate.chademo.id0D_req.Soc);
 
 				if(ShmSysConfigAndInfo->ate.ATEStatus == 1){
+					ShmSysConfigAndInfo->ate.Permission = START;
+					setChargerMode(CCS_QUANTITY, ShmSysConfigAndInfo->ate.Permission);
 					//ShmSysConfigAndInfo->ate.Permission = START;
 					//setChargerMode(CCS_QUANTITY, ShmSysConfigAndInfo->ate.Permission);
 					//printf("ATEStatus == 1 %d \n",ShmSysConfigAndInfo->ate.ATEStatus);
@@ -1665,14 +1680,17 @@ int main(int argc, char *argv[])
 				}
 				//SetChargingPermission(CCS_QUANTITY, ShmSysConfigAndInfo->ate.Permission, ShmSysConfigAndInfo->ate.TotalBatteryCap, ShmSysConfigAndInfo->ate.MaxBatteryCurrent, ShmSysConfigAndInfo->ate.MaxBatteryVoltage, 1);
 				//SetChargingPermission(CCS_QUANTITY, START, 1000, 1200, 6000, 1);
-				//usleep(1000);
+				usleep(1000);
 				//給火線電壓
+				//07
 				SetPresentInputPower(ShmSysConfigAndInfo->ate.RequireVoltage, ShmSysConfigAndInfo->ate.RequireCurrent, 1);
-				//usleep(1000);
+				usleep(1000);
 				//SetPresentInputRequirement(4800, 6000, 1920, 20);
 				SetPresentInputRequirement(ShmSysConfigAndInfo->ate.RequireVoltage, ShmSysConfigAndInfo->ate.RequireCurrent, ShmSysConfigAndInfo->ate.PresentBattVoltage, ShmSysConfigAndInfo->ate.MinimumChargeCurrent, 1);
 
 			}
+		}else if(ShmSysConfigAndInfo->ate.ATEState  == 3){//chademo
+
 		}
 
 	}

+ 7 - 1
EVSE/Projects/ATE/Apps/Module_InternalComm.c

@@ -26,7 +26,7 @@
 #include <ctype.h>
 #include <ifaddrs.h>
 #include <math.h>
-#include "IOComm.h"
+#include 	"IOComm.h"
 
 #include 	"Config.h"
 #include "../../define.h"
@@ -512,6 +512,7 @@ void GetPersentOutputVol()
 			//ShmRelayModuleData->Gun2RelayOutputVolt = outputVoltage.behindRelay_Voltage_C2;
 
 	        ShmSysConfigAndInfo->ate.targetVoltage_Value = (outputVoltage.behindRelay_Voltage_C2);
+
 	        //usleep(whileLoopTime);
 			/*
 			for (int index = 0; index < gunCount; index++)
@@ -1176,6 +1177,8 @@ void CheckRelayOutput(byte index)
 			else
 				_chargingData[1]->RelayKPK2Status = NO;
 		}
+	}else if(ShmSysConfigAndInfo->ate.ATEState == 3){
+
 	}
 
 }
@@ -1699,6 +1702,7 @@ int main(void)
 	printf("inter %d....................\n" , ShmSysConfigAndInfo->ate.ATEState);
     for(;;)
     {
+    	GetPersentOutputVol();
     	CheckRelayOutput(CCS_QUANTITY);
 		//依據當前各槍的狀態選擇 搭上/放開 Relay
 		SetEvContactorRelayStatus(CCS_QUANTITY);
@@ -1710,6 +1714,7 @@ int main(void)
 			{
 				//printf("Match Relay............................ \n");
 				MatchRelayStatus();
+				/*
 				printf("reg relay, AC = %x, g1_p = %x, g1_n = %x, g2_p = %x, g2_n = %x, pn = %x, pp = %x \n",
 											regRelay.relay_event.bits.AC_Contactor,
 											regRelay.relay_event.bits.Gun1_P,
@@ -1718,6 +1723,7 @@ int main(void)
 											regRelay.relay_event.bits.Gun2_N,
 											regRelay.relay_event.bits.Gun1_Parallel_N,
 											regRelay.relay_event.bits.Gun1_Parallel_P);
+											*/
 			}
 		}
 

+ 29 - 1
EVSE/Projects/ATE/Apps/ReadCmdline.c

@@ -253,7 +253,35 @@ void targetVoltage(char *v1){
 		printf("targetVoltage = %d \n", ShmSysConfigAndInfo->ate.targetVoltage_Value);
 	}else{
 		int value = atoi(v1);
-		ShmSysConfigAndInfo->ate.targetVoltage_Value = value;
+		if(ShmSysConfigAndInfo->ate.ATEState  == 1){//VCCU
+			int voltage = value;
+			int maxValue = 950;
+			if(voltage > (maxValue - 10)){
+				ShmSysConfigAndInfo->ate.maximumVoltage_value = maxValue;
+				ShmSysConfigAndInfo->ate.targetVoltage_Value = maxValue - 20;
+				ShmSysConfigAndInfo->ate.linkVoltage = maxValue - 20;
+			}else{
+				ShmSysConfigAndInfo->ate.maximumVoltage_value = voltage + 10;
+				ShmSysConfigAndInfo->ate.targetVoltage_Value = voltage - 10;
+				ShmSysConfigAndInfo->ate.linkVoltage = voltage - 10;
+			}
+		}else if(ShmSysConfigAndInfo->ate.ATEState  == 2){//GB
+			int voltage = value;
+			int gbmaxValue = 750;
+			if(voltage > (gbmaxValue - 100)){
+				//ShmSysConfigAndInfo->ate.targetVoltage_Value = maxValue - 100;
+				ShmSysConfigAndInfo->ate.chademoTargetVoltage_Value = gbmaxValue - 100;
+				ShmSysConfigAndInfo->ate.RequireVoltage = gbmaxValue -100;
+				ShmSysConfigAndInfo->ate.MaxBatteryVoltage = gbmaxValue;
+
+			}else{
+				ShmSysConfigAndInfo->ate.chademoTargetVoltage_Value = voltage;
+				ShmSysConfigAndInfo->ate.RequireVoltage = voltage;
+				ShmSysConfigAndInfo->ate.MaxBatteryVoltage = gbmaxValue;
+			}
+		}
+
+		//ShmSysConfigAndInfo->ate.targetVoltage_Value = value;
 		printf("targetVoltage = %d \n", ShmSysConfigAndInfo->ate.targetVoltage_Value);
 	}
 }

+ 35 - 8
EVSE/Projects/ATE/Apps/main.c

@@ -1166,10 +1166,27 @@ bool Contactors(){
 
 bool S_PowerDelivery(){
 	bool result = false;
-	if(PreCharge_Statue() && ShmSysConfigAndInfo->ate.vccu.v2g_StateM.VCCU_V2G_StateM_StateMachineSt == PowerDelivery
+
+	/*
+	 * ((ShmSysConfigAndInfo->ate.vccu.v2g_StateM.VCCU_V2G_StateM_StateMachineSt == PreCharge ) &&
+			ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.DATA.bits.VCCU_ChargeUnit_State == EVSEStateC &&
+			//(ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.ControlPilot_Voltage.bits.value / 2) == 6 &&
+			ShmSysConfigAndInfo->ate.vccu.chargeToVehicle.bits.VCCU_Vehicle_IsolationMea_0000 == Not_requested)
+
+	ShmSysConfigAndInfo->ate.vccu.chargeFromVehicle.DATA.bits.VCCU_Vehicle_ChargePermission
+	ShmSysConfigAndInfo->ate.vccu.chargeFromVehicle.bits.VCCU_Vehicle_ContactorStatus
+	 * */
+
+	if(ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.DATA.bits.VCCU_ChargeUnit_State == EVSEStateC &&
+			chargingInfo[CCS_QUANTITY]->SystemStatus == V_CONTACTORSCLOSED &&
+			ShmSysConfigAndInfo->ate.vccu.v2g_StateM.VCCU_V2G_StateM_StateMachineSt == PowerDelivery &&
+			//ShmSysConfigAndInfo->ate.vccu.v2g_StateM.VCCU_V2G_StateM_StateMachineSt == PreCharge &&
+			ShmSysConfigAndInfo->ate.vccu.chargeToVehicle.bits.VCCU_Vehicle_IsolationMea_0000 == Not_requested
 			&& ShmSysConfigAndInfo->ate.vccu.chargeToVehicle.bits.VCCU_Vehicle_ContactorRequest == Close
 			){
 		result = true;
+		//printf("status CCS PowerDelivery %d %d....................\n", ShmSysConfigAndInfo->ate.vccu.v2g_StateM.VCCU_V2G_StateM_StateMachineSt, ShmSysConfigAndInfo->ate.vccu.chargeToVehicle.bits.VCCU_Vehicle_ContactorRequest);
+
 		//VCCU_V2G_EVTargetVoltage(450, U_V, TRUE, 0);
 		setChargerMode(CCS_QUANTITY, V_POWERDELIVERY);
 	}
@@ -1188,11 +1205,16 @@ bool S_CurrentDemand(){
 
 bool PowerDeliveryFalse(){
 	bool result = false;
-	if(ShmSysConfigAndInfo->ate.vccu.v2g_StateM.VCCU_V2G_StateM_StateMachineSt == PowerDelivery
+	if(
+			chargingInfo[CCS_QUANTITY]->SystemStatus == V_CURRENTDEMAND &&
+			ShmSysConfigAndInfo->ate.vccu.v2g_StateM.VCCU_V2G_StateM_StateMachineSt == PowerDelivery
 			&& ShmSysConfigAndInfo->ate.vccu.chargeToVehicle.bits.VCCU_Vehicle_ContactorRequest == Open
+			//&& ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.DATA.bits.VCCU_ChargeUnit_State != EVSEStateC
 			){//(DC13) PowerDelivery
 		result = true;
 		setChargerMode(CCS_QUANTITY, V_POWERDELIVERYFALSE);
+
+		//printf("CCS POWERDELIVERYFALSE Processing 14 VCCU_V2G_StateM_StateMachineSt = %d VCCU_ChargeUnit_State = %d VCCU_Vehicle_IsolationMea_0000 = %d ....................\n" , ShmSysConfigAndInfo->ate.vccu.v2g_StateM.VCCU_V2G_StateM_StateMachineSt, ShmSysConfigAndInfo->ate.vccu.controlPilotStatus.DATA.bits.VCCU_ChargeUnit_State, ShmSysConfigAndInfo->ate.vccu.chargeToVehicle.bits.VCCU_Vehicle_IsolationMea_0000);
 	}
 	return result;
 }
@@ -1536,7 +1558,7 @@ int main(void){
 	ShmSysConfigAndInfo->ate.chademo.id0D_req.K1K2Status=0x00;
 	ShmSysConfigAndInfo->ate.chademo.id0D_req.Soc = 50;
 	ShmSysConfigAndInfo->ate.ateMode = 0;
-	ShmSysConfigAndInfo->ate.ATEState = 1;//1:ccs 2:gb
+	ShmSysConfigAndInfo->ate.ATEState = 2;//1:ccs 2:gb
 	/*
 	outputRelay.relay_event.bits.Gun1_Parallel_N = 0x00;
 	outputRelay.relay_event.bits.Gun1_Parallel_P = 0x00;
@@ -1577,10 +1599,10 @@ int main(void){
 
 	//GB
 	//ShmSysConfigAndInfo->ate.PresentBattVoltage = 4700;
-	ShmSysConfigAndInfo->ate.PresentBattVoltage = 7400;
+	ShmSysConfigAndInfo->ate.PresentBattVoltage = 4700;
 	ShmSysConfigAndInfo->ate.MinimumChargeCurrent = 20;
 	//ShmSysConfigAndInfo->ate.RequireVoltage = 4800;
-	ShmSysConfigAndInfo->ate.RequireVoltage = 7450;
+	ShmSysConfigAndInfo->ate.RequireVoltage = 4800;
 	//ShmSysConfigAndInfo->ate.RequireVoltage = 4700;
 	ShmSysConfigAndInfo->ate.RequireCurrent = 600;
 	ShmSysConfigAndInfo->ate.chademoTargetVoltage_Value = 4800;
@@ -1589,7 +1611,7 @@ int main(void){
 	ShmSysConfigAndInfo->ate.Permission = STOP;
 	ShmSysConfigAndInfo->ate.TotalBatteryCap = 1000;          //0.1
 	ShmSysConfigAndInfo->ate.MaxBatteryCurrent = 1200;        //0.1
-	ShmSysConfigAndInfo->ate.MaxBatteryVoltage = 7500;        //0.1
+	ShmSysConfigAndInfo->ate.MaxBatteryVoltage = 5000;        //0.1
 	ShmSysConfigAndInfo->ate.status = 0;
 	ShmSysConfigAndInfo->ate.chademo.id03.state = 0;
 	ShmSysConfigAndInfo->ate.ATEStatus = 0x00;
@@ -2043,16 +2065,21 @@ int main(void){
 			printf("ProximitySignal = %d, state =  %d Permission = %d TotalBatteryCap = %d MaxBatteryCurrent = %d MaxBatteryVoltage = %d ATEStatus = %d....................\n", ShmSysConfigAndInfo->ate.chademo.id03.state ,ShmSysConfigAndInfo->ate.Permission,
 					ShmSysConfigAndInfo->ate.chademo.id03.ProximitySignal, ShmSysConfigAndInfo->ate.TotalBatteryCap, ShmSysConfigAndInfo->ate.MaxBatteryCurrent,
 					ShmSysConfigAndInfo->ate.MaxBatteryVoltage, ShmSysConfigAndInfo->ate.ATEStatus);
-			*/
 
-			printf("state =  %d Permission = %d TotalBatteryCap = %d MaxBatteryCurrent = %d MaxBatteryVoltage = %d ATEStatus = %d K1K2Status = %d PresentBattVoltage = %d RequireVoltage = %d....................\n", ShmSysConfigAndInfo->ate.chademo.id03.state ,ShmSysConfigAndInfo->ate.Permission,
+
+			printf("state =  %d Permission = %d TotalBatteryCap = %d MaxBatteryCurrent = %d MaxBatteryVoltage = %d ATEStatus = %d K1K2Status = %d PresentBattVoltage = %d RequireVoltage = %d....................\n",
+					ShmSysConfigAndInfo->ate.chademo.id03.state ,
+					ShmSysConfigAndInfo->ate.Permission,
 					ShmSysConfigAndInfo->ate.TotalBatteryCap, ShmSysConfigAndInfo->ate.MaxBatteryCurrent,
 					ShmSysConfigAndInfo->ate.MaxBatteryVoltage, ShmSysConfigAndInfo->ate.ATEStatus,
 					ShmSysConfigAndInfo->ate.chademo.id0D_req.K1K2Status, ShmSysConfigAndInfo->ate.PresentBattVoltage, ShmSysConfigAndInfo->ate.RequireVoltage);
 
 			usleep(whileLoopTime);
+			*/
 			//usleep(whileLoopTime);
 
+		}else if(ShmSysConfigAndInfo->ate.ATEState  == 3){//chademo
+
 		}
 
 	}