summaryrefslogtreecommitdiff
path: root/nmea_parse.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2005-08-03 15:08:50 +0000
committerEric S. Raymond <esr@thyrsus.com>2005-08-03 15:08:50 +0000
commit6b30b6705628e417fab3bf67c48611b631ab3147 (patch)
tree4ea7fb02f90809d06e466ef831844f47c99a0e4f /nmea_parse.c
parent083ebe289b744df50b75775c6568de30b5aec616 (diff)
downloadgpsd-6b30b6705628e417fab3bf67c48611b631ab3147.tar.gz
We don't need dummy handlers to ignore sentences.
Diffstat (limited to 'nmea_parse.c')
-rw-r--r--nmea_parse.c25
1 files changed, 2 insertions, 23 deletions
diff --git a/nmea_parse.c b/nmea_parse.c
index 45753dd3..241ebd61 100644
--- a/nmea_parse.c
+++ b/nmea_parse.c
@@ -302,28 +302,6 @@ static gps_mask_t processGPGGA(int c UNUSED, char *field[], struct gps_device_t
return mask;
}
-static gps_mask_t processGPVTG(int c UNUSED, char *field[], struct gps_device_t *session)
-/* Track Made Good and Ground Speed */
-{
- /*
- This is mostly a placeholder to quell "unknown sentence" logs
-
- VTG,180.0,170.0,10.0,18.0,A, *42
- 180.0 True course over ground, 000 or 000.0
- 171.1 Magnetic course over ground, 000 or 000.0
- 10.0 Speed over ground in knots, 0.0 or 0.00
- 18.0 Speed over ground in kilometers/hr, 0.0 or 0.00,
- A Only in NMEA 2.3, A=Autonomous, D=Differential,
- E=estimated, N=Data not Valid
-
- */
- gps_mask_t mask;
-
- gpsd_report(3, "GPVTG\n");
- mask = 0;
- return mask;
-}
-
static gps_mask_t processGPGSA(int count, char *field[], struct gps_device_t *session)
/* GPS DOP and Active Satellites */
{
@@ -580,7 +558,7 @@ gps_mask_t nmea_parse(char *sentence, struct gps_device_t *session)
{"GLL", processGPGLL},
{"GSA", processGPGSA},
{"GSV", processGPGSV},
- {"VTG", processGPVTG},
+ {"VTG", NULL}, /* ignore this */
{"ZDA", processGPZDA},
{"PGRME", processPGRME},
#ifdef TNT_ENABLE
@@ -620,6 +598,7 @@ gps_mask_t nmea_parse(char *sentence, struct gps_device_t *session)
if (strlen(nmea_phrase[i].name) == 3)
s += 2; /* skip talker ID */
if (strcmp(nmea_phrase[i].name, s) == 0) {
+ retval = 0; /* unknown sentence */
if (nmea_phrase[i].decoder) {
retval = (nmea_phrase[i].decoder)(count, field, session);
strncpy(session->gpsdata.tag, nmea_phrase[i].name, MAXTAGLEN);