GpsData.h 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. #ifndef GPS_DATA_H
  2. #define GPS_DATA_H
  3. /******************************************************************************/
  4. #include "stdint.h"
  5. typedef struct SUT_GPS_INF
  6. {
  7. unsigned char isGpsWork:1;//GPS模块工作标志
  8. unsigned char isGpsValid:1;//GPS定位标志 0 GPS未定位 1 GPS已定位
  9. unsigned char isServerLogin:1; //GPS 服务器连接成功标志
  10. unsigned char isAutoSend:1;//自动发送标志
  11. unsigned char isGpsAuthOk:1;//GPS是否鉴权成功
  12. // unsigned char isFirstLocationSend:1;//is location package send and get ack or not after ath ok
  13. unsigned char GpsInactiveCt;//串口没反应计数器 ,当串口接收到消息则清零 ,否则持续时间长将复位模块
  14. unsigned char HostCmd;//主机下发的命令
  15. //unsigned short SendTime;//发送到服务器的时间间隔 秒为单位
  16. //unsigned short GPSSendTime;
  17. unsigned int GPS_SecondCnt;
  18. unsigned short GPS_UploadTime;
  19. unsigned char GPS_TimeIndexBackup;
  20. unsigned char year;
  21. unsigned char month;
  22. unsigned char day;
  23. unsigned char hour;
  24. unsigned char minu;
  25. unsigned char sec;
  26. uint32_t longitue;//经度
  27. uint32_t latitue;//纬度
  28. uint32_t speed;//速度
  29. uint32_t aspect;//方位
  30. uint32_t AvgSpeed;//平均速度
  31. uint32_t speedbuf[5];
  32. uint32_t StatisticsMile ;//历程统计
  33. //----------
  34. unsigned char Status;
  35. unsigned char Location[16];
  36. unsigned char Speed[8];
  37. unsigned char Time[8];
  38. uint32_t testJD;
  39. uint32_t testWD;
  40. char NSFlag;//N 北纬 S 南纬
  41. char EWFlag;//E 东经 W 西经
  42. // unsigned char reAthCnt;//resend ath time max 5
  43. }SUT_GPS_INF;
  44. extern SUT_GPS_INF sutGpsInfo;
  45. extern void process_nema(char *nema);
  46. /********************************************************************************/
  47. #endif // GPS_STRUCT_H