From eb2415c28e3bea00c205e56e69ae6d022671ea1f Mon Sep 17 00:00:00 2001 From: Yury Shuvakin Date: Sat, 12 Nov 2022 23:47:54 +0300 Subject: [PATCH] Fixed write network settings command --- Core/Src/modCommands.c | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/Core/Src/modCommands.c b/Core/Src/modCommands.c index ae14262..7533352 100644 --- a/Core/Src/modCommands.c +++ b/Core/Src/modCommands.c @@ -425,30 +425,30 @@ void modCommandsProcessPacket(unsigned char *data, unsigned int len) { ind = 0; modCommandsSendBuffer[ind++] = packet_id; - i=250; - while (i>0){ + i=0; + while (i<250){ libBufferAppend_uint8(modCommandsSendBuffer,modCommandsToBeSendConfig->Domain_URL[i],&ind); - i--; + i++; } - i=250; - while (i>0){ + i=0; + while (i<250){ libBufferAppend_uint8(modCommandsSendBuffer,modCommandsToBeSendConfig->Domain_URL_Event[i],&ind); - i--; + i++; } - i=50; - while (i>0){ + i=0; + while (i<50){ libBufferAppend_uint8(modCommandsSendBuffer,modCommandsToBeSendConfig->GSM_APN[i],&ind); - i--; + i++; } - i=50; - while (i>0){ + i=0; + while (i<50){ libBufferAppend_uint8(modCommandsSendBuffer,modCommandsToBeSendConfig->GSM_USER[i],&ind); - i--; + i++; } - i=50; - while (i>0){ + i=0; + while (i<50){ libBufferAppend_uint8(modCommandsSendBuffer,modCommandsToBeSendConfig->GSM_PWD[i],&ind); - i--; + i++; } modCommandsSendPacket(modCommandsSendBuffer, ind);