[ntp:questions] NIST vs. pool.ntp.org ?
unruh at invalid.ca
Thu Mar 28 02:50:17 UTC 2013
On 2013-03-27, Richard B. Gilbert <rgilbert88 at comcast.net> wrote:
> On 3/27/2013 3:20 PM, Robert Scott wrote:
>> I am confused about the proper usage of pool.ntp.org and NIST.
>> pool.ntp.org seems to be a collection of private sector time servers
>> offered for all to use, but with registration expected for regular
>> users. And NIST has a government run set of time servers. Neither
>> group (NIST or pool.ntp.org) seems to include or referece the other.
>> Are they in competition? Who normally uses the NIST servers and who
>> uses pool.ntp.org?
>> I posted here several months ago about my specific application. I
>> want to use SNTP, not to synchronize a system clock but to make a
>> frequency measurement on the audio sampling rate in a smartphone. My
>> use of time servers will be very occasional - typically a user of my
>> app would only use the time servers once when the app is first
>> installed to do a calibration of the audio sampling rate in that
>> phone. And my app will have very limited circulation. So I won't be
>> hitting the servers very often at all.
>> Today I found the last bug that prevented me from getting response
>> from the time servers in my socket code. I had neglected to set the
>> port number (123) using htons(123) to put the port number in network
>> byte order. When I fixed that I finally started getting responses.
>> I have gotten responses from pool.ntp.org as well as several of the
>> NIST time servers listed on their website. However the round-robin
>> address of time.nist.gov does not seem to return anything. The recv()
>> function just times out. And I sure don't want to hard-code any of
>> the other NIST server URLs in my app. I was going to go with
>> pool.ntp.org until I saw the NIST servers that did not seem to be part
>> of the pool.
>> So I guess my main question is which servers should I use for my very
>> limited application?
>> Robert Scott
>> Hopkins, MN
> I think you need to start by defining the quality of time you need. Is
> 4:13 PM Eastern Timegood enough? Some people just want to "Get me to
> the church on time!" OR the bus, or the train or plane. A radio
> astronomer is almost certainly going to insist on time to the nearest
> nano second.
> Most of the range above is probably going to be "overkill" for most people.
> Please try to define your requirements a little more closely!
> Nano-seconds, "get me to the church/train/plane . . . . on time!" or
> something else.
He wants to calibrate the onboard clock on a cellphone/tablet to about
10PPM for an app he is writing to act as a tuner which is supposed to be
better than 1 cent in its tuning ability. He is willing to spend a few
hours on this (ie, the time accuracy needs to be about 10-100 ms), but then let the clock freewheel except perhaps an
occasional check that the calibration is still good.
At least that is how I understand it.
This app is to be sold to every musician in the world, and he is
wondering whether he should hard code the NIST IP into the phone to use
as an ntp server. (NONONONONO) or perhaps use the pool. I think he is
worried that since the pool does not apparently use NIST as the source
for the time, that the time in the pool is not good enough. He does not
really understand ntp and the pool, and GPS time and thus is worried
that using the pool might not be good enough for his needs.
More information about the questions