|
From: | Juergen Harms |
Subject: | Re: [avr-chat] GPS based digital clock |
Date: | Tue, 10 Jul 2007 18:24:47 +0200 |
User-agent: | Thunderbird 2.0.0.4 (X11/20070620) |
Basic concept: (1) use a normal crystal oscillator (14.xxx Mhz for me), (2) add a polynomial correction to correct for the deviation between (a) its effective frequency (which nominally may not be precisely a decimal fraction of a second and is also subject to variations between individual crystals), (3) do all the evident junk to get human readable wall-time, do lap-year and daylight saving-time correction (4) receive and decode the FM signal from the standard time transmitter, (5) whenever you receive a valid value from the FM source, synchronise your crystal time with that value (preferably doing this smoothly to avoid upsetting the applications that use your time base).
In case you are interested in the corresponding code, say so. If you are interested in the DCF time source, most distributors of electronic components sell antennas and receivers for a few bucks worth. Personally, I have tried two, one distributed by Conrad and one distributed by Distrelec and have a clear preference for the latter. You can directly feed its output to an input pin of your AVR (I have long leads and use a balanced pair for transmission).
Good luck, Juergen
[Prev in Thread] | Current Thread | [Next in Thread] |