Author Topic: Decoding WWVB phase modulation  (Read 8156 times)

0 Members and 1 Guest are viewing this topic.

Offline jmwTopic starter

  • Frequent Contributor
  • **
  • Posts: 285
  • Country: us
Decoding WWVB phase modulation
« on: February 04, 2021, 04:04:23 pm »
For a while WWVB has had a BPSK-modulated signal that is supposedly more robust against fading and interference. What kind of discrete circuit would be used to demodulate it? For a exercise, I've wanted to make my own receiver that can output the baseband signal without using SDR.
 

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #1 on: February 05, 2021, 09:53:11 am »
I don't know for sure how to analog detect the phase signal in the WWVB signal, I'm much more of a digital guy, but a PLL would do the job.  The PLL would run at 60 kHz to match the carrier.  When the phase shifted the change in the output of the phase detector would shift.  If the tracking is fast enough the control signal would be a spike on every phase shift, either negative or positive. 

The phase shift of the signal is on top of the AM signal.  So when the AM is low the phase is harder to detect.  I suppose you might want to detect the low amplitude and disable the PLL tracking.  But if you can detect when the amplitude is low you don't need the phase detection. 

Or maybe it would be easier to do this the way I would do it in digital.  Have a fairly stable and accurate 60 kHz reference signal to beat against the incoming signal in quadrature and take the ratio.  Hmmm... that already sounds difficult in analog.  Any interest in doing this digitally?  Anyway, the quadrature ratio is the phase difference which will show a slow variation from the difference in frequency of the reference and the WWVB signal.  It will also show a sharp change at every phase shift.  Hmmm... the ratio actually won't change with a 180° change in phase due to the symmetry of the tangent.  But the sign of both portions of the quadrature signal will. 

I used to know how to do this, but I seem to have forgotten the details and a quick google search didn't help. 

I do recall that when the government produced this new format a company worked with them to design a chip which I guess they expected to sell to all the clock makers.  This company has a patent on the method of demodulating the time code signal.  I don't know if they priced the chip too high or what, but I've never seen a standard wall clock that made any claims about demodulating the phase and I'm sure if they were using the chip, they would be crowing about it. The patent still has over 10 years to go I believe.
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 

Offline CaptDon

  • Super Contributor
  • ***
  • Posts: 1740
  • Country: is
Re: Decoding WWVB phase modulation
« Reply #2 on: February 05, 2021, 02:30:04 pm »
There is a company that made WWVB timecode receivers that plugged into the Tektronix TM500 system power modules. Those receivers no longer work correctly because the modulation scheme is no longer used. I see the receivers for sale on Ebay from time to time but they are useless. Efratom I think was the company that made them. Blue colored single space plugin. They were sweet back in their day!!!!
Collector and repairer of vintage and not so vintage electronic gadgets and test equipment. What's the difference between a pizza and a musician? A pizza can feed a family of four!! Classically trained guitarist. Sound engineer.
 

Offline CaptDon

  • Super Contributor
  • ***
  • Posts: 1740
  • Country: is
Re: Decoding WWVB phase modulation
« Reply #3 on: February 05, 2021, 02:41:31 pm »
Those little plugin receivers were made by spectracom. They also had the WWVB rack mount models which I currently see on Ebay. I assume those are also not useful today since they had the same guts. Perhaps WWVB has some new modulation standard but I thought with all the GPS disciplined stuff today that WWVB has no compensation modulation scheme anymore????
Collector and repairer of vintage and not so vintage electronic gadgets and test equipment. What's the difference between a pizza and a musician? A pizza can feed a family of four!! Classically trained guitarist. Sound engineer.
 

Offline CaptDon

  • Super Contributor
  • ***
  • Posts: 1740
  • Country: is
Re: Decoding WWVB phase modulation
« Reply #4 on: February 05, 2021, 02:58:53 pm »
I see I am totally ass backwards on this, It is the new PM signal which has made the old Spectracom stuff useless. Sorry about that!! When the phase shifts the old Spectracom and others see this as a frequency/phase discrepancy which is out of tolerance and the error/unlock light comes on as the unit tries to re-establish phase coherency. Ouch, my bad, I just remember millions of dollars of WWVB disciplined oscillators becoming worthless. Cheers mates!!
Collector and repairer of vintage and not so vintage electronic gadgets and test equipment. What's the difference between a pizza and a musician? A pizza can feed a family of four!! Classically trained guitarist. Sound engineer.
 

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #5 on: February 05, 2021, 05:09:26 pm »
I see I am totally ass backwards on this, It is the new PM signal which has made the old Spectracom stuff useless. Sorry about that!! When the phase shifts the old Spectracom and others see this as a frequency/phase discrepancy which is out of tolerance and the error/unlock light comes on as the unit tries to re-establish phase coherency. Ouch, my bad, I just remember millions of dollars of WWVB disciplined oscillators becoming worthless. Cheers mates!!

The problem is the more accurate systems got the basic time from the modulated tone that was sent AM, but also locked to the 60 kHz carrier to get more accurate timing resolution.  Now that they added the phase modulation these units can't lock to the phase. 

The irony is to demodulate the phase signal requires detecting the carrier phase, just not blindly locking to it. 
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 

Offline jmwTopic starter

  • Frequent Contributor
  • **
  • Posts: 285
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #6 on: February 05, 2021, 05:40:07 pm »
Thanks! I'd eventually like to to do something like the wall clock idea (something microcontroller-based) instead of connecting to a full-blown PC SDR setup. So I think digitial demod is ok, and sampling and processing at > 2*60 kHz should be within the capabilities of microcontrollers, right?
 

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #7 on: February 05, 2021, 06:44:51 pm »
I looked at synchronous sampling in detail once.  I was going to sample at 240 kHz as the lowest frequency to give quadrature data (slower is lower power).  The input stream is multiplied by a pair of sine waves to give the I and Q streams which at 4x the carrier rate are just sequences of 1, 0, -1, 0.  After applying a simple filter the I,Q samples become (y(t)-y(t-2), y(t-1)-y(t-3)), so no math other than subtraction. 

There are short cut ways of taking the RMS of the samples (amplitude signal) and dividing to get the tangent.  I can't believe I didn't realize 180° phase shift doesn't change this ratio.  Hmmm... someone double check me on that.  Yeah, my calculator says they are the same.  So the sign has to be checked and that means both the I and the Q have to be checked since one could be very close to zero. 

While the amplitude squared can be accumulated as a running sum, the I and Q parts probably should be accumulated separately then the signs and phase angle calculated at the end of a sample period.  You want to track the phase angle (the tangent) to see how your oscillator is drifting wrt the carrier.  I was planning to integrate over 0.1 seconds.  The AM varies with a resolution of 0.2 sec, but the phase is constant for a full bit time, 1 second.  The phase changes when the amplitude is low so aligning to the edge of a second may be hard other than by using a long term integration.  Such a long term integration is not amenable to the lowest power levels, but is fine for wall powered equipment. 

Still, if you are trying to get the most accurate timing possible and you are not close enough to the transmitter to receive a good signal when the amplitude is low you may be limited in the accuracy you can achieve.
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 

Offline 5065AGuru

  • Frequent Contributor
  • **
  • Posts: 355
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #8 on: February 10, 2021, 01:30:43 am »
There are "de-bpsker" circuits that can make the old receivers useful again.
They have been described on the time nuts forum.

Cheers,

Corby
 

Offline Gregory

  • Regular Contributor
  • *
  • Posts: 59
  • Country: br
    • All Electronics Channel
Re: Decoding WWVB phase modulation
« Reply #9 on: February 11, 2021, 07:19:25 am »
Hello guys!

Here is a demo of a 2 PSK (BPSK) discrete demodulator, I'm not with the schematic here in this pc, but I can share later if it helps

 
The following users thanked this post: jmw

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 16621
  • Country: us
  • DavidH
Re: Decoding WWVB phase modulation
« Reply #10 on: February 11, 2021, 01:40:43 pm »
The circuit you are looking for is called a Costas loop and is relatively easy to implement in hardware.  It is also used for synchronous AM detection so you can recover the amplitude information at the same time without interference from the phase modulation.

https://en.wikipedia.org/wiki/Costas_loop
 
The following users thanked this post: jmw

Offline ZigmundRat

  • Regular Contributor
  • *
  • Posts: 126
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #11 on: February 17, 2021, 08:01:42 pm »
In the years since the BPSK was introduced to WWVB, I have yet to see a completed, functional, and reproducible BPSK clock and/or carrier recovery project. Plenty of times I've seen 'just do this' - but I've not seen anyone actually do it. It's also one thing to do it with a clean 60khz signal from a generator, but it's another to do it in the presence of all the noise on the WWVB carrier. I'm very interested to see if anyone actually makes progress on this.  :popcorn:
 

Offline octillion

  • Contributor
  • Posts: 37
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #12 on: February 18, 2021, 04:30:47 am »
The only readily available WWVB-BPSK decoder I know of is the EverSet ES100.  http://everset-tech.com/receivers/

I purchased the Universal-Solder application development kit a few months ago, and can verify it is fully functional.  After assembling and first power-on, it picked up the correct time in under 2 minutes in New York in the afternoon (signal propagation is best late at night).  In other power-ons it has taken a few minutes to pick up the time.  This is in my basement with stock antennas, and no attempt at optimizing location.
https://www.universal-solder.ca/product/canaduino-application-development-kit-with-everset-es100-mod-wwvb-bpsk-atomic-clock-receiver-module/
 
The following users thanked this post: edavid, seamusdemora

Offline ZigmundRat

  • Regular Contributor
  • *
  • Posts: 126
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #13 on: February 18, 2021, 02:17:38 pm »
By all accounts the Everset chips do their job pretty well. As a simple upgrade to consumer wall/desk clocks they are fine. However the accuracy of the Everset output is actually pretty poor, and there is no way to accomplish carrier recovery. So the problem remains. The closest I have seen is the “A Frequency Standard For Today’s WWVB” by John Magliacane, KD2BD. (http://www.arrl.org/files/file/QEX_Next_Issue/2015/Nov-Dec_2015/Magliacane.pdf] [url]http://www.arrl.org/files/file/QEX_Next_Issue/2015/Nov-Dec_2015/Magliacane.pdf[/url]). Unfortunately this doesn’t provide a restored 60khz signal.

I’d like to see a real implementation of the Costas loop (which would yield both timecode and recovered carrier). A bonus would be seeing both digital and analog implementations. It seems that with the abilities of the faster Teensy processors or PSoC a 60khz digital Costas loop should be quite possible, but I don’t know enough to even begin such a project.   
 

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #14 on: February 18, 2021, 11:20:22 pm »
By all accounts the Everset chips do their job pretty well.

Everset is the company that apparently worked with NIST to assure a receiver would be commercialized and has patents on much of the receiver technology implemented in chips.  That's probably why you don't see anyone else making them... that and the fact that the people making the clocks don't care.  I doubt very many consumers would pay $5 or $10 more for an "atomic" clock that is really only a benefit to a relatively few on the east coast. 

To appear in more serious equipment the chip is competing against an MCU implementation and has to be cheaper, lower power or cost less than a programmed MCU.  I'm not sure the Everset chip is any of those things.  The documents on their web site seem to show a very basic receiver really, but they may only be marketing materials.  One of the docs shows their chip as simply being an MCU!
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 

Offline rcbuck

  • Frequent Contributor
  • **
  • Posts: 346
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #15 on: February 19, 2021, 12:03:28 am »
La Crosse Technology has had a wall clock (1235UA) out for several yeats that decodes the phase modulation. They sell it for $76 but I have seen it on sale for $40 at Lowes big box store a couple of times. There is even a tear down of the clock here:

http://leapsecond.com/pages/ultratomic/

Quote
Still, if you are trying to get the most accurate timing possible and you are not close enough to the transmitter to receive a good signal when the amplitude is low....
You don't need to detect the signal when it is low. You use the low (or no) signal to determine the beginning of each second. Using either the old st\yle AM decoding or new style PM decoding you would be able to get within 50-100 milliseconds of the corect time. That is good enough for any consumer clock.

The QEX article that is referenced does actually provide a series of 1s and 0s at a TTL level that corresponds to the phase of the WWVB signal. But that requires duplicating the parts of his design that does that. That is roughly 12 ICs and about 30 resistors and 30 capacitors.

I have had email correspondence with John and am actually thinking about duplicating the parts of the circuit to extract the phase modulation. He doesn't extract the original 60 kHz signal but does have a 10 MHz output that is locked to the WWVB signal. The 10 MHz oscillator generates 7 other outputs using 74HC390 dividers.  The 10 MHz signal does not have the phase reversal present. That was the purpose of the article - eliminate the phase reversal so the WWVB signal could be used for Frequency measurement purposes. The unit's purpose wasn't built to decode the time but it does so using the old AM modulation process.

Quote
I doubt very many consumers would pay $5 or $10 more for an "atomic" clock that is really only a benefit to a relatively few on the east coast.
No, but government buildings, schools, medical centers, and other operations with dozens of wall clocks would. It is far less costly than paying someone to go around and set the clocks once per week. And it means the clock can be moved without having to call someone in relocate the wiring if the clocks are linked together over a PPOE connection. The medical center I go to has several of the "Atomic" clocks hanging on the wall. You can clearly see the little radio tower emblem on the face of the clocks.
 

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #16 on: February 19, 2021, 12:45:27 am »
La Crosse Technology has had a wall clock (1235UA) out for several yeats that decodes the phase modulation. They sell it for $76 but I have seen it on sale for $40 at Lowes big box store a couple of times. There is even a tear down of the clock here:

http://leapsecond.com/pages/ultratomic/


Yes, this is even more expensive than I expected.  I've bought RC clocks for $25 regular price. 

Quote
Quote
I doubt very many consumers would pay $5 or $10 more for an "atomic" clock that is really only a benefit to a relatively few on the east coast.
No, but government buildings, schools, medical centers, and other operations with dozens of wall clocks would. It is far less costly than paying someone to go around and set the clocks once per week. And it means the clock can be moved without having to call someone in relocate the wiring if the clocks are linked together over a PPOE connection. The medical center I go to has several of the "Atomic" clocks hanging on the wall. You can clearly see the little radio tower emblem on the face of the clocks.

Sure lots of places like RCCs.  But relatively few find they can't live with the $25 versions.  I don't know what you are talking about setting clocks every week.  My non-RCC clocks are only adjusted twice a year when the time changes.  The improvements from adding the phase modulation are largely unrealized because of a general lack of need in most areas and few adopters in the rest of the country where it might be of benefit. 

I am near DC, so in a poor reception area.  Yet it works just fine nearly every night.  NIST has coverage maps for 100 uV/m, the approximate threshold for amplitude demodulation.  I wonder if they have been calculated at an appropriate threshold for a phase modulated signal? 

Wow!  70 kW ERP!  I wonder how far that can be received in space?  It's "aimed" more along the surface of the earth, but that's got to be receivable at some considerable distance. 
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 

Offline rcbuck

  • Frequent Contributor
  • **
  • Posts: 346
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #17 on: February 19, 2021, 01:58:45 am »
Quote
I don't know what you are talking about setting clocks every week.
I guess it depends on the clock, how accurate they are, and how accurate you want the clocks to be. I think all the RC clocks I see are the old AM based ones.

I've got 6 clocks in my house. One of them loses over a minute per month. Three of them lose or gain less than a minute every 6 months. My RC wrist watch and home built GPS clock are never wrong. I'm in Phoenix so we don't change time. But if I did live in a DST place the wrist watch has the feature built in to handle that automatically. WWVB transmits the information and the watch software extracts it. I had to turn DST off to keep it from changing.

My family lives in North GA and when I go back for a visit the RC wrist watch picks up WWVB every night. It has an icon that tells if the reception was successful or not at the 2 AM hour. I think the problem people have in the upper NE part of the country is with interference from the MSF signal in the UK since it is also on 60 kHz.
 

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #18 on: February 19, 2021, 02:52:22 am »
That's my point about the phase modulation and the market.  Very few people need this to begin with.  Those people probably aren't going to pay much for the benefit. 

I was looking at this one time, how to aim an antenna.  I found WWVB is nearly 270° from my place near Wash DC.  Anthorn in the UK is 45° from my place, much more north than I would have expected, but that's great circles for you.
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 16621
  • Country: us
  • DavidH
Re: Decoding WWVB phase modulation
« Reply #19 on: February 19, 2021, 10:10:14 pm »
Everset is the company that apparently worked with NIST to assure a receiver would be commercialized and has patents on much of the receiver technology implemented in chips.  That's probably why you don't see anyone else making them... that and the fact that the people making the clocks don't care.  I doubt very many consumers would pay $5 or $10 more for an "atomic" clock that is really only a benefit to a relatively few on the east coast.

My understanding from when the change happened is that nobody wanted to risk Everset's patent wrath.

That's my point about the phase modulation and the market.  Very few people need this to begin with.  Those people probably aren't going to pay much for the benefit.

The people who might need it are the ones whose clocks stopped working properly because of the modulation changes.
 

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #20 on: February 19, 2021, 10:22:40 pm »
Everset is the company that apparently worked with NIST to assure a receiver would be commercialized and has patents on much of the receiver technology implemented in chips.  That's probably why you don't see anyone else making them... that and the fact that the people making the clocks don't care.  I doubt very many consumers would pay $5 or $10 more for an "atomic" clock that is really only a benefit to a relatively few on the east coast.

My understanding from when the change happened is that nobody wanted to risk Everset's patent wrath.

That's my point about the phase modulation and the market.  Very few people need this to begin with.  Those people probably aren't going to pay much for the benefit.

The people who might need it are the ones whose clocks stopped working properly because of the modulation changes.

My understanding is the only units that stopped working are the ones that locked to the signal phase... in other words, the fancy, expensive ones.  lol 

I think there is a mitigation where the phase modulation is turned off periodically to allow such units to sync up. 
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 

Offline rcbuck

  • Frequent Contributor
  • **
  • Posts: 346
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #21 on: February 20, 2021, 03:15:10 am »
Quote
My understanding from when the change happened is that nobody wanted to risk Everset's patent wrath.
I doubt that is the reason. BPSK has been around for a long time. Maybe they could patent their one chip solution (which I think is what they did) but patent the decoding scheme would not hold up. The decoding method for BPSK has been around since it was invented. It is probably as gnuarm says "Why bother with the extra cost of phase demodulation when AM demodulation works virtually everywhere."

Quote
I think there is a mitigation where the phase modulation is turned off periodically to allow such units to sync up.
From https://en.wikipedia.org/wiki/WWVB :
To allow users of phase tracking receivers time to adjust, the phase-modulated time code was initially omitted twice daily for 30 minutes, beginning at noon and midnight Mountain Standard time (07:00 and 19:00 UTC). This provided enough opportunity for a receiver to lock on to the WWVB carrier phase. This allowance was removed as of March 21, 2013.

I don't know how difficult it would be to use a micro such as an STM32 or PIC to decode the BPSK. It must not be easy or someone would have already published an article on how to do it. There is an article online that describes building a DCF77 receiver to decode the phase changes using a dsPIC33.
http://www.marvellconsultants.com/DCF/
 

Offline seamusdemora

  • Regular Contributor
  • *
  • Posts: 54
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #22 on: January 30, 2023, 07:52:38 am »
Hoping to resurrect this thread as there's a lot of good information here.

Anyway - I've become interested in building a SDR for WWVB. At this point, as long as I can still get a useful signal, I'm not particularly keen on phase modulation. I'm leaning more toward low, low cost receiver. I recently saw a post somewhere that led me to this GitHub repo for PiccoloSDR where the author has apparently developed code to use the ADC on a Raspberry Pi Pico to implement a direct-sampling receiver.

First question: Opinions on the viability of this as a WWVB receiver??
The trouble with the world is that the stupid are cocksure, and the intelligent are full of doubt.
~ Bertrand Russell
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 16621
  • Country: us
  • DavidH
Re: Decoding WWVB phase modulation
« Reply #23 on: January 30, 2023, 03:57:07 pm »
Quote
My understanding from when the change happened is that nobody wanted to risk Everset's patent wrath.

I doubt that is the reason. BPSK has been around for a long time. Maybe they could patent their one chip solution (which I think is what they did) but patent the decoding scheme would not hold up. The decoding method for BPSK has been around since it was invented.  ...

They would have patented every way they could think of for decoding the WWVB phase modulation as applied to WWVB, just to block other people from doing it, even while they only implemented one way.

The companies selling encrypted pay TV services worked this way to try and keep third party decoders off of the market.

First question: Opinions on the viability of this as a WWVB receiver??

There is no reason that it cannot be done, however the dynamic range requirements are considerable because of noise and interference unless significant filtering is done in the hardware.
« Last Edit: January 30, 2023, 04:03:05 pm by David Hess »
 

Offline seamusdemora

  • Regular Contributor
  • *
  • Posts: 54
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #24 on: January 30, 2023, 11:36:00 pm »
First question: Opinions on the viability of this as a WWVB receiver??

There is no reason that it cannot be done, however the dynamic range requirements are considerable because of noise and interference unless significant filtering is done in the hardware.


Anything more specific than "significant filtering"? I have always assumed that these receivers are fairly simple in design because they are inexpensive. But I've never actually seen a schematic for one of them.
The trouble with the world is that the stupid are cocksure, and the intelligent are full of doubt.
~ Bertrand Russell
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 16621
  • Country: us
  • DavidH
Re: Decoding WWVB phase modulation
« Reply #25 on: January 31, 2023, 12:49:44 am »
There is no reason that it cannot be done, however the dynamic range requirements are considerable because of noise and interference unless significant filtering is done in the hardware.


Anything more specific than "significant filtering"? I have always assumed that these receivers are fairly simple in design because they are inexpensive. But I've never actually seen a schematic for one of them.

The ones I have seen use considerable filtering to prevent noise outside of the channel from overloading the mixer stages, and the same would apply to a direct conversion or SDR design.  The HF bands are very noisy, which is why an RF amplifier to lower the noise figure of the receiver is not necessary.

For an SDR design, at least a preselector should be included.
 
The following users thanked this post: seamusdemora

Offline jpanhalt

  • Super Contributor
  • ***
  • Posts: 3479
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #26 on: January 31, 2023, 03:47:19 am »
Here's a link to one schematic: https://sidstation.loudet.org/hw-en.xhtml  I didn't bother to check whether the kits are still available.  I doubt it. 

The receiver I built basically used just the RF front end (attached).  My antenna was tuned.  It worked with ordinary ferrite core antennas, but I used a larger shielded loop design to get 24-hour reception at my location in Ohio.  If you just want a receiver, you can harvest one from an inexpensive "atomic clock" off ebay.
 
The following users thanked this post: seamusdemora

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #27 on: January 31, 2023, 04:14:21 pm »
Hoping to resurrect this thread as there's a lot of good information here.

Anyway - I've become interested in building a SDR for WWVB. At this point, as long as I can still get a useful signal, I'm not particularly keen on phase modulation. I'm leaning more toward low, low cost receiver. I recently saw a post somewhere that led me to this GitHub repo for PiccoloSDR where the author has apparently developed code to use the ADC on a Raspberry Pi Pico to implement a direct-sampling receiver.

First question: Opinions on the viability of this as a WWVB receiver??

As long as you are only asking for opinions, and not facts...

I have mind designed a direct conversion WWVB receiver for some time now.  I would sample with a 1 bit ADC at 240 kHz.  The input signal can be mixed with an LO that consists of the pattern 0, 1, 0, -1 without multiplies.  Every other sample can be used as the I and Q signals, giving phase.  The amplitude can be approximated by adding the I and Q signals. 

For this to work, the sampling rate has to be pretty close to 240 kHz.  A VCO can be used by initially syncing it to a reference like a 32,768 kHz crystal (I was trying to keep the design minimal power).  240 kHz crystals exist, but are hard to find.  The phase samples should be averaged over 50 ms periods to extract the signal phase.  An offset to the VCO can be measured and subtracted out.  The VCO should be adjusted to minimize the phase drift.  I was going to use a set of binary valued capacitors to trim the VCO.  Or, if you can still find them, a varactor would do the job (tuning diode).  I think LEDs might make adequate tuning diodes.  The DC value on the diode can be adjusted using a 1 bit DAC (sigma delta). 

This is not terribly complex, but the devil is in the details.  I don't know how hard it will be to keep the 240 kHz oscillator stable.  It has to remain stable for ~100 ms, enough so that you can compare adjacent block phase and trim the oscillator frequency to suit. 

I almost forgot... the reason a 1 bit ADC will work, is because the oversampling creates a pretty good low pass filter.  At 240 kHz, a 50 ms window has 12,000 samples being averaged.  I seem to recall the number 6,000 samples in the average, so maybe I was looking at 25 ms windows.  It's a trade off between the processing gain (more samples) and timing resolution for signal changes (fewer samples).

I may have mucked up some details.  I think I looked at this maybe 20 years ago. lol  I was going to do it all in a low power FPGA.  SiliconBlue had a family with low double digit static power numbers.  Processing at these low rates would not create much dynamic current, so it could have run from a AA battery.  Lattice bought SiBlue and when the new 45 nm chip came out, it was more like 100 uA static current. 

I should still do this.  It would make for a radio controlled clock that could be powered by scavenged energy. 
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 
The following users thanked this post: seamusdemora

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #28 on: January 31, 2023, 04:25:23 pm »
Anything more specific than "significant filtering"? I have always assumed that these receivers are fairly simple in design because they are inexpensive. But I've never actually seen a schematic for one of them.

They generally get all needed selectivity from a 60kHz tuned ferrite rod antenna.

If you use a more broadband antenna you would need to add an LC bandpass or lowpass filter.

There aren't any significant noise sources until you get to the AM band at 540kHz.

There's a reason clocks adjust themselves at night.  Many noise generators are not running.  Noise sources in this band are everywhere today.  Switching power supplies often run at around 60 kHz.  Even if they are running at 100 or 200 kHz, that's not far enough away from 60 kHz to be effectively filtered out when they are 100 dB stronger than your signal.

The ferrite loopstick is essential.  It will need to be tuned with a fixed film capacitor and a variable cap.  Depending on where you are, the WWVB signal can be rather marginal.  You need all the help you can get in getting rid of the noise.  A tuned circuit also boosts the gain, if your input is high enough impedance. 

Or... you can go with a long wire antenna.  A quarter wave length is 1,250 meters.  lol

Actually, that could be coiled up, no?  It's still a lot of wire though. 
« Last Edit: January 31, 2023, 04:30:54 pm by gnuarm »
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 
The following users thanked this post: seamusdemora

Offline jpanhalt

  • Super Contributor
  • ***
  • Posts: 3479
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #29 on: January 31, 2023, 04:48:23 pm »
My shielded loop antenna was built as described here w/ minor modifications: https://www.febo.com/time-freq/wwvb/antenna/

Pictures attached.  Initial tuning was done with a large aircore capacitor then switched to mica caps for the final design.  As mentioned, I got pretty much 24-hour reception in Cleveland, OH; whereas, the ferrite cores only gave night reception.
 
The following users thanked this post: edavid, seamusdemora

Offline KE5FX

  • Super Contributor
  • ***
  • Posts: 1894
  • Country: us
    • KE5FX.COM
Re: Decoding WWVB phase modulation
« Reply #30 on: January 31, 2023, 06:06:07 pm »
Pictures attached.  Initial tuning was done with a large aircore capacitor then switched to mica caps for the final design.  As mentioned, I got pretty much 24-hour reception in Cleveland, OH; whereas, the ferrite cores only gave night reception.

Interesting.  I wonder what the rationale behind the antenna coupling is.  Not having played with large magnetic loop antennas before, what's the advantage to the single-turn secondary winding around the loop, assuming that the JFET input stage is located at the antenna? 

Would the performance be worse somehow if you simply tied the gate of Q1 directly to the hot end of C1/L1?  It's not as if you're going for grid-leak detection here, right?

I suppose peak voltage might be a concern, in environments where LF fields are strong enough to damage the FET.  But  that could be handled with a voltage divider, again with seemingly-equivalent results to the step-down effect from the one-turn secondary winding.
 

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #31 on: January 31, 2023, 06:55:14 pm »
I may have mucked up some details.  I think I looked at this maybe 20 years ago. lol  I was going to do it all in a low power FPGA.  SiliconBlue had a family with low double digit static power numbers.  Processing at these low rates would not create much dynamic current, so it could have run from a AA battery.  Lattice bought SiBlue and when the new 45 nm chip came out, it was more like 100 uA static current. 

I should still do this.  It would make for a radio controlled clock that could be powered by scavenged energy.

The iCE40s can run at 25-100 microwatts if you go off the 10 kHz internal oscillator. But seeing as you're in Puerto Rico, if we go off the inverse square law, you'd need either a 5 cm aperture (going off 1/r) or a 205 square meter aperture (going off 1/r^2) to run at 100% duty cycle. Probably a lot easier to scavenge power from other bands like WiFi, LTE, AM/FM terrestrial radio, etc.

Not sure how you came up with the power number you did.  They may have some very tiny parts in some of the newer iCE40 lines, but the static current is the limit of power.  I don't have the time to dig out the data sheets at the moment, but I'm pretty sure the spec was near 100 uA for most of their parts.  I don't know if this design would fit in 256 LUTs.

Even so, I wasn't planning to use RF power.  I was going to use temperature fluctuations or maybe solar cells.  The trouble is the messy circuits required to capture power from low power and intermittent sources.  That's a field of it's own.
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 

Offline mark03

  • Frequent Contributor
  • **
  • Posts: 711
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #32 on: January 31, 2023, 09:45:56 pm »
Pictures attached.  Initial tuning was done with a large aircore capacitor then switched to mica caps for the final design.  As mentioned, I got pretty much 24-hour reception in Cleveland, OH; whereas, the ferrite cores only gave night reception.

Interesting.  I wonder what the rationale behind the antenna coupling is.  Not having played with large magnetic loop antennas before, what's the advantage to the single-turn secondary winding around the loop, assuming that the JFET input stage is located at the antenna?

I'd also like to understand the design principles behind this.

In addition, I'm wondering how much selectivity this provides without further filtering.  If you connect a scope directly, can you see the WWVB signal?  I tried a multi-turn loop using ribbon cable, a plastic variable capacitor to resonate, and an instrumentation amp (no transformer).  I could see a signal near 60 kHz, but nothing exactly on frequency.

I'm in the odd position of thinking the DSP stuff to decode the phase modulation would be fairly easy (or at least fun), whereas the analog aspects of actually getting a signal to the A/D are what stumps me...
 

Offline seamusdemora

  • Regular Contributor
  • *
  • Posts: 54
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #33 on: January 31, 2023, 11:21:02 pm »

I have mind designed a direct conversion WWVB receiver for some time now.  I would sample with a 1 bit ADC at 240 kHz.  The input signal can be mixed with an LO that consists of the pattern 0, 1, 0, -1 without multiplies.  Every other sample can be used as the I and Q signals, giving phase.  The amplitude can be approximated by adding the I and Q signals. 

For this to work, the sampling rate has to be pretty close to 240 kHz.  A VCO can be used by initially syncing it to a reference like a 32,768 kHz crystal (I was trying to keep the design minimal power).  240 kHz crystals exist, but are hard to find.  The phase samples should be averaged over 50 ms periods to extract the signal phase.  An offset to the VCO can be measured and subtracted out.  The VCO should be adjusted to minimize the phase drift.  I was going to use a set of binary valued capacitors to trim the VCO.  Or, if you can still find them, a varactor would do the job (tuning diode).  I think LEDs might make adequate tuning diodes.  The DC value on the diode can be adjusted using a 1 bit DAC (sigma delta). 

<<snip>>

I should still do this.  It would make for a radio controlled clock that could be powered by scavenged energy.

I agree 100%... you should still definitely do this!  :-+

Some notes:

Note I (FWIW): I'm not particularly interested in the scavenged power aspect; batteries work fine for my intended usage.

Note II: I found this repo on GitHub wherein the author has some working code to implement a SDR using the ADC on a Raspberry Pi Pico:
(https://github.com/luigifcruz/pico-stuff/tree/main/apps/piccolosdr)
This seems a good start to me... Pico chips are available for US$1.00; an entire board for US$4.00; at 500 ksps max, the onboard ADC easily covers your proposed sampling rate.

Note III (Question): RE Varactors - They still seem to be available from several sources, and through distribution. Also, would it make any sense to use a PLL to set the bias on the varactor so that the antenna stays tuned at precisely 60kHz?
The trouble with the world is that the stupid are cocksure, and the intelligent are full of doubt.
~ Bertrand Russell
 

Offline seamusdemora

  • Regular Contributor
  • *
  • Posts: 54
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #34 on: January 31, 2023, 11:45:53 pm »
Millions of cheap WWVB clocks show that you don't need active tuning of the antenna.


But two of them I've owned suggest you need something more... They work for a while, and then they don't, they work in one location, but not another. My expectations were that the signal was only available in the late PM or early AM, but even that was wishful thinking in my experience. If not a tuned antenna, what's your opinion on how best to improve reception?
The trouble with the world is that the stupid are cocksure, and the intelligent are full of doubt.
~ Bertrand Russell
 

Offline seamusdemora

  • Regular Contributor
  • *
  • Posts: 54
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #35 on: February 01, 2023, 04:25:57 am »
Of course you need a tuned antenna, just not actively tuned.  By all means use a trim cap to get it on frequency.

To improve reception, use a physically larger antenna, point it in the right direction, and possibly add an RF amp.

Well, it's a very narrow-band signal, and as you know the S/N is not great. A larger antenna (larger than this ferrite core antenna) will likely be impractical in the application that I have in mind, and an rf amp will amplify both noise and signal AFAIK. What am I missing in your suggestion?

The trouble with the world is that the stupid are cocksure, and the intelligent are full of doubt.
~ Bertrand Russell
 

Offline seamusdemora

  • Regular Contributor
  • *
  • Posts: 54
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #36 on: February 01, 2023, 04:28:51 am »
the missing antenna picture (?? I hope)
The trouble with the world is that the stupid are cocksure, and the intelligent are full of doubt.
~ Bertrand Russell
 

Offline seamusdemora

  • Regular Contributor
  • *
  • Posts: 54
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #37 on: February 01, 2023, 07:58:44 pm »
You said that you wanted to build a receiver, and that's how you would go about it.  Now it seems like you've decided to build a clock, with some specific constraints you haven't mentioned, so I don't know if what you want is even possible  :-//


I haven't changed my mind, but you apparently made an assumption. Wrt constraints, and being possible, it seems to be possible as there are many clocks - even wrist watches - available. I replied to your post hoping to get some clarification on your recommendations, but it seems to have come across to you as something else. My apologies then - no offense was intended.
The trouble with the world is that the stupid are cocksure, and the intelligent are full of doubt.
~ Bertrand Russell
 

Offline jmwTopic starter

  • Frequent Contributor
  • **
  • Posts: 285
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #38 on: February 02, 2023, 04:21:55 am »
To get an idea of the noise you'll see in a direct sampling receiver, here is WWVB sampled at 192 kHz on a PC. Hardware is a tuned loopstick antenna and my preamp (https://eevblog.com/forum/rf-microwave/wwvb-preamp-help/ with some changes as suggested in the thread) that was wired to a 3.5 mm phono plug.

For a long time I thought the preamp didn't work at all, and then I tried starting the recording at various times and I got this a little after midnight. This is a screenshot in Audacity, the light purple is the RMS amplitude, and there's only about 3 dB difference between the peak and trough levels. Quite a bit worse than the advertised 17 dB difference in transmission levels. The duration of the dips are pretty consistent at .2 and .5 s as expected from the code. Some nights I'd get a clear signal like this for a good hour or so, and then it would disappear, and some nights get nothing at all.

I tried putting the recording into a GNU radio workflow for BPSK demodulation and never got anything meaningful out, but I guess others on this thread say it requires sampling at least 4x the frequency (is this result documented somewhere like the Nyquist theorem?) and my PC tops out at 192 kHz.


 
The following users thanked this post: seamusdemora

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #39 on: February 02, 2023, 06:46:32 am »

I have mind designed a direct conversion WWVB receiver for some time now.  I would sample with a 1 bit ADC at 240 kHz.  The input signal can be mixed with an LO that consists of the pattern 0, 1, 0, -1 without multiplies.  Every other sample can be used as the I and Q signals, giving phase.  The amplitude can be approximated by adding the I and Q signals. 

For this to work, the sampling rate has to be pretty close to 240 kHz.  A VCO can be used by initially syncing it to a reference like a 32,768 kHz crystal (I was trying to keep the design minimal power).  240 kHz crystals exist, but are hard to find.  The phase samples should be averaged over 50 ms periods to extract the signal phase.  An offset to the VCO can be measured and subtracted out.  The VCO should be adjusted to minimize the phase drift.  I was going to use a set of binary valued capacitors to trim the VCO.  Or, if you can still find them, a varactor would do the job (tuning diode).  I think LEDs might make adequate tuning diodes.  The DC value on the diode can be adjusted using a 1 bit DAC (sigma delta). 

<<snip>>

I should still do this.  It would make for a radio controlled clock that could be powered by scavenged energy.

I agree 100%... you should still definitely do this!  :-+

At the moment, I have a sizable contract in negotiation.  If I get that, I'll be pretty busy for at least 6 months, maybe 9 months.


Quote
Some notes:

Note I (FWIW): I'm not particularly interested in the scavenged power aspect; batteries work fine for my intended usage.

Note II: I found this repo on GitHub wherein the author has some working code to implement a SDR using the ADC on a Raspberry Pi Pico:
(https://github.com/luigifcruz/pico-stuff/tree/main/apps/piccolosdr)
This seems a good start to me... Pico chips are available for US$1.00; an entire board for US$4.00; at 500 ksps max, the onboard ADC easily covers your proposed sampling rate.

I'm a minimalist at heart, so I have a lot of interest in finding ways to do this using as little as possible.  The synchronous sampling at 4x the carrier frequency automatically down converts to DC.  The trick is to keep the sample rate stable and synchronous.


Quote
Note III (Question): RE Varactors - They still seem to be available from several sources, and through distribution. Also, would it make any sense to use a PLL to set the bias on the varactor so that the antenna stays tuned at precisely 60kHz?

I don't think it is important to tune the antenna in real time.  You can tune it on the bench, and it should remain pretty stable.  My idea is to tune the local VCO for the LO to be mixed with the incoming signal.  That will drift and needs to be updated in real time. If you run from a crystal, you still get some tens or even hundreds of ppm error, unless you go to lengths to stabilize them.  I can't remember off the top of my head how stable it needs to be, but maybe 200 ppm is not a problem.  I didn't want to use a fast crystal oscillator because it sucks down power.  32.768 kHz can be pretty light. That can be compared to 240 kHz at 128 Hz. 
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 
The following users thanked this post: seamusdemora

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #40 on: February 02, 2023, 06:52:42 am »
Millions of cheap WWVB clocks show that you don't need active tuning of the antenna.


But two of them I've owned suggest you need something more... They work for a while, and then they don't, they work in one location, but not another. My expectations were that the signal was only available in the late PM or early AM, but even that was wishful thinking in my experience. If not a tuned antenna, what's your opinion on how best to improve reception?

Tuned antenna, yes.  Just not real time adjustment of the tuning.  Unless your set up see extremes of temperatures, you won't have issues with the antenna tuning.  It's sharp, but not that sharp.

I know ham sets can have issues with tuned "magnetic" loops, where the bandwidth of the loop is more narrow than the voice signal being received!  Still, that's 4 kHz and you only need some tens of Hz.  The signal changes on 100 ms boundaries, with a minimum pulse spacing of 200 ms.  So 40 or 50 Hz bandwidth should be plenty.  I think you'll have a hard time getting your loop stick or even a large loop that narrow.  So if it drifts, you will still be in the tuning range.
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 
The following users thanked this post: seamusdemora

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #41 on: February 02, 2023, 07:03:13 am »
No one is challenging Nyquist.  I use 4x because that can be worked to give me I and Q to get phase (essentially Fs = 2 x BW for two signals).  The sampling at 2x trick only works if you are doing direct conversion, because it automatically down converts to DC.

In theory, you can demodulate the phase at a lower SNR than you can distinguish the amplitude changes.  That's why they added the phase modulation.  Then someone they were working with patented a receiver design.  No one (or very few) has produced a chip to demodulate the phase.  If you consider the market for most of these clocks, if the chip costs $0.50 more, it won't get used.  It's a bit like the Beta vs. VHS issue, Beta was better, but not demonstrably so.  How would you market the clock with the slightly better receiver? 
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 
The following users thanked this post: seamusdemora

Offline jpanhalt

  • Super Contributor
  • ***
  • Posts: 3479
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #42 on: February 02, 2023, 11:19:05 am »
@jmw (post#40)
Attached are images of what my analog signal looked like.  That was easily cleaned up easily with a PIC12F683/12F1840.

Unfortunately, I "finished" that project in 2014, and it is now buried in other papers.  Where in the US are you?
Edit: Corrected year
« Last Edit: February 02, 2023, 11:23:04 am by jpanhalt »
 
The following users thanked this post: seamusdemora

Offline jmwTopic starter

  • Frequent Contributor
  • **
  • Posts: 285
  • Country: us
Re: Decoding WWVB phase modulation
« Reply #43 on: February 02, 2023, 03:29:51 pm »
Central San Francisco, so there are probably lots of noise sources nearby at all times. I also have one of the Everset ES100 kits, and it is often able to get the time in the middle of the day, so the BPSK signal is definitely more robust than the AM signal.
 
The following users thanked this post: seamusdemora

Offline gnuarm

  • Super Contributor
  • ***
  • Posts: 2218
  • Country: pr
Re: Decoding WWVB phase modulation
« Reply #44 on: November 26, 2023, 10:18:01 pm »
Central San Francisco, so there are probably lots of noise sources nearby at all times. I also have one of the Everset ES100 kits, and it is often able to get the time in the middle of the day, so the BPSK signal is definitely more robust than the AM signal.

San Francisco is also relatively close to the WWVB transmitter, so easier to decode than much of the US, such as the east coast.   
Rick C.  --  Puerto Rico is not a country... It's part of the USA
  - Get 1,000 miles of free Supercharging
  - Tesla referral code - https://ts.la/richard11209
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf