summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--driver_rtcm3.c10
-rw-r--r--gpsd_json.c2
2 files changed, 3 insertions, 9 deletions
diff --git a/driver_rtcm3.c b/driver_rtcm3.c
index 627b8713..de2fe16a 100644
--- a/driver_rtcm3.c
+++ b/driver_rtcm3.c
@@ -22,7 +22,7 @@ passing RTCM corrections to a GPS, which normally should just be
passed an entire correction packet for processing by their internal
firmware.
-Decodes of the following types have been verified: 1005
+Decodes of the following types have been verified: 1029,
This file is Copyright (c) 2010 by the GPSD project
BSD terms apply: see the file COPYING in the distribution root for details.
@@ -192,13 +192,7 @@ void rtcm3_unpack( /*@out@*/ struct rtcm3_t *rtcm, char *buf)
#define R1005 rtcm->rtcmtypes.rtcm3_1005
R1005.station_id = (unsigned short)ugrab(12);
ugrab(6); /* reserved */
- temp = ugrab(3);
- if ((temp & 0x04)!=0)
- R1005.system = NAVSYSTEM_GPS;
- if ((temp & 0x02)!=0)
- R1005.system = NAVSYSTEM_GLONASS;
- if ((temp & 0x01)!=0)
- R1005.system = NAVSYSTEM_GALILEO;
+ R1005.system = ugrab(3);
R1005.reference_station = (bool)ugrab(1);
R1005.ecef_x = sgrab(38) * ANTENNA_POSITION_RESOLUTION;
R1005.single_receiver = ugrab(1);
diff --git a/gpsd_json.c b/gpsd_json.c
index 8cde8229..78cc3f1f 100644
--- a/gpsd_json.c
+++ b/gpsd_json.c
@@ -1051,7 +1051,7 @@ void json_rtcm3_dump(const struct rtcm3_t *rtcm,
if (buf[strlen(buf)-1] == ',')
buf[strlen(buf)-1] = '\0';
(void)snprintf(buf + strlen(buf), buflen - strlen(buf),
- "],\"refstation\":\"%s\",\"sro\":\"%s\","
+ "],\"refstation\":%s,\"sro\":%s,"
"\"x\":%.4f,\"y\":%.4f,\"z\":%.4f,",
JSON_BOOL(rtcm->rtcmtypes.rtcm3_1005.reference_station),
JSON_BOOL(rtcm->rtcmtypes.rtcm3_1005.single_receiver),