-
Notifications
You must be signed in to change notification settings - Fork 2
ntpd setup
vaclavstepan edited this page Jun 7, 2016
·
6 revisions
Once GPS acquires 3-D fix, even after cold boot, ntp sets the time correctly.
This uses GPS NMEA protocol parser, directly reading from /dev/gps0, which now points to ttyACM0. Utilizes GPMRC records.
# /etc/ntp.conf, configuration for ntpd; see ntp.conf(5) for help
# Maybe this is not used?
pps /dev/pps0 assert hardpps
#
driftfile /var/lib/ntp/ntp.drift
# GPS data reference via SHM (NTP0)
#server 127.127.28.0 true
#fudge 127.127.28.0 refid GPS
# NMEA
server 127.127.20.0 prefer true minpoll 4 maxpoll 4
fudge 127.127.20.0 flag1 1 flag3 1 refid PPK
# Should enable another skips after initial one
tinker panic 0
# Do not share anything by deafult but local users are fine
restrict default ignore
restrict 127.0.0.1
restrict ::1
Running ppstest /dev/pps0
shows PPS as available, but so far the ntp does not seem to use it.
Add "-n" option into /etc/default/gpsd to make the daemon always poll. Anyway, the GPS daemon source alone seems to never get the fix. Together with the NMEA driver they work, with small time difference.
If time skip would be extreme (such as from 1980), removing drift file helps. NMEA driver seems valid, even if alone.