[ntp:questions] drift modeling question
hal-usenet at ip-64-139-1-69.sjc.megapath.net
Sun Jul 13 08:21:54 UTC 2008
>Correct, in that the linear correction will vary with temperature (and
>could be matched closely by a quadratic)
I don't think you can measure the temperature and/or drift accurately
enough to make quadratic corrections interesting.
>I am thinking of a least-squares fit to the drift data, versus
>temperature. Another poster mentioned that we really need temperature of
>the crystal, I agree, but there should be strong correlation between that
>(unknown) temperature and the motherboard or processor chip temperatures.
Years ago, I tried to measure things.
Most PCs have 2 xtals. One at 14.xxx MHz (cheap, 4X color burst)
that drives the CPU and most motherboard logic through a magic clock
generator (PLL) chip, and another that is a 32 KHz watch crystal for
keeping time when the CPU is off. The latter also makes interrupts
for the scheduler.
I had the temperature probe on the 14 MHz xtal. It didn't work very well.
I was assuming that the system used something like a cycle counter
(TSC) for timekeeping. That has troubles in multi-CPU systems.
The code I was actually running used the timer interrupts for
timekeeping and the TSC to interpolate between ticks.
Things got a lot better when I moved the probe to the 32 KHz xtal which
was in a corner of the board far from the CPU.
Here are a couple of graphs:
Again, read Mark Martinec's web page. He's got a lot of good
These are my opinions, not necessarily my employer's. I hate spam.
More information about the questions