[time-nuts] WWVB Signal Generator

Wayne Holder wayne.holder at gmail.com
Fri Aug 31 01:44:30 UTC 2018


I've had some luck improving things with my ATTiny85-based WWVB Simulator
design by replacing the crappy, 8 MHz internal oscillator with an 8 MHz
crystal and removing the tweaked timer values I had previously used.  In
addition, based on a suggestion from Paul Swed, I tried looping the antenna
wire a few times around the ferrite rod of a WWVB receiver module I
happened to have lying around and this also greatly improved things (see
photo on web page at
https://sites.google.com/site/wayneholder/controlling-time).  In fact, with
the ferrite rod in place, the BALDR clock now syncs even when completely
disconnected from being grounded to the ATTiny85 and the scope.

I've updated my web page, and the source code at the bottom of the page,
accordingly.  BTW, the SYNC output is now moved to pin 7 and the PPS output
is currently disabled in the code. In addition, I've added some additional
info on my web page about how to compile and download the program to an
ATTiny85 using ATTinyCore by Spence Konde.

I've ordered a 15.36 MHz crystal to try, as that should let the ATTiny85
generate a true, 60,000 Hz output but, so far, the 8 MHz crystal has helped
improve things quite a bit.  In addition, I plan to do more tests on
different types of antennas in order to see if I can make things even more
reliable and stable.

I still plan on reworking the code so it can also run on a 328-based
Arduino board but, currently, the Arduino IDE has no easy way to work with
boards that don't use a standard, 16 MHz crystal, as this frequency is used
by the serial port and, in turn, by the boot loader, so altering it can
break the ability to upload code.  This has actually caused some issues for
some of my other projects, so I'm investigating how this issue might be
handled.

Also, if anyone is interested in trying out other modulation schemes, I can
easily add a compile option t the code that will let it output a binary
low/high modulation signal instead of the PWM signal.

Wayne

On Thu, Aug 30, 2018 at 8:53 AM paul swed <paulswedb at gmail.com> wrote:

> Wayne as I work through the chronverter I do know the good phase tracking
> clocks really demand on frequency behavior. As I measured its +/- .6 Hz at
> 60 KHz. I believe the cheapy wall clocks are a bit wider, but not sure as
> they are hard to actually measure. They do use a small tuning fork crystal
> and from experience these are sharp. When I experimented with them they
> were maybe 5 Hz. Indeed the Chinese website had 25 X 60 KHz crystals for
> maybe $2.
> With respect to the antenna. My thinking is a loopstick resonated on 60 KHz
> and most likely driving it push pull or single ended. Thats 1 transistor if
> single ended as common collector if I had to guess. The reason is the
> micros put out a fair level of signal so its a case of upping current into
> the antenna. But it really will be a bit of experimenting.
> I did look at your code and that was so nice it opened up straight into the
> arduino IDE.
> Regards
> Paul
> WB8TSL
>
> On Thu, Aug 30, 2018 at 5:12 AM, Wayne Holder <wayne.holder at gmail.com>
> wrote:
>
> > For anyone trying out my ATTiny85 code, I've done some additional tests
> and
> > find that placement of the antenna near the clock is very finicky and, so
> > far, the only way to get a reliable decode of the time in the clock is by
> > using a scope to monitor the demodulated output and then moving the
> antenna
> > around until the demodulated signal lines up cleanly with modulated
> carrier
> > and there are no intra bit glitches.  This can take a bit of patience, so
> > clearly a better solution needs to be found.  I've found that any type of
> > glitch in the demodulated signal seems to prevent the clock chip from
> > decoding the time.
> >
> > It's possible the difficultly with locking onto my simulated WWVB signal
> > may be partially due to the design of the clock (from my location it's
> > never been able to to lock onto the real WWVB signal), but I have no
> > reference to compare it against so, for now, I have conclude that the
> > PWM-based modulation scheme my code uses may also be suboptimal for this
> > application.  To make testing even more frustrating, the BALDR clock I'm
> > using will only look for a signal for about 6 minutes before it goes to
> > sleep and I have to then power cycle the clock to get it to listen again.
> >
> > So, keep this in mind if you're going to try and replicate my results.
> >
> > Wayne
> >
> > On Wed, Aug 29, 2018 at 6:03 PM Wayne Holder <wayne.holder at gmail.com>
> > wrote:
> >
> > > For those that have asked for my to publish the source code for my
> > > ATTiny85-based WWVB simulator, I have put up a somewhat hurriedly
> written
> > > page on my google site at:
> > >
> > >   https://sites.google.com/site/wayneholder/controlling-time
> > >
> > > that describes a bit about how the code works, how to compile it using
> > the
> > > Arduino IDE, how I tested it, some issues I have observed in testing it
> > > and, at the bottom of the page, a downloadable zip file that contains
> the
> > > complete source code.
> > >
> > > Note: as mentioned at the top of this page, this is currently a work in
> > > process, so I'm not yet going to link the article to my main website
> > page,
> > > so you'll need to link in this post to find it.  Also, as draft, I'm
> > going
> > > to continue to revise the page until I feel the project is complete
> > enough
> > > to publish.  That means the source code zip file is going to
> potentially
> > > change from time to time, too.
> > >
> > > Wayne
> > >
> > > On Wed, Aug 29, 2018 at 1:35 AM Wayne Holder <wayne.holder at gmail.com>
> > > wrote:
> > >
> > >> As a follow up, I now have a simple WWVB simulator written in C that's
> > >> now running an an ATTiny85 using nothing more than the internal, 8
> > >> mHz oscillator and about a 6 inch length of wire connected to one of
> the
> > >> pins as an antenna.  It generates an approximate 60 kHz signal using
> > PWM on
> > >> timer 1.  I tweaked the timer value a bit to correct for some variance
> > in
> > >> the internal oscillator, but I' not even sure that was necessary, as
> my
> > >> target is just a  BALDR Model B0114ST, consumer grade "Atomic" clock.
> > >> Modulation is done by varying the duty cycle of the PWM to approximate
> > the
> > >> -17 dBr drop on the carrier.  But, again, I don't think this value is
> > >> critical with a consumer clock chip.  I tapped the demodulated output
> > >> inside the clock and displayed it on my scope along with the generated
> > >> signal and I got good, steady demodulation with the wire antenna just
> > >> placed near clock.  The next step is to connect up a GPS module and
> add
> > >> code to use it to set the time.  I'm also going to change the code to
> > use
> > >> the PPS signal from the GPS to drive the output timing rather than the
> > test
> > >> code I have now that uses timer 0 to generate the PPS interrupt.  I'm
> > happy
> > >> to share details if anyone is interested.
> > >>
> > >> Wayne
> > >>
> > >>
> > >>
> > >> On Sun, Aug 26, 2018 at 2:51 PM, paul swed <paulswedb at gmail.com>
> wrote:
> > >>
> > >>> That would be a great neighbor to have but I can tell you around here
> > its
> > >>> the phone. Not to concerned about someone putting up a wwvb
> > replacement.
> > >>> And I can always up the power. Chickle.
> > >>> Regards
> > >>> Paul
> > >>>
> > >>> On Sun, Aug 26, 2018 at 2:34 PM, Bob kb8tq <kb8tq at n1k.org> wrote:
> > >>>
> > >>> > Hi
> > >>> >
> > >>> > The gotcha is if you have neighbors two or three doors away that
> > *also*
> > >>> > put up one of
> > >>> > these devices. You then have a real problem with the neighbor(s) in
> > the
> > >>> > middle. The
> > >>> > wavelength is long enough that Raleigh issues won’t get you. You
> > still
> > >>> > have the two
> > >>> > signals ( at slightly different frequencies) beating against each
> > >>> other.
> > >>> > The result is
> > >>> > going to show up as who knows what to this or that receiver. With a
> > >>> > precision receiver,
> > >>> > you might even have issues from the guy two houses away …...
> > >>> >
> > >>> > Bob
> > >>> >
> > >>> > > On Aug 26, 2018, at 1:08 PM, paul swed <paulswedb at gmail.com>
> > wrote:
> > >>> > >
> > >>> > > Agree with the conversation. With respect to neighbors when the
> day
> > >>> comes
> > >>> > > they may ask you to boost your signal. :-)
> > >>> > > Granted maybe the day won't come but at least having your local
> > >>> clocks
> > >>> > work
> > >>> > > is nice.
> > >>> > > Regards
> > >>> > > Paul
> > >>> > > WB8TSL
> > >>> > >
> > >>> > > On Sat, Aug 25, 2018 at 10:29 PM, Dana Whitlow <
> > >>> k8yumdoober at gmail.com>
> > >>> > > wrote:
> > >>> > >
> > >>> > >> With the watch being physically close to the faux WWVB
> > >>> "transmitter",
> > >>> > one
> > >>> > >> is in
> > >>> > >> the so-called "near field" regime, where the field strength
> (V/m)
> > >>> falls
> > >>> > as
> > >>> > >> the inverse
> > >>> > >> cube of the distance.  If one is putting the watch, say, within
> a
> > >>> few
> > >>> > >> inches of the
> > >>> > >> transmitter, reliable reception should be available yet the
> signal
> > >>> > should
> > >>> > >> be literally
> > >>> > >> undetectable by any practical receiving device more than a few
> > feet
> > >>> > away.
> > >>> > >> Hence,
> > >>> > >> meeting the FCC field strength limit should be trivial.if the
> > >>> device is
> > >>> > >> used as pictured.
> > >>> > >> However, if one cranks up the power enough to reliably cover
> one's
> > >>> > entire
> > >>> > >> house,
> > >>> > >> then there might be a problem depending how close the nearest
> > >>> neighbor
> > >>> > >> lives,
> > >>> > >> even at levels well within the FCC limit he quotes.
> > >>> > >>
> > >>> > >> Taking the near field relationship in hand, 40 uV/m at 300m
> would
> > >>> > translate
> > >>> > >> into
> > >>> > >> a whopping 0.135 V/m at 20 meters range, more than enough to
> feed
> > >>> most
> > >>> > >> peoples'
> > >>> > >> entire house.  So the pragmatic issue would again be- neighbors.
> > >>> On the
> > >>> > >> other
> > >>> > >> hand, most of them would never be aware of the local signal as
> > long
> > >>> as
> > >>> > they
> > >>> > >> get good
> > >>> > >> time settings, unless they live close enough to Ft. Collins for
> > the
> > >>> two
> > >>> > >> signals to
> > >>> > >> contend with each other.
> > >>> > >>
> > >>> > >> It looks to me like the ferrite rod antenna is considerable
> > >>> overkill.
> > >>> > Even
> > >>> > >> with no
> > >>> > >> purposeful antenna I'd expect leakage to yield sufficient signal
> > >>> for at
> > >>> > >> least a few
> > >>> > >> inches.
> > >>> > >>
> > >>> > >> Dana
> > >>> > >>
> > >>> > >>
> > >>> > >> On Sat, Aug 25, 2018 at 8:11 PM Wayne Holder <
> > >>> wayne.holder at gmail.com>
> > >>> > >> wrote:
> > >>> > >>
> > >>> > >>> This guy has what looks like a well thought out design using a
> > >>> > Sirf-Based
> > >>> > >>> GPS and ATTiny44A chip to generate a signal to update his
> watch:
> > >>> > >>>
> > >>> > >>>  https://www.anishathalye.com/2016/12/26/micro-wwvb/
> > >>> > >>>
> > >>> > >>> Unfortunately, he doesn't seem to have published a schematic or
> > his
> > >>> > >> source
> > >>> > >>> code.  But, he covers enough detail that I think it wouldn't be
> > too
> > >>> > hard
> > >>> > >> to
> > >>> > >>> replicate what he's done.  Or, perhaps he would disclose these
> > >>> details
> > >>> > if
> > >>> > >>> contacted.
> > >>> > >>>
> > >>> > >>> Wayne
> > >>> > >>>
> > >>> > >>> On Sat, Aug 25, 2018 at 4:33 AM, D. Resor <
> > organlists at pacbell.net>
> > >>> > >> wrote:
> > >>> > >>>
> > >>> > >>>> I thought I would search in a different way for a WWVB signal
> > >>> > generator
> > >>> > >>>> design.  I found this item.  While the designer explains it
> > isn't
> > >>> as
> > >>> > >>>> accurate as WWVB it may be another starting point.
> > >>> > >>>>
> > >>> > >>>> http://www.tauntek.com/wwvbgen-low-cost-wwvb-time-
> > >>> > signal-generator.htm
> > >>> > >>>>
> > >>> > >>>>
> > >>> > >>>>
> > >>> > >>>> Donald R. Resor Jr. T. W. & T. C. Svc. Co.
> > >>> > >>>> http://hammondorganservice.com
> > >>> > >>>> Hammond USA warranty service
> > >>> > >>>> "Most people don't have a sense of humor. They think they do,
> > but
> > >>> they
> > >>> > >>>> don't." --Jonathan Winters
> > >>> > >>>>
> > >>> > >>>> _______________________________________________
> > >>> > >>>> time-nuts mailing list -- time-nuts at lists.febo.com
> > >>> > >>>> To unsubscribe, go to http://lists.febo.com/mailman/
> > >>> > >>>> listinfo/time-nuts_lists.febo.com
> > >>> > >>>> and follow the instructions there.
> > >>> > >>>>
> > >>> > >>> _______________________________________________
> > >>> > >>> time-nuts mailing list -- time-nuts at lists.febo.com
> > >>> > >>> To unsubscribe, go to
> > >>> > >>>
> http://lists.febo.com/mailman/listinfo/time-nuts_lists.febo.com
> > >>> > >>> and follow the instructions there.
> > >>> > >>>
> > >>> > >> _______________________________________________
> > >>> > >> time-nuts mailing list -- time-nuts at lists.febo.com
> > >>> > >> To unsubscribe, go to http://lists.febo.com/mailman/
> > >>> > >> listinfo/time-nuts_lists.febo.com
> > >>> > >> and follow the instructions there.
> > >>> > >>
> > >>> > > _______________________________________________
> > >>> > > time-nuts mailing list -- time-nuts at lists.febo.com
> > >>> > > To unsubscribe, go to http://lists.febo.com/mailman/
> > >>> > listinfo/time-nuts_lists.febo.com
> > >>> > > and follow the instructions there.
> > >>> >
> > >>> >
> > >>> > _______________________________________________
> > >>> > time-nuts mailing list -- time-nuts at lists.febo.com
> > >>> > To unsubscribe, go to http://lists.febo.com/mailman/
> > >>> > listinfo/time-nuts_lists.febo.com
> > >>> > and follow the instructions there.
> > >>> >
> > >>> _______________________________________________
> > >>> time-nuts mailing list -- time-nuts at lists.febo.com
> > >>> To unsubscribe, go to
> > >>> http://lists.febo.com/mailman/listinfo/time-nuts_lists.febo.com
> > >>> and follow the instructions there.
> > >>>
> > >>
> > >>
> > _______________________________________________
> > time-nuts mailing list -- time-nuts at lists.febo.com
> > To unsubscribe, go to http://lists.febo.com/mailman/
> > listinfo/time-nuts_lists.febo.com
> > and follow the instructions there.
> >
> _______________________________________________
> time-nuts mailing list -- time-nuts at lists.febo.com
> To unsubscribe, go to
> http://lists.febo.com/mailman/listinfo/time-nuts_lists.febo.com
> and follow the instructions there.
>



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