[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Working Narrowband FM examples?

From: Gary Schafer
Subject: Re: Working Narrowband FM examples?
Date: Wed, 11 Aug 2021 11:12:35 -0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0

Hi, Nathan,

I'm with you on the "too far down in the weeds / eyes roll back in my head". I 
still do that even now. Just watch me in a staff meeting.

Sorry about the hardware question. Had it in my head that you'd tried *ANOTHER* 
SDR other than the HackRF. My bad. Yes, it should be capable of 20 MSam/sec. I 
*had* a HackRF, until I somehow managed to fry the front-end. Otherwise, I 
would have been trying your graphs on my own SDR.

You're on to something with regards to the GQRX vs Gnu Radio. However, I think it's just a case of 
matching the blocks and settings. GQRX is nothing more than a Gnu Radio graph in a really nice 
wrapper. However, after I dug into the code and tried to recreate the FM broadcast stereo receiver 
(the one put together by Alex Grinkov) in Gnu Radio, I noticed that, just as you stated, the audio 
doesn't sound as nice as it does using GQRX. Frankly, I heard a hiss on my Gnu Radio version that 
is not there in the GQRX version. But it must be settings. The hardware is the same (RTL-SDR, in 
this case) and, again, GQRX uses Gnu Radio blocks. I'm still going to try your graph with a RTL-SDR 
(still a 8-bit digitizer, same as the HackRF) to see if I can figure out how and why GQRX sounds so 
much nicer. This is peculiar. As they say, the best discoveries don't come from "Eureka!" 
moments, but from "Hmmm, that's peculiar" moments.



Hi Gary,

Thanks for the reading list.  I’m an engineer, so I have multivariate calculus
under my belt, but I’m not an electrical engineer, so sometimes when texts get
too down in the weeds my eyes roll back in my head and I start foaming at the
mouth, haha.

As for hardware, I mentioned in my opening post to the list that it’s a hackRF.
 It *should* be capable of up to 20MS/s all the way from 1MHz to 6GHz.  I’ve
ordered one of those RF shielding kits to hopefully address the noise problem.
Or at least, I’m not aware of any limitations on the hackrf’s sampling rate
other than the 20MHz upper limit (but I’m still digging!)

For the low pass filter in the Xlating block I’m calling out to firdes:

firdes.low_pass(1, 8e6, 5000, 1700)

On Aug 9, 2021, at 17:05, Gary Schafer <schafer@site2241.net> wrote:

Several points:

1) Further reading: "Digital Signal Processing" by Steven Smith and "Understanding Digital Signal Processing" by Rick Lyons. Smith makes his book available for download at https://www.dspguide.com/. Lyons has many of his stuff scattered around "DSPRelated.com" (https://www.dsprelated.com/). Unlike your usual textbooks, these books actually *EXPLAIN* stuff, not just throw some math proofs at you and say, "See how easy it is to understand?"

2) What hardware are you actually using? USRP? RTL-SDR? HackRF? Something else? I've found that the HackRF, while it covers a huuuuuge frequency range relative to most other inexpensive SDRs, it also has a much worse noise figure.

3) 384k wasn't too *low*. I was guessing it was just *outside* of what the hardware can handle. If the hardware *could* handle it, then you would not have had the issue you did. The RTL-SDR, for example, can only handle sample rates between 200 kHz - 300 kHz, then jumps to 0.9 - 3.2 MHz. Anything outside of that range gets pushed to the closest sample rate the device can handle. The few times I've managed to play with a USRP, I've found that it can only handle sample rates that are values of 100 MHz / N, where "N" is an integer. As you discovered with whatever hardware you're actually using, if you use a sample rate that will work with the hardware, you can change it in Gnu Radio to whatever you *need* it to be.

4) I'm game for a comparison between GQRX and Gnu Radio. We need to make sure we have similar settings between them. I don't think the sample rate is the problem. So long as you're within the parameters that the particular SDR wants, AND you are meeting Nyquist, you should be golden. To me, so long as you're using the same hardware, the critical aspects of comparing audio from an FM signal are ensuring we have the same filters and that we're using the same demodulator. I'm willing to bet large sums that the GQRX is using a polar discriminator. That's the same as the "Quadrature Demod" block in Gnu Radio. Easy enough. But what of the filtering? I can't see what parameters you've selected for your lowpass filter in your attached PNG (and, by the way, you get major kudos for including those... makes troubleshooting infinitely easier!) What are your stop frequency and transition width for your lowpass filter (used in your "Frequency Xlating FIR Filter")?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]