[ntp:questions] how stable is GPS after startup

Chris Albertson albertson.chris at gmail.com
Tue Feb 14 20:34:47 UTC 2012

On Tue, Feb 14, 2012 at 11:53 AM, Ron Frazier (NTP)
<timekeepingntplist at c3energy.com> wrote:
> Hi all,
> I have my USB GPS running pretty well.  However, I have noticed a few
> occasions when it goes wonky.  Those are:
> a) Sometimes it appears to produce more consistent loopstats charts running
> the process on Above Normal priority (in Windows) rather than RealTime
> priority.  I have to do further testing and documentation on this.
> b) Sometimes, it appears to destabilize after about 3 days of operation, and
> offsets jump by a factor of 10 to over 100 ms.  I have to do more testing on
> this too, but I have noticed that unplugging and replugging the GPS appears
> to fix the problem.  This has prompted me on some occasions to unplug and
> replug the GPS before restarting NTPD after making any configuration
> changes.
> c) I have sometimes noticed a large offset on the order of 50 ms TO THE NIST
> SERVERS after restarting NTPD even though the PC was closely synchronized to
> under 5 ms just a minute or two before.  Note, the GPS is the preferred
> clock, AND, I have the GPS time fudged so it is in very close agreement with
> NIST.  So, normally, both the NIST servers and the GPS are reporting less
> than 5 ms of offset.
> So, my main question for this thread is about item c).  I know it has been
> said that NTPD takes a while to stabilize, but the phenomenon I mention
> doesn't always occur.  Sometimes, the very first report I get after
> restarting NTPD says I'm within 5 ms or so of GPS time and the NIST servers.
>  I was originally thinking NTPD was at fault, or possibly NTPQ or possibly
> the Meinberg server monitor.
> I'm now wondering if the GPS receiver is the problem.  I want to know if
> this theory is likely.  I have noted on an old hand held GPS I have, that,
> when it gets a fix, it will first say, for example, that it's accuracy is
> 150 ft, then later, maybe 70 ft, then, after a while, maybe 23 feet, and
> occasionally, 15 feet or so.  So, I'm wondering it my unit here is doing the
> same thing.  Maybe, when I first plug it in, it doesn't have an accurate
> position fix, and possibly, is not outputting the time as accurately.  Maybe
> that's why I see immediate offsets to all the NIST servers of 50 ms or more.
>  Then, later, after the GPS has been running 20 minutes or so, maybe it's
> position and time fix is much more accurate, so then I see my normal offsets
> to NIST of under 5 ms.  Does that make sense?

Much of the appearent problem may be that NTP is  measring offset with
respect to the system time and the system time is not stable.   With a
GPS I'd guess this is the case.

Yes the GPS will gain a better idea of it's location over time

The graph of stabilty over time most offen used is an ADEV plot.  Or
Allen Deviation plot.  This is really not hard.   the vertical axis is
deviation just like you learned in a statistics class.  The horz. axis
is the number of seconds yo collected sample data to compute the

adev plot for a good GPS should be a straight line going down forever,
until it hits some limit like the master clock at the GPS ground
control station at maybe one part on 10^14.

But when you first turn on the GPS it might take some minutes before
it outputs anything.   In fact a Motorola Oncore with no battery
backup and an indoor antenna can take an hour or more but about 1
minute is typical for most GPSes.

However a broken GPS can do "anything".   A few ways they can be
broken is if the antenna does not have a good view of the sky and a
sat. flies out of view or gets blocked by a tree.  or if you can see
the sky but there is "multipath" reflections.    Typically a hand held
GPS has very poor timing.  I have one that NTP always rejects. It
works well for sailboat racing (the velocity made good computation is
a godsend) but the unit is useless for timing.   If you GPS is doing
odd things, check that it can see at least four sats. and nothing bad
happened to the signal strength becuase the GPS signal i jammed.
(another good reason to have the GPS antenna on a mast outdoors.)

Chris Albertson
Redondo Beach, California

More information about the questions mailing list