gpsd-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gpsd-dev] [PATCH] Using GOODTIME_IS for UBX_MODE_TMONLY.


From: Håkan Johansson
Subject: [gpsd-dev] [PATCH] Using GOODTIME_IS for UBX_MODE_TMONLY.
Date: Mon, 14 Mar 2016 21:47:04 +0100
User-agent: Alpine 2.11 (DEB 23 2013-08-11)


Note: I have no ubx device; so no live testing.
Also have no idea how to put it in TMONLY mode.

scons check passes
---
 driver_ubx.c |    3 +++
 timehint.c   |    2 --
 2 filer ändrade, 3 tillägg(+), 2 borttagningar(-)

diff --git a/driver_ubx.c b/driver_ubx.c
index 41ebc24..e4a8211 100644
--- a/driver_ubx.c
+++ b/driver_ubx.c
@@ -205,6 +205,9 @@ ubx_msg_nav_sol(struct gps_device_t *session, unsigned char *buf,
     navmode = (unsigned char)getub(buf, 10);
     switch (navmode) {
     case UBX_MODE_TMONLY:
+       session->newdata.mode = MODE_NO_FIX;
+       mask |= GOODTIME_IS;
+       break;
     case UBX_MODE_3D:
        session->newdata.mode = MODE_3D;
        break;
diff --git a/timehint.c b/timehint.c
index e057339..c224d76 100644
--- a/timehint.c
+++ b/timehint.c
@@ -371,8 +371,6 @@ static char *report_hook(volatile struct pps_thread_t *pps_thread,
         * required on all Garmin and u-blox; safest to do it
         * for all cases as we have no other general way to know
         * if PPS is good.
-        *
-        * Not sure yet how to handle u-blox UBX_MODE_TMONLY
         */
        if (session->fixcnt <= PPS_MIN_FIXES &&
            (session->gpsdata.set & GOODTIME_IS) == 0)
--
1.7.10.4

reply via email to

[Prev in Thread] Current Thread [Next in Thread]