chen
2025-03-03 f029c316190f23acec54d2cb01f2d435534c57e7
keil/include/drivers/serial_at_cmd_app.c
@@ -262,10 +262,11 @@
                              if(wd!=0)
                              blink_led(&gps_success_state);
                    pos_state=atoi(Posstate.m_pData);
                              if(gga_num<10&&!gps_open_flag)
                           if(!gps_open_flag){
                              if(gga_num<10)
                                    {
                                       gps_timeout_flag=0;
                                    snprintf(GGA_Format_message, sizeof(GGA_Format_message), "%s,%04x,%02u%%,%d,%d,0,0\r\n", \
                                    snprintf(GGA_Format_message, sizeof(GGA_Format_message), "%s,%04x,%x,%d,%d,0,0\r\n", \
                                                          GPS_GGAmessage,g_com_map[DEV_ID],bat_percent,userkey_state,gps_timeout_flag);
                                    datalenth_gga = sprintf((char*)&GGA_Final_message[u32GGaLenth],"%s",GGA_Format_message);
                                    u32GGaLenth += datalenth_gga;
@@ -273,6 +274,7 @@
                                    }else{
                                    UDPClient_UploadGPS_10pack();//上传GPS超时无效数据
                                    }
                                 }
                        if(pos_state!=0)
                        {
                           
@@ -285,9 +287,11 @@
                        gps_timeout_flag=0;//不超时接收状态
                gps_need_data_flag=0;//接收数据完成
                gps_wait_count=0;//清0接收状态
                        UDPClient_UploadGPS();//上传GPS超时无效数据
                        gps_power_state=0;//立即关掉gps,防止串口数据过多导致无法切换休眠
                        update_led_power_state();
                        UDPClient_UploadGPS();//上传GPS超时无效数据
//                           }else{
//                                    
                                 }