[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: gpsd losing connection to ublox
From: |
Niall Parker |
Subject: |
Re: gpsd losing connection to ublox |
Date: |
Thu, 11 Nov 2021 13:34:12 -0800 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 |
On 2021-11-11 12:44 p.m., Gary E. Miller wrote:
And it shows gpsd is sending on NTP0 and NTP2, which is odd considering
what I though was you configuration.
How exactly are you running gpsd? Put another way, what is
the output of this, run as root:
# pstree -paul | fgrep gpsd
|-gpsd,18077,nobody -n -s 115200 /dev/ttyTHS1 /dev/pps0
| |-{gpsd},18305
| `-{gpsd},18308
| |-grep,17309 -F --color=auto gpsd
mostly been starting gpsd via systemd, which pulls in config info from
/etc/default/gpsd
# Default settings for the gpsd init script and the hotplug wrapper.
# Start the gpsd daemon automatically at boot time
START_DAEMON="true"
# Use USB hotplugging to add new USB devices automatically to the daemon
USBAUTO="true"
# Devices gpsd should collect to at boot time.
# They need to be read/writeable, either by user gpsd or the group dialout.
DEVICES="/dev/ttyTHS1 /dev/pps0"
# Other options you want to pass to gpsd
GPSD_OPTIONS="-n -s 115200"
though gpsd doesn't seem to start on reboot properly, needing a manual
kick once I can ssh in ... probably some process sequence I should sort out.
... this gave me the clue it wasn't NTP1 I needed but rather NTP2,
adjusting that in ntp.conf and finally it was able to reach the PPS
signal.
Good, but fishy. What is you full ntp.conf now?
# /etc/ntp.conf, configuration for ntpd; see ntp.conf(5) for help
driftfile /var/lib/ntp/ntp.drift
leapfile /usr/share/zoneinfo/leap-seconds.list
# You must create /var/log/ntpstats (owned by ntp:ntp) to enable logging.
statsdir /var/log/ntpstats/
statistics loopstats peerstats clockstats
filegen loopstats file loopstats type day enable
filegen peerstats file peerstats type day enable
filegen clockstats file clockstats type day enable
# Comment this out if you have a refclock and want it to be able to
discipline
# the clock by itself (e.g. if the system is not connected to the network).
#tos minclock 4 minsane 3
# Specify one or more NTP servers.
pool us.pool.ntp.org iburst
# Use Ubuntu's ntp server as a fallback.
server ntp.ubuntu.com preempt
# Access control configuration; see
/usr/share/doc/ntpsec-doc/html/accopt.html
# for details.
#
# Note that "restrict" applies to both servers and clients, so a
configuration
# that might be intended to block requests from certain clients could
also end
# up blocking replies from your own upstream servers.
# By default, exchange time with everybody, but don't allow configuration.
restrict default kod nomodify nopeer noquery limited
# Local users may interrogate the ntp server more closely.
restrict 127.0.0.1
restrict ::1
# GPS Serial data reference (NTP0)
server 127.127.28.0 noselect
fudge 127.127.28.0 time1 0.134 refid GPS
# GPS PPS reference (NTP1)
server 127.127.28.2 prefer
fudge 127.127.28.2 refid PPS
This setup is running to refine the time1 fudge factor, will adjust when
good enough and stick with just GPS time (system will have intermittent
network access).
Found a note in https://gpsd.io/gpsd-time-service-howto.html this
might be the case for some GPS HATs, should have read it more
carefully ! ;)
But that is not what I would expect from MAGIC_HAT option.
I wasn't expecting the shift to NTP2 as hw is a Nvidia Jetson, not rpi
but I guess it has more to do with pps-gpio driver ?
Now that PPS is getting through I can follow the tuning procedure in
the howto, give it some time get some stats.
Patience, and ntpviz, are required to tune it. Ad tuning depends on
what you want to optimize.
Goal probably minimum jitter, system providing time to local cluster
sharing video tasks so synch within a frame time would be nice. Remote
and headless so will grab the data from /var/log/ntpstats and use ntpviz
locally, probably enough data now to get started.
... Niall
- gpsd losing connection to ublox, Niall Parker, 2021/11/09
- Re: gpsd losing connection to ublox, Gary E. Miller, 2021/11/09
- Re: gpsd losing connection to ublox, Niall Parker, 2021/11/09
- Re: gpsd losing connection to ublox, Gary E. Miller, 2021/11/09
- Re: gpsd losing connection to ublox, Niall Parker, 2021/11/10
- Re: gpsd losing connection to ublox, Gary E. Miller, 2021/11/10
- Re: gpsd losing connection to ublox, Niall Parker, 2021/11/11
- Re: gpsd losing connection to ublox, Gary E. Miller, 2021/11/11
- Re: gpsd losing connection to ublox,
Niall Parker <=
- Re: gpsd losing connection to ublox, Gary E. Miller, 2021/11/11
- Re: gpsd losing connection to ublox, Niall Parker, 2021/11/11
- Re: gpsd losing connection to ublox, Gary E. Miller, 2021/11/11
- Re: gpsd losing connection to ublox, Gary E. Miller, 2021/11/11
- Re: gpsd losing connection to ublox, Niall Parker, 2021/11/12
- Re: gpsd losing connection to ublox, Gary E. Miller, 2021/11/12
- Re: gpsd losing connection to ublox, Niall Parker, 2021/11/15
- Re: gpsd losing connection to ublox, Gary E. Miller, 2021/11/17
- Re: gpsd losing connection to ublox, Niall Parker, 2021/11/17
- Re: gpsd losing connection to ublox, Gary E. Miller, 2021/11/18