jgaeddert / liquid-usrp

Toy programs for SDR applications
http://liquidsdr.org
57 stars 26 forks source link

Help with asgram_rx rtl-sdr port #1

Closed mryndzionek closed 10 years ago

mryndzionek commented 10 years ago

Hello, I've ported the asgram_rx app to rtl-sdr. It looks like it works. I can see the 433MHz ISM band traffic, 88-108MHz WBFM stations. and MOTOTRBO-like transmissions on 172MHz. I would like you to take a quick look at the code and check if there are no obvious errors or misconfigurations.

I am also planning to write an rtl_fm clone using liquid-dsp. I was thinking on using the msresamp_crcf object and then push the data through freqdem demodulator. Is this approach correct?

Best regards and thanks for all the excellent work !

jgaeddert commented 10 years ago

Mariusz, I scanned over your program briefly and it looks fine. I know the RTL SDR produced fixed-point (integer) samples, and I do have a branch of liquid-dsp to handle fixed-point math. That being said, I'm still in the process of porting everything over so there's still some work to be done there.

Yes, using the multi-stage resampler (msresamp) along with the analog frequency demodulator (freqdem) should produce the results you're looking for. Let me know how it works out, and if I can be of any help. -jd

mryndzionek commented 10 years ago

That being said, I'm still in the process of porting everything over so there's still some work to be done there.

So the only thing I must do is to use this branch and recompile the library ?

I have also a question regarding the out_block_size - the data chunk size pulled from the dongle. When I set this to a high value the processing becomes painfully slow. I reckon the msresamp object gets overloaded. Is this the case? If so, should theout_block_size be adjusted to selected bandwidth?

jgaeddert commented 10 years ago

Ah, I think I see what's going on. Your buffer size is 16k so depending upon your sample rate it might take a few (hundred) milliseconds to fill the buffer. Then you run the msresamp all at once before sending it to the spectrogram. You could very easily change your buffer size to be a lot smaller (1k) and it would effectively just run the spectrogram more often. I hope that makes sense

mryndzionek commented 10 years ago

Everything is clear now. Thanks for the answers. I will open another issue in case of any problems with the rtl_fm clone.