I have a Raspberry Pi 3 with Adafruit's Ultimate GPS Pi Hat. I was able to successfully install gpsd and chrony. I am now getting NMEA and PPS thumbs up But I have a weird issue.

The Ultimate GPS module is spitting out more NMEA messages that I want: I want only GPGGA and GPRMC....but it is also replying with GPGSA, GPGSV, and GPZDA.

So Adafruit has some Python code/libraries that allows you to interface with the GPS module and 'talk' to it. (https://github.com/adafruit/Adafruit_GPS). Using this code I was able to send the following packet using the PMTK command packet (https://cdn-shop.adafruit.com/datasheets/PMTK_A11.pdf)


I then opened up Putty and using a 9600 serial connection to /dev/ttyAMA0 I see indeed that only GPGGA and GPRMC are being processed out:

enter image description here BUT...as soon as I reopen gpsmon/gpsd, all the NMEA message streams are reactivated'...what the heck ??

If I don't open gpsd/gpsmon...indeed only GPGGA and GPRMC are active.

Has anyone come across this issue before ?

[enter image description here

  • Well, you don't need to use puTTY to read the longwinded, difficult to ciper, text messages. You may like to read my answer to the following question for tips to selectively read only the data you want. (raspberrypi.stackexchange.com/questions/98840/… ). Instead of using puTTY, you can use python to extract the data.
    – tlfong01
    Jul 1, 2019 at 1:37
  • Please don't post pictures of text. Instead paste the text direct into the question.
    – Ingo
    Jul 1, 2019 at 9:07

1 Answer 1


gpsd re-enables most sentence types when it detects that it is talking to the GPS chip that the Adafruit Ultimate GPS Hat uses (MTK3339).

The relevant code in gpsd reacts when it sees a sentence from the GPS Hat starting $PMTK705,, which identifies this GPS hardware. gpsd then sends a few configuration strings, including one for PMTK314:

// Set NMEA sentences.
(void)nmea_send(session, "$PMTK314,0,1,0,1,1,5,1,1,0,0,0,0,0,0,0,0,0,1,0");

There's no way in gpsd to disable this behaviour except a sledgehammer workaround, which is to invoke gpsd with the -b option to prevent it from writing to the device at all. On Raspbian, editing /etc/default/gpsd will do:

# Other options you want to pass to gpsd

Needless to say, disabling gpsd from writing to the device might have undesired consequences.

  • What possible reason could gpsd have to write to your GPS receiver? Other than to reconfigure it. Just use the -b option and you're done.
    – Dougie
    May 19, 2021 at 8:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.