Re: [chrony-users] Setting up Chrony with PPS |
[ Thread Index |
Date Index
| More chrony.tuxfamily.org/chrony-users Archives
]
- To: chrony-users@xxxxxxxxxxxxxxxxxxxx
- Subject: Re: [chrony-users] Setting up Chrony with PPS
- From: Bryan Christianson <bryan@xxxxxxxxxxxxx>
- Date: Fri, 19 Feb 2016 12:23:35 +1300
- Dkim-signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=smtpcorp.com; s=a0-2; h=Feedback-ID:X-Smtpcorp-Track:To:Message-Id:Date: From:Subject; bh=2sVAr2fkKe+5MBR4lAIeaO0K4T57u5uqy4Eg671s3bs=; b=zuRaVAYGRb3v n+mril9YA9NaqWvEQzALqWOC+O7V9HQTvMG/BDZngf2wVK8Z2g+Jn4yce1b8dl4x4/pxMIWn/AAe2 Qh7AV5a+Wl6zSbkdGPnhncvqYkKKTH0Be/Cr6fQtWCBSv+EN3CsvmyAh7+oer1FoB/r6zQS39d1vK Trd1D+8PVzbDT9SKcmGHIRqwSE41TpHdHBCxPpdcKzOBQCI19iAHlg80BdK1OC2oTLIrlh1vFpaU4 +LUs0UBYtPsdIv1nB50KqyNjFui51lA13CyTqVRhhsCceUhTq9JJFkwvvo2WGzO1OZckihFqLDrCE LLFUDWM+MPH53axZumn91A==;
- Feedback-id: 149811m:149811acx33YQ:149811s0qfy59KtE:SMTPCORP
> On 19/02/2016, at 12:07 PM, Tomalak Geret'kal <tom@xxxxxxxxx> wrote:
>
> On 18/02/2016 22:48, Deven Hickingbotham wrote:
>>
>>> $cat /sys/class/pps/pps0/assert
>>> 1455831692.018636856#178
>>>
>>> Are you seeing those?
>>>
>>
>> Yes, but just one timestamp per execution:
>>
>> pi@gps ~ $ cat /sys/class/pps/pps0/assert
>> 1455835119.289108505#4272
>> pi@gps ~ $ cat /sys/class/pps/pps0/assert
>> 1455835154.690359907#4305
>> pi@gps ~ $ cat /sys/class/pps/pps0/assert
>> 1455835157.936493770#4308
>> pi@gps ~ $ cat /sys/class/pps/pps0/assert
>> 1455835160.102904599#4310
>>
>
> Okay so your PPS looks fine.
>
> I think what's happening (and I'm half guessing but I did the following in the past to solve the same problem) is that you have two separate refclocks. One is your GPS NMEA (which is working), and the other is your PPS source ... which is only providing timing, not time.
>
> I believe you need to make it so that the PPS refclock is treated as a sort of extension of the GPS refclock, then prevent the GPS refclock from being selected on its own:
>
> refclock SHM 0 refid GPS precision 1e-1 offset 0.9999 delay 0.2 noselect
> refclock SOCK /var/run/chrony.ttyAMA0.sock refid PPS lock GPS
>
> I'm not sure why you see "PP" in the "chronyc sources" output - double-check your file on disk for dodgy line endings perhaps? Bit of a concern if the trailing "S" now gets truncated in my example above.
>
> Anyway, give that a try.
>
> Cheers
> Tom
I have this config working on a RP 2 - different PPP device but substituting your device for mine and adjusting the offsets to suit your device may work. I got this config from the gpsd web site
# SHM0 from gpsd is the NEMA data at 4800bps, so is not very accurate
refclock SHM 0 precision 1e-1 offset -0.135 delay 0.5 refid NEMA
# SHM1 from gpsd (if present) is from the kernel PPS_LDISC
# module. It includes PPS and will be accurate to a few ns
refclock SHM 1 offset 0.00135 delay 0.1 refid PPS
# SOCK protocol also includes PPS data and
# it also provides time within a few ns
refclock SOCK /var/run/chrony.ttyUSB0.sock offset 0.00135 delay 0.0 refid SOCK
Bryan Christianson
bryan@xxxxxxxxxxxxx
--
To unsubscribe email chrony-users-request@xxxxxxxxxxxxxxxxxxxx
with "unsubscribe" in the subject.
For help email chrony-users-request@xxxxxxxxxxxxxxxxxxxx
with "help" in the subject.
Trouble? Email listmaster@xxxxxxxxxxxxxxxxxxxx.