diff options
author | Gary E. Miller <gem@rellim.com> | 2019-03-26 14:18:26 -0700 |
---|---|---|
committer | Gary E. Miller <gem@rellim.com> | 2019-03-26 14:18:26 -0700 |
commit | d08b925f855774c0bb0ad16e6aadc997ee8f9f0b (patch) | |
tree | b7d3dcd9a40ab84792e71f79e26ee167af4317e3 /driver_greis.c | |
parent | edf0686f65b3644ea28ab220f0f075e90b2d5dfd (diff) | |
download | gpsd-d08b925f855774c0bb0ad16e6aadc997ee8f9f0b.tar.gz |
driver_greis: Remove epx/epy computation. Do in gpsd_model_error().
Wow, all these various computations of epx/epy, all different...
Diffstat (limited to 'driver_greis.c')
-rw-r--r-- | driver_greis.c | 20 |
1 files changed, 8 insertions, 12 deletions
diff --git a/driver_greis.c b/driver_greis.c index 9e170e6a..d4bc1979 100644 --- a/driver_greis.c +++ b/driver_greis.c @@ -299,22 +299,18 @@ static gps_mask_t greis_msg_SG(struct gps_device_t *session, /* * All errors are RMS which can be approximated as 1 sigma, so we can just - * multiply to get the length used for GPSD confidence level. + * use them directly. * - * Make the simplifying assumption that error is the same for latitude and - * longitude, since GREIS does not provide those as precomputed components. - * A future improvement might be to compute the individual errors from the - * position covariance matrix, but only if this proves insufficient. + * Compute missing items in gpsd_error_model(), not here. */ - session->newdata.epx = session->newdata.epy = - hpos * (1 / sqrt(2)) * GPSD_CONFIDENCE; - session->newdata.epv = vpos * GPSD_CONFIDENCE; - session->newdata.eps = hvel * GPSD_CONFIDENCE; - session->newdata.epc = vvel * GPSD_CONFIDENCE; + session->newdata.eph = hpos; + session->newdata.epv = vpos; + session->newdata.eps = hvel; + session->newdata.epc = vvel; gpsd_log(&session->context->errout, LOG_DATA, - "GREIS: SG, epx: %.2f, epy: %.2f, eps: %.2f, epc: %.2f\n", - session->newdata.epx, session->newdata.epy, + "GREIS: SG, eph: %.2f, eps: %.2f, epc: %.2f\n", + session->newdata.eph, session->newdata.eps, session->newdata.epc); return HERR_SET | SPEEDERR_SET | CLIMBERR_SET; |