[LinuxPPS] kernel 2.6.32 - ntpd-4.2.6 linuxpps experiences

Luca Bertagnolio time at berta.com
Sat Dec 19 09:49:32 CET 2009


On Mon, Dec 14, 2009 at 03:18, Hal V. Engel <hvengel at astound.net> wrote:
> On Sunday 13 December 2009 03:34:30 pm clemens at dwf.com wrote:
> I had the same issue with an older version of ntp.  It appears that recent
> versions of LinuxPPS/kernel requires fairly recent versions of ntp to work
> with the Oncore.
>
>>
>> Not sure why, but that version is over a year old.
>> The ONCORE driver really hasnt had any changes.

I too have to report some oddities with 4.2.6 and the Oncore driver.

I do have two test machines, one running FreeBSD and ntpd 4.2.5p247RC,
and the other one running Gentoo Linux with kernel 2.6.32 and the
latest rc8 diffs applied, and ntpd 4.2.6.

The normal setup would call for a Garmin GPS18LVC to be connected to
the FreeBSD machine, flawlessly running a "production" environment,
while the Linux machine is more of a testbed, and so the Oncore VP is
connected there.  But I can of course swap the GPS between the two
machines, and doing this allowed me to unconver a strange oddity.

pps-ldisc module loads fine, ldattach 18 /dev/ttyS0 works OK, and I
immediately start to see the assert and clear events via sysfs, like
this:

dex ~ # cat /sys/class/pps/pps0/assert; cat /sys/class/pps/pps0/clear
1261188065.991711288#27
1261188066.190633240#27

But when I start ntpd-4.2.6 with the Oncore driver configured, all of
a sudden the clear events stop, and only the assert are seen by
LinuxPPS:

dex ~ # cat /sys/class/pps/pps0/assert; cat /sys/class/pps/pps0/clear
1261188096.661844987#56
1261188088.188679280#49
dex ~ # cat /sys/class/pps/pps0/assert; cat /sys/class/pps/pps0/clear
1261188115.985610379#58
1261188088.188679280#49
dex ~ # cat /sys/class/pps/pps0/assert; cat /sys/class/pps/pps0/clear
1261188118.985075113#61
1261188088.188679280#49
dex ~ # cat /sys/class/pps/pps0/assert; cat /sys/class/pps/pps0/clear
1261188119.984899420#62
1261188088.188679280#49

This in itself is already an oddity, but the weirdest thing happens
when I change configuration in ntpd and rather use the NMEA driver
(for the GPS18LVC) instead of the Oncore driver.

dex ~ # ldattach 18 /dev/ttyS0
dex ~ # cat /sys/class/pps/pps0/assert; cat /sys/class/pps/pps0/clear
1261210286.999856181#3
1261210287.179854642#3
dex ~ # cat /sys/class/pps/pps0/assert; cat /sys/class/pps/pps0/clear
1261210289.999855726#6
1261210290.179855910#6
dex ~ # cat /sys/class/pps/pps0/assert; cat /sys/class/pps/pps0/clear
1261210291.999856213#8
1261210292.179854198#8
dex ~ # /etc/init.d/ntpd start
 * Starting ntpd ...                                                      [ ok ]
dex ~ # cat /sys/class/pps/pps0/assert; cat /sys/class/pps/pps0/clear
1261210350.678257957#67
1261210350.858259211#67
dex ~ # cat /sys/class/pps/pps0/assert; cat /sys/class/pps/pps0/clear
1261210356.678257992#73
1261210356.858256277#73

Everything now seems to be working fine... the clear events are there.
 So is it the Oncore driver in ntpd-4.2.6 messing things up with
LinuxPPS?

I am really starting to get confused... I was hoping to get rid of the
FreeBSD machine rather sooner than later, but it looks like there is
more to research.  And I still have the Thunderbolt with the Palisade
driver to check out!

Ciao, Luca



More information about the LinuxPPS mailing list