diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2009-09-03 10:16:43 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2009-09-03 10:16:43 +0000 |
commit | ff1a623dbdca3fa26de67d88739d9a039b8e39ea (patch) | |
tree | e5dd06d01abeba8e9210f65f79d4c19eeeb4cb94 /driver_sirf.c | |
parent | d5755a55b8681c04ee0de3dc683124e581e47a9b (diff) | |
download | gpsd-ff1a623dbdca3fa26de67d88739d9a039b8e39ea.tar.gz |
Split eph into epx and epy internally...
...but still report eph by re-mixing them in the JSON dumper. This was
worth doing because all regression tests still pass, showing that
visible behavior for old-protocol users gas not changed.
Diffstat (limited to 'driver_sirf.c')
-rw-r--r-- | driver_sirf.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/driver_sirf.c b/driver_sirf.c index 7d169053..0aa284c3 100644 --- a/driver_sirf.c +++ b/driver_sirf.c @@ -477,6 +477,7 @@ static gps_mask_t sirf_msg_geodetic(struct gps_device_t *session, unsigned char { unsigned short navtype; gps_mask_t mask = 0; + double eph; if (len != 91) return 0; @@ -505,8 +506,10 @@ static gps_mask_t sirf_msg_geodetic(struct gps_device_t *session, unsigned char if (session->gpsdata.fix.latitude!=0 && session->gpsdata.fix.latitude!=0) mask |= LATLON_SET; - if ((session->gpsdata.fix.eph = getbesl(buf, 50)*1e-2) > 0) + if ((eph = getbesl(buf, 50)*1e-2) > 0) { + session->gpsdata.fix.epx = session->gpsdata.fix.epy = eph; mask |= HERR_SET; + } if ((session->gpsdata.fix.epv = getbesl(buf, 54)*1e-2) > 0) mask |= VERR_SET; if ((session->gpsdata.fix.eps = getbesw(buf, 62)*1e-2) > 0) |