[time-nuts] Lowest Power NTP Server

Hal Murray hmurray at megapathdsl.net
Tue Dec 3 12:55:39 UTC 2019


If a Raspberry Pi fits your energy budget, that's probably the simplest way to 
go.  There are lots of them running with GPS hats.

> More or less, 0.5W on a 5AH 12V battery runs for 120 hours. Something at 5W
> only runs for 12 hours ….. 

My Kill-A-Watt alternates between 02 and 03 watts for a Pi 2B with USB WiFi 
and GPS.  I don't know how inefficient the wall wart is.

I have one of the little USB volt/amp meters, but I'll have to dig to find it.


> My target is “a couple of mili seconds” so a microsecond or five is sort of a
> non-issue.

What sort of client software are you considering?  Real ntp client or some 
hack?

Do you need accurate real time or can you post process things?

How good is your WiFi connection?  (more in another msg - long tail with a 
bump)  Real ntpd has a filter of 8 packets that ignores most of the outliers.  
Dumb ntp just smashes the clock to its calculated value which follows the tail 
wherever it leads.


> My main concern is that the clients are likely to be a bit “time challenged”
> and some of them could need fairly high update rates.  

What do you mean by "time challenged"?  Hardware or software?

Normally ntpd adjusts the clock rate to match the actual crystal.  It's called 
drift.  Deep inside the OS there is a magic constant that converts ticks from 
clock to ns.  You need a side door to adjust that constant.  Real NTP client 
software does a good job of using that knob.  It tracks temperature.

---------

I don't know of any NTP software that has been well tuned for working in ultra low power.  (But I haven't been looking and I don't track the literture.)  For low power, you probably want to turn off the CPU crystal and PLLs.  That turns into timekeeping using two clocks, the RTC while sleeping and the normal CPU crystal when running.  You need a way to recover the time from the RTC quickly and accurately and you also need to keep track of two clock drifts.

-- 
These are my opinions.  I hate spam.







More information about the Time-nuts_lists.febo.com mailing list