summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2009-09-21 14:56:37 +0000
committerEric S. Raymond <esr@thyrsus.com>2009-09-21 14:56:37 +0000
commit1978d039aaa7ccc44a7eeb50a0ddcd93687a8bf2 (patch)
treec14713ddbad722216b8c7de29649d6244166991b
parentc856f3357d38a6a43690e4e58dad8f2bd793f539 (diff)
downloadgpsd-1978d039aaa7ccc44a7eeb50a0ddcd93687a8bf2.tar.gz
Accept $GN and $GL NMEA prefixes associated with GLONASS.
-rw-r--r--packet.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/packet.c b/packet.c
index e0fb6488..0a71760a 100644
--- a/packet.c
+++ b/packet.c
@@ -84,6 +84,8 @@ others apart and distinguish them from baud barf.
*
* The NMEA portion of the state machine allows the following talker IDs:
* GP -- Global Positioning System.
+ * GN -- GLONASS, accoring to IEIC 61162
+ * GL -- Mixed GPS and GLONASS data, according to IEIC 61162
* II -- Integrated Instrumentation (Raytheon's SeaTalk system).
* IN -- Integrated Navigation (Garmin uses this).
*
@@ -237,7 +239,11 @@ static void nextstate(struct gps_packet_t *lexer,
lexer->state = GROUND_STATE;
break;
case NMEA_PUB_LEAD:
- if (c == 'P')
+ /*
+ * $GP == GPS, $GN = GLONASS only, $GL = mixed GPS and GLONASS,
+ * according to NMEA (IEIC 61162) DRAFT 02/06/2009.
+ */
+ if (c == 'P' || c == 'N' || c == 'L')
lexer->state = NMEA_LEADER_END;
else
lexer->state = GROUND_STATE;