GpsData.h 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. #ifndef __GPS_DATA_H_
  2. #define __GPS_DATA_H_
  3. typedef enum{
  4. GPS_NULL,
  5. GNRMC=1,
  6. GPVTG,
  7. GNGGA,
  8. GPGSV,
  9. GBGSV,
  10. }GPS_DATA_TYPE;
  11. extern GPS_DATA_TYPE GPS_Data_Type;
  12. typedef struct SUT_GPS_INF
  13. {
  14. unsigned char isGpsWork:1;//GPS模块工作标志
  15. unsigned char isGpsValid:1;//GPS定位标志 0 GPS未定位 1 GPS已定位
  16. unsigned char year;
  17. unsigned char month;
  18. unsigned char day;
  19. unsigned char hour;
  20. unsigned char minu;
  21. unsigned char sec;
  22. unsigned char GPSVisible_num;
  23. unsigned char BDVisible_num;
  24. unsigned char startnum;
  25. unsigned short hight;
  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. unsigned char Status;
  34. unsigned char Location[16];
  35. unsigned char Speed[8];
  36. unsigned char Time[8];
  37. uint32_t testJD;
  38. uint32_t testWD;
  39. char NSFlag;//N 北纬 S 南纬
  40. char EWFlag;//E 东经 W 西经
  41. char g_GpsEnable; // enable;
  42. // unsigned char reAthCnt;//resend ath time max 5
  43. }SUT_GPS_INF;
  44. extern SUT_GPS_INF sutGpsInfo;
  45. void GPSRestart(void);
  46. void GPSStop(void);
  47. void GPSInit(void);
  48. void process_gps_data(char *buf,uint32_t size);
  49. void GpsInternalChange(unsigned int interval);
  50. #endif