Getting raw IQ data via GNURadio

Add useful snippets of code or links to entire SDR projects.
Post Reply
js9013
Posts: 10
Joined: Wed May 22, 2019 4:34 pm

Getting raw IQ data via GNURadio

Post by js9013 » Wed Jun 12, 2019 6:44 pm

I have an RSPduo and I am trying to accomplish something that seems relatively simple - just dump the raw IQ data from the two SDRPlay RSPduo channels into two separate files. I installed the source blocks using this: https://www.sdrplay.com/gnu-radio-and-s ... onvention/

However, there is no documentation on how to proceed. I have tried connecting my duo block to two separate file sinks (since all I need is the IQ data, no demodulation or anything). However, many of the RSPduo settings are pretty esoteric and I can find no explanation for what they should be, namely - AGC? IF attenuation? LNA Attenuation Step? BiasT?

Further, connecting the duo block to a file sink is not possible for some reason. I don't have qt GUI installed, but I shouldn't need it for this simple application.

Thank you for any help!
Jon
Last edited by js9013 on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason

js9013
Posts: 10
Joined: Wed May 22, 2019 4:34 pm

Re: Getting raw IQ data via GNURadio

Post by js9013 » Thu Jun 13, 2019 11:32 am

Turns out this is a moot point by now, because GNU Radio can't find the SDRPlay modules. Is anyone familiar with how to get GNURadio to know where to find to .so api/hw files?

GNU Radio returns "No module named sdrplay". I can confirm that lsusb shows my RSPduo is connected as some device "1df7". Other than that, no idea where this "sdrplay" module is located in the .so files and am completely lost at this point.
Last edited by js9013 on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason

js9013
Posts: 10
Joined: Wed May 22, 2019 4:34 pm

Re: Getting raw IQ data via GNURadio

Post by js9013 » Fri Jun 14, 2019 8:44 pm

Update: through some finagling and updating Python and LD config paths, I was able to get the GNU Radio Python output to *mostly* run. However, now it seems that it is not recognizing the SDRPlay on USB. A quick lsusb shows something that I believe is the SDRPlay, but all it says is "1df7". and no device name or manufacturer info (e.g. Mirics).

Has anyone had this trouble with Linux recognizing the SDRPlay on USB before?
Last edited by js9013 on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason

sdrplay
Posts: 960
Joined: Wed Jan 07, 2015 7:58 am

Re: Getting raw IQ data via GNURadio

Post by sdrplay » Fri Jun 14, 2019 8:56 pm

RSP source blocks work in Gnu Radio by following this guide...

https://www.sdrplay.com/docs/gr-sdrplay-workflow.pdf

Best regards,

SDRplay Support

Reason: No reason

js9013
Posts: 10
Joined: Wed May 22, 2019 4:34 pm

Re: Getting raw IQ data via GNURadio

Post by js9013 » Mon Jun 17, 2019 12:31 pm

I've followed those instructions to the letter, and it did not prevent this issue from occurring.

First, the top_block.py generated by gnuradio wasn't working, as it was returning "No module named sdrplay". After some digging I found an import statement in sdrplay_swig.py that stated "import sdrplay_swig as sdrplay". For whatever reason, this did not seem to be running. So I modified the top_block.py from gnuradio to have "import sdrplay_swig as sdrplay" and it worked - until this:

Code: Select all

> $ python top_block.py
shm_open: No such file or directory
Failed to open SDRplay device 
Traceback (most recent call last):
  File "top_block.py", line 63, in <module>
    main()
  File "top_block.py", line 52, in main
    tb = top_block_cls()
  File "top_block.py", line 35, in __init__
    '1809069432', 'T1_50ohm')
  File "/usr/local/lib64/python2.7/site-packages/sdrplay/sdrplay_swig.py", line 1442, in make
    return _sdrplay_swig.rspduo_source_make(*args, **kwargs)
RuntimeError: Failed to open SDRplay device 
Now, from my limited knowledge, it appears the Linux system is not recognizing the SDRPlay device connected on USB. An lsusb command outputs:

Code: Select all

$ lsusb
Bus 001 Device 003: ID 0a5c:5800 Broadcom Corp. BCM5880 Secure Applications Processor
Bus 001 Device 002: ID 8087:8001 Intel Corp. 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 002 Device 006: ID 0461:4d51 Primax Electronics, Ltd 0Y357C PMX-MMOCZUL (B) [Dell Laser Mouse]
Bus 002 Device 005: ID 05e3:0608 Genesys Logic, Inc. Hub
Bus 002 Device 004: ID 04e6:5116 SCM Microsystems, Inc. SCR331-LC1 / SCR3310 SmartCard Reader
Bus 002 Device 003: ID 05e3:0608 Genesys Logic, Inc. Hub
Bus 002 Device 012: ID 1df7:3020  
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
So it appears the 1df7 entry is the RSPduo, but I have no idea how to confirm whether this is the issue or not. In case it matters, I am not using a Debian based distro (I am on CentOS), and I had some issues following the SDRPlay Linux process (namely in installing boost, but I don't see how that matters), but did finally make it through the whole workflow.

I have to say the Linux install guide is very bare bones and quite disappointing. I have had to do so much manual digging and ensuring everything is properly included that is not even remotely mentioned anywhere in the SDRPlay documentation.

Reason: No reason

Post Reply