[ntp:questions] Using NTP to calibrate sound app

unruh unruh at invalid.ca
Sun Jan 27 19:33:30 UTC 2013

On 2013-01-27, no-one at no-place.org <no-one at no-place.org> wrote:
> @unruh: You are exactly right.  Whatever network jitter there is I
> just need to have a calibration run sufficiently long so that the
> derived frequency is close enough.  Given infinite time I can make

Well, no. the problem is that as time goes on, the clock itself has
frequency shifts ( temperature changes, crystal aging,...)

> arbitrarily precise frequency measurements.  Of course the limiting
> factor is user bother in putting up with a long calibration run.  I
> hope to mitigate that problem by the following:
> 1. This calibration is only needed once when the user installs my app.
> 2. The calibration, once initiated, will run unattended.  So the user
> will be instructed to start the calibration and then leave the
> smartphone alone.  During that time our app will have to be running
> continuously, so we will recommend that the user leave the phone
> plugged in to a charger, preferably overnight.  When he wakes in the
> morning the calibration will have been completed.

See above. After a few days, the sound crystal frequency will have
drifted ( whether enough to bother you I do not know). There is a
concept of the Allen minimum which gives essentially the ideal time
between calibrations. ntp has this problem and tries to alter the
calibration time scale to get to that minimum.
> Unfortunately the calibration software cannot be interrupted by a
> phone call.  So if it is interrupted the user will just be notified
> that the calibration was aborted because of the interruption and he
> will have to start the calibration run over again.  But I don't see
> that as a big problem.   My estimates of the time span now, based on
> expected network jitter, is about one hour.  It is not that hard to
> have one hour of uninterrupted time, especially if the user starts the
> calibration run just before retiring for the night.

> In case you are wondering, my app is a professional piano tuning app.
> The standard in this industry is that tuning devices should be
> accurate to 12 parts per million.  I know that is probably overkill
> for tuning pianos, but that is what the professionals expect from
> their equipment.

Ah. I would expect 1 cent, which is more like 500PPM.

> Robert Scott
> Hopkins, MN

More information about the questions mailing list