[time-nuts] First success with very simple, very low cost GPSDO, under $8

Orin Eman orin.eman at gmail.com
Thu Apr 10 03:25:46 UTC 2014

On Wed, Apr 9, 2014 at 11:03 AM, Chris Albertson
<albertson.chris at gmail.com>wrote:

> On Wed, Apr 9, 2014 at 2:08 AM, Hal Murray <hmurray at megapathdsl.net>
> wrote:
> >
> > > Also any code that accesses them needs to do so with interrupts turned
> > > off...  otherwise you can wind up with corrupted values.
> >
> Forgot if I made this point but in a GPSDO when the interrupt is caused by
> the PPS, the interrupts are in effect off for 0.99999 seconds after each
> interrupt.   The software can assume an interrupt will never happen less
> then one second after an interrupt.  So the software does all the variable
> access within millisecond after each interrupt.
> These micro controllers are actually much easier to deal with than a
> general purpose multi-tasking operating system.  There is far less
> non-determinism.

Indeed.  I was just thinking the same thing.  It's much easier to deal with
an interrupt routine updating variables than multiple threads fighting over
them...   I just had to replace a mutex lock with an atomic exchange to
avoid a deadlock in my code at work.


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