Adafruit GPS Library
Adafruit_PMTK.h
Go to the documentation of this file.
1 /**************************************************************************/
22 /**************************************************************************/
23 
24 #ifndef _ADAFRUIT_PMTK_H
25 #define _ADAFRUIT_PMTK_H
26 
27 /**************************************************************************/
33 #define PMTK_SET_NMEA_UPDATE_100_MILLIHERTZ \
34  "$PMTK220,10000*2F"
35 #define PMTK_SET_NMEA_UPDATE_200_MILLIHERTZ \
36  "$PMTK220,5000*1B"
37 #define PMTK_SET_NMEA_UPDATE_1HZ "$PMTK220,1000*1F"
38 #define PMTK_SET_NMEA_UPDATE_2HZ "$PMTK220,500*2B"
39 #define PMTK_SET_NMEA_UPDATE_5HZ "$PMTK220,200*2C"
40 #define PMTK_SET_NMEA_UPDATE_10HZ "$PMTK220,100*2F"
41 // Position fix update rate commands.
42 #define PMTK_API_SET_FIX_CTL_100_MILLIHERTZ \
43  "$PMTK300,10000,0,0,0,0*2C"
44 #define PMTK_API_SET_FIX_CTL_200_MILLIHERTZ \
45  "$PMTK300,5000,0,0,0,0*18"
46 #define PMTK_API_SET_FIX_CTL_1HZ "$PMTK300,1000,0,0,0,0*1C"
47 #define PMTK_API_SET_FIX_CTL_5HZ "$PMTK300,200,0,0,0,0*2F"
48 // Can't fix position faster than 5 times a second!
49 
50 #define PMTK_SET_BAUD_115200 "$PMTK251,115200*1F"
51 #define PMTK_SET_BAUD_57600 "$PMTK251,57600*2C"
52 #define PMTK_SET_BAUD_9600 "$PMTK251,9600*17"
53 
54 #define PMTK_SET_NMEA_OUTPUT_GLLONLY \
55  "$PMTK314,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0*29"
56 #define PMTK_SET_NMEA_OUTPUT_RMCONLY \
58  "$PMTK314,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0*29"
59 #define PMTK_SET_NMEA_OUTPUT_VTGONLY \
61  "$PMTK314,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0*29"
62 #define PMTK_SET_NMEA_OUTPUT_GGAONLY \
64  "$PMTK314,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0*29"
65 #define PMTK_SET_NMEA_OUTPUT_GSAONLY \
67  "$PMTK314,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0*29"
68 #define PMTK_SET_NMEA_OUTPUT_GSVONLY \
70  "$PMTK314,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0*29"
71 #define PMTK_SET_NMEA_OUTPUT_RMCGGA \
73  "$PMTK314,0,1,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0*28"
74 #define PMTK_SET_NMEA_OUTPUT_RMCGGAGSA \
76  "$PMTK314,0,1,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0*29"
77 #define PMTK_SET_NMEA_OUTPUT_ALLDATA \
79  "$PMTK314,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0*28"
80 #define PMTK_SET_NMEA_OUTPUT_OFF \
81  "$PMTK314,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0*28"
82 
83 // to generate your own sentences, check out the MTK command datasheet and use a
84 // checksum calculator such as the awesome
85 // http://www.hhhh.org/wiml/proj/nmeaxor.html
86 
87 #define PMTK_LOCUS_STARTLOG "$PMTK185,0*22"
88 #define PMTK_LOCUS_STOPLOG "$PMTK185,1*23"
89 #define PMTK_LOCUS_STARTSTOPACK \
90  "$PMTK001,185,3*3C"
91 #define PMTK_LOCUS_QUERY_STATUS "$PMTK183*38"
92 #define PMTK_LOCUS_ERASE_FLASH "$PMTK184,1*22"
93 #define LOCUS_OVERLAP \
94  0
95 #define LOCUS_FULLSTOP 1
96 
97 #define PMTK_ENABLE_SBAS \
98  "$PMTK313,1*2E"
99 #define PMTK_ENABLE_WAAS "$PMTK301,2*2E"
101 
102 #define PMTK_STANDBY \
103  "$PMTK161,0*28"
104 #define PMTK_STANDBY_SUCCESS "$PMTK001,161,3*36"
105 #define PMTK_AWAKE "$PMTK010,002*2D"
106 
107 #define PMTK_Q_RELEASE "$PMTK605*31"
108 
109 #define PGCMD_ANTENNA \
110  "$PGCMD,33,1*6C"
111 #define PGCMD_NOANTENNA "$PGCMD,33,0*6D"
112 
113 #define MAXWAITSENTENCE \
114  10
115 /**************************************************************************/
116 #endif