[time-nuts] Holdover, RTC for Pi as NTP GPS source

Bob kb8tq kb8tq at n1k.org
Wed Nov 1 09:17:05 EDT 2017


> On Nov 1, 2017, at 12:14 AM, MLewis <mlewis000 at rogers.com> wrote:
> (I suspect this is drifting from the original thread too much, so new subject)
> Temperature ranges from 65F to 78F, with the potential for drafts, but is more typically 76F.

The gotcha in a real environment often involves people. They walk by (creating a draft). They 
turn on all the lights and equipment. They open or close the blinds to let in or block the sun. 
They tend to do this in an unpredictable / chaotic fashion. All of this makes a correction 
process based on “normal operation” a bit difficult. Something goes wrong, and the unit
goes into holdover. People suddenly start dashing around and the temperature is not 
what it has been ….


> I read about the NTPsec runs with insulating a Pi and running a load generating program to better maintain a stable core temperature.
> Just today I've put my GPS module inside a case for an RF shield that is also semi insulated. It's feeding LH on a PC while I do the next step.
> The Pi 3 is going inside a large enough tea tin and that will be lined with insulation.
> I'm wondering about insulating the RTC...
> The low cost for a 'precision' RTC means it is cheap to test.
> I'd completely discounted coasting with the system clock, as I have fixed in my head the variable loads on my production machine mean that Window's time lags variable amounts, as the CPU load is variable with variable burst loads every 1/8 of a second.
> Michael
> On 31/10/2017 11:45 PM, Hal Murray wrote:
>>> I'm intending to add a "precision" (well, precision to the Pi world) RTC  to
>>> my Pi 3 to use for a holdover source when it hasn't got PPS from the  GPS
>>> module.
>>> An RTC that +/- 3 PPM over 24 hours would be great for holdovers of one  to
>>> 20 minutes.
>> Run some experiments to collect some data and play with the numbers.
>> How stable is the temperature in your environment?
>> The key to keeping sane time on a PC or Raspberry PI is to calibrate the
>> crystal.  Most CPUs have a register that counts at the CPU clock frequency -
>> or something in that range.  Most systems smear the clock to keep the FCC
>> happy...
>> Most OSes keep time by watching that register and dividing by the clock rate.
>>  The actual clock rate doesn't usually match the number printed on the
>> crystal.  It's close, but ntpd can easily measure the error and tell the
>> kernel so the kernel can use the right value.  If you turn on loopstats, ntpd
>> will log it and you can graph it.
>> If you are writing an embedded system, you will want that sort of logic too.
>> My guess is that in the under 30 minute range, you will get better results by
>> just coasting with the system clock rather that using a RTC.  It would be an
>> interesting experiment.  Implement both clocking schemes and compare them.
> _______________________________________________
> time-nuts mailing list -- time-nuts at febo.com
> To unsubscribe, go to https://www.febo.com/cgi-bin/mailman/listinfo/time-nuts
> and follow the instructions there.

More information about the time-nuts mailing list