[time-nuts] GPSDO with all-digital phase/time measurement?

Hal Murray hmurray at megapathdsl.net
Thu Feb 27 08:00:14 UTC 2014


haunma at keteu.org said:
> That being said, I find myself wondering as follows: Suppose that we count
> OCXO cycles (at, say, 10 MHz) using one of the MCU's timer/counter
> peripherals, and periodically sample the counter value with an interrupt
> triggered on the rising edge of the GPS 1pps.  Assume that this interrupt is
> the highest priority in the system, so that our measurement is fully
> deterministic, having only the +/- one cycle ambiguity inherent in the
> counting.  Also assume that we keep the counter running continuously. 

In general, things like "highest priority interrupt" don't guarantee what you 
want.  The fine print depends upon your MCU.  Some instructions take more 
than 1 cycle.  Consider what happens if your interrupt arrives just after 
another interrupt got started.

For this problem, I'd check the fine print on the counter/timers.  They often 
have a mode where it will copy the counter to a holding register (and 
generate an interrupt) on the rising edge of an input pin.  If you also get 
an interrupt on the counter overflowing, you can work out the total number of 
cycles between rising edges.

----------

The other problem you need to be aware of if you want to build a GPSDO is 
hanging bridges.
  tvb: Motorola GPS M12+ Sawtooth
  http://www.leapsecond.com/pages/m12/sawtooth.htm
  Tom Clark and Rick Hambly: Timing for VLBI
  http://gpstime.com/files/tow-time2009.pdf


-- 
These are my opinions.  I hate spam.






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