From f73fddfb81820a3ef708d992aa8b197890867f0a Mon Sep 17 00:00:00 2001 From: Kai Harrekilde-Petersen Date: Sun, 18 Mar 2018 13:40:02 +0100 Subject: [PATCH 2/2] processPSTI: silently ignore 003 sentences. nmea_parse: ignore DTM and GRS sentences. Signed-off-by: Kai Harrekilde-Petersen --- driver_nmea0183.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/driver_nmea0183.c b/driver_nmea0183.c index eb3d881..28d5dba 100644 --- a/driver_nmea0183.c +++ b/driver_nmea0183.c @@ -1654,6 +1654,13 @@ static gps_mask_t processPSTI(int count, char *field[], "PSTI,001: Count: %d\n", count); return mask; } + if (0 == strcmp("003", field[1])) { + /* Unknown message sent by S1216/Venus8 FW v2.2.4 */ + /* Seen: 003,[123] */ + gpsd_log(&session->context->errout, LOG_DATA, + "PSTI,003: Value: %d\n", atoi(field[2])); + return mask; + } if (0 == strcmp("005", field[1])) { /* GPIO 10 event-triggered time & position stamp. */ gpsd_log(&session->context->errout, LOG_DATA, @@ -1795,6 +1802,8 @@ gps_mask_t nmea_parse(char *sentence, struct gps_device_t * session) {"TXT", 5, false, processTXT}, {"ZDA", 4, false, processZDA}, {"VTG", 0, false, NULL}, /* ignore Velocity Track made Good */ + {"DTM", 0, false, NULL}, /* ignore Datum updates */ + {"GRS", 0, false, NULL}, /* ignore GPS Range Residuals */ }; int count; @@ -1830,7 +1839,7 @@ gps_mask_t nmea_parse(char *sentence, struct gps_device_t * session) if (*p == '*') *p++ = ','; /* otherwise we drop the last field */ #ifdef SKYTRAQ_ENABLE_UNUSED - /* $STI is special, no trailing *, or chacksum */ + /* $STI is special, no trailing *, or checksum */ if ( 0 != strncmp( "STI,", sentence, 4) ) { skytraq_sti = true; *p++ = ','; /* otherwise we drop the last field */ -- 2.7.4