|
@@ -507,10 +507,9 @@ static void Uart_Task(void* arg)
|
|
static void Fota_Task(void* arg)
|
|
static void Fota_Task(void* arg)
|
|
{
|
|
{
|
|
Fota_Stuct.Fota_Data_Len=100;
|
|
Fota_Stuct.Fota_Data_Len=100;
|
|
- uint8_t Uart_Send_buffer[6];
|
|
|
|
uint8_t Uart_Rece_buffer[110];
|
|
uint8_t Uart_Rece_buffer[110];
|
|
uint32_t file_address = 0x00000000;
|
|
uint32_t file_address = 0x00000000;
|
|
- uint8_t Uart_Send_buffer = {0x00,0x00,0x00,0x00,0x64,0x01};
|
|
|
|
|
|
+ uint8_t Uart_Send_buffer[6] = {0x00,0x00,0x00,0x00,0x64,0x01};
|
|
uint32_t timeout = 0x00000000;
|
|
uint32_t timeout = 0x00000000;
|
|
while (true)
|
|
while (true)
|
|
{
|
|
{
|
|
@@ -537,8 +536,8 @@ static void Fota_Task(void* arg)
|
|
Uart_Send_buffer[2] = file_address>>8;
|
|
Uart_Send_buffer[2] = file_address>>8;
|
|
Uart_Send_buffer[3] = file_address;
|
|
Uart_Send_buffer[3] = file_address;
|
|
#ifdef USING_PRINTF
|
|
#ifdef USING_PRINTF
|
|
- printf("Uart_Send_buffer:");
|
|
|
|
- for(int i=0;i++;i<110)
|
|
|
|
|
|
+ printf("Uart_Send_buffer:");
|
|
|
|
+ for(int i=0;i<110;i++)
|
|
printf("%x",Uart_Send_buffer[i]);
|
|
printf("%x",Uart_Send_buffer[i]);
|
|
printf("\n");
|
|
printf("\n");
|
|
#endif
|
|
#endif
|
|
@@ -548,6 +547,7 @@ static void Fota_Task(void* arg)
|
|
isRecvTimeout == false;
|
|
isRecvTimeout == false;
|
|
memset(Uart_Rece_buffer,0,110);
|
|
memset(Uart_Rece_buffer,0,110);
|
|
}
|
|
}
|
|
|
|
+ }
|
|
}
|
|
}
|
|
//Uart线程初始化
|
|
//Uart线程初始化
|
|
void Uart_Task_Init()
|
|
void Uart_Task_Init()
|