Переглянути джерело

[Bug fix][Modularization][Module_OcppBackend20]

2022.05.20 / Folus Wen

Actions:
1. sent_queue() fix folder name from OCPP to OCPP_PH.

Files:
1. As follow commit history

Image version: D0.00.XX.XXXX.XX
Image checksum: XXXXXXXX

Hardware PWB P/N : XXXXXXX
Hardware Version : XXXXXXX
FolusWen 2 роки тому
батько
коміт
ae7400390b

+ 4 - 4
EVSE/Modularization/ocppph/Module_OcppBackend.c

@@ -937,17 +937,17 @@ int sentqueue()
 
 	DEBUG_INFO("Sent queue.\n");
 
-	stat("/Storage/OCPP", &stats);
+	stat("/Storage/OCPP_PH", &stats);
 
 	// Check for directory existence
 	if (S_ISDIR(stats.st_mode) != 1)
 	{
-		//DEBUG_INFO("\n OCPP directory not exist, create dir \n");
-		sprintf(cmd, "mkdir -p /Storage/OCPP");
+		//DEBUG_INFO("\n OCPP_PH directory not exist, create dir \n");
+		sprintf(cmd, "mkdir -p /Storage/OCPP_PH");
 		system(cmd);
 	}
 
-	if((fp = fopen("/Storage/OCPP/TransactionRelatedQueue" , "r")) == NULL)
+	if((fp = fopen("/Storage/OCPP_PH/TransactionRelatedQueue" , "r")) == NULL)
 	{
 		DEBUG_ERROR("Error opening file");
 	}

+ 5 - 0
EVSE/Projects/AX80/Apps/main.c

@@ -5740,6 +5740,11 @@ int main(void)
 									//sprintf((char*)ShmSysConfigAndInfo->SysConfig.UserId, "F5902677");
 									ShmCharger->gun_info[gun_index].isGetEvCCID = ON;
 
+									if(getRequest(gun_index))
+									{
+										setRequest(gun_index, OFF);
+									}
+
 									DEBUG_INFO("Got EVCCID: %s\n", ShmSysConfigAndInfo->SysConfig.UserId);
 								}
 							}