diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2015-06-01 07:58:58 -0400 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2015-06-01 07:58:58 -0400 |
commit | 25a4dfb07f31a24e7ce09e8489eaf3f0a5dafa08 (patch) | |
tree | 8556824fab32534b9c3f243c4410af6cd3f39ef9 /driver_nmea0183.c | |
parent | f0dcc9854936518cea64e197cbbc5ac77aa6acd2 (diff) | |
download | gpsd-25a4dfb07f31a24e7ce09e8489eaf3f0a5dafa08.tar.gz |
Allow NMEA 4.1 GSVs in the NMEA0183 driver.
Diffstat (limited to 'driver_nmea0183.c')
-rw-r--r-- | driver_nmea0183.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/driver_nmea0183.c b/driver_nmea0183.c index 152de79a..996ddfcc 100644 --- a/driver_nmea0183.c +++ b/driver_nmea0183.c @@ -613,6 +613,9 @@ static gps_mask_t processGSV(int count, char *field[], * emit a GPGSV set followed by a GLGSV set. We have also seen a * SiRF-IV variant that emits GPGSV followed by BDGSV. We need to * combine these. + * + * NMEA 4.1 adds a signal-ID field just before the checksum. First + * seen in May 2015 on a u-blox M8, */ int n, fldnum; @@ -624,7 +627,11 @@ static gps_mask_t processGSV(int count, char *field[], session->gpsdata.satellites_visible = 0; return ONLINE_SET; } - if (count % 4 != 0) { + /* + * This check used to be !=0, but we have loosen it a little to let by + * NMEA 4.1 GSVs with an extra signal-ID field at the end. + */ + if (count % 4 > 1) { gpsd_log(&session->context->errout, LOG_WARN, "malformed GPGSV - fieldcount %d %% 4 != 0\n", count); |