Re: [PIC] FSK demodulation
"Harold Hallikainen" <[email protected]> Thu, 24 Jul 2025 19:15:42 -0700
| Newsgroups | gmane.comp.hardware.microcontrollers.pic |
|---|---|
| Message-ID | <[email protected]> |
On Thu, July 24, 2025 5:07 pm, Dave Tweed wrote: > Harold -- > > >> I've been playing with AFSK demodulation (project at >> https://w6iwi.org/rtty/DspTU3/ ). I'm currently using biquad bandpass >> filters for mark and space, then comparing the level out of each to >> determine whether I am receiving mark or space. I also adjust the >> mark/space threshold based on the last received mark or space level to >> allow for selective fading. >> >> I've also heard of using the Goertzel algorithm to detect the mark and >> space tones. >> >> Is there an advantage to one or the other? The biquad filters seem >> pretty simple and operate on a sample by sample basis (instead of a >> block of samples). > > Goertzel is basically a one-channel DFT converted to recursive form, > which makes it pretty much equivalent to any IIR filter as far as > implementation. It will generally be significantly more selective (narrow > passband) compared to the biquads, which may or may not be an advantage in > your application. > > But to avoid the limitation of working only on blocks of samples, there's > no reason not to do the sliding-window DFT calculation directly, which > gives you a result on every sample. If you only care about two or three > frequencies, it's quite doable. > > I was messing around with this stuff myself some 30 years ago, trying to > decode the time signals from radio station CHU in Canada (their equivalent > of WWV). One element of their signal is a Bell-103 compatible burst of > data that I wanted to capture. I wrote up some of my efforts for Circuit > Cellar -- issues 83 and 84, June and July 1997. I was using an ADSP-2101 > evaluation board and was focusing mainly on FIR-based techniques. > > -- Dave Tweed Thanks! I'm working with 170 Hz and 850 Hz shift at 45 bps. I'm using a pair of cascaded biquads for mark and another for space. The bandwidth of each is 1.7 times the baud rate which results in close to 0 dB attenuation at the tone frequency +/- BR/2. The result is an eye diagram that goes to full amplitude on alternating bits. A narrower bandwidth attenuates that sideband resulting in the eye not going to full amplitude. Harold https://w6iwi.org -- Not sent from an iPhone.