[ntp:questions] NMEA ref.clock better than my ISP's timeserver?

Unruh unruh-spam at physics.ubc.ca
Sat Jun 13 07:46:45 UTC 2009

David Lord <snews at lordynet.org> writes:

>Unruh wrote:
>> David Lord <snews at lordynet.org> writes:
>>> David J Taylor wrote:
>>>> David Lord wrote:


>> I get an average of 2usec from pps driving the parallel interrupt ( with
>> "myown" interupt service daemon). I think much of that is a) ntp's
>> handling of rate fluctuations, and b)natural variation in the interrupt
>> handling due to computer issues. My gps 18 has about a 20m run to the
>> computer, and is simply a "bar wire ( well one of the Cat5e twisted pair
>> wires) connection.

>Thanks for that Bill, to both you and David, I'll still make up
>the pcbs but will first try connecting with straight through cable.


>> Putting in a thermistor on top of the clock crystal and read the
>> temperature and use it to predict the rate variation. That will probably
>> give far better results than using a temperature controll. Also using
>> chrony ( which now has an shm refclock input at least in beta). will
>> give better results than ntp. 

> From my searches I had opposite impression, that patches to ntp
>for temperature compensation were good but not anywhere near as
>good as keeping crystal at constant temperature.

>Add to that a pps source probably takes system clocks largely
>out of the equation.

>I'm very happy to give chrony another try. I used it for a few
>years without problems when on dialup. I'm thinking of
>notebook rather than servers but I'd be happy to try on one of
>servers (webserver uses ntpd but has chrony-1.20nb3 which I
>guess is old).

Yes, that is old. The latest is 1.23 but 
Miroslav Lichvar has since then put in a patch for giving chrony an shm
refclock driver 
I am not sure if I can post the location of the patch, but his email is mlichvar 
at redhat dot com
This is beta software, so report to him if you find bugs.
It needs a line in chrony.conf
refclock SHM 1 poll 4 offset 0.0 refid GPS1
 (poll, offset, refid are optional) The "1" refers to the shm port
number (gpsd uses 1) 

Note that he finds that chrony is about a factor 20 better than ntp at
poll level 4 (I think there is something wrong there) and about 2-3
times better at poll level 3. I suspect this depends crucially on the
thermal behaviour of the computer. 

More information about the questions mailing list