GNU Radio support for educational use

Add useful snippets of code or links to entire SDR projects.
Post Reply
jon
Posts: 433
Joined: Tue Jan 06, 2015 10:48 am

GNU Radio support for educational use

Post by jon » Wed Oct 17, 2018 8:22 am

GNU radio is ideal for people who want to create their own SDR Applications and go beyond just installing standard SDR software and hardware. All the SDRplay RSP radios are supported, including the phase coherent dual tuner “RSPduo” (Noise cancelling and other diversity applications are being written by the GNU radio community which will be applicable)

GNU Radio is a free & open-source software development toolkit that provides signal processing blocks to implement software radios. It can be used with readily-available low-cost external RF hardware to create software-defined radios, or without hardware in a simulation-like environment. It is widely used in hobbyist, academic and commercial environments to support both wireless communications research and real-world radio systems.

The GNU Radio set-up flow for SDRplay SDRs is now much simpler and is summarised here: https://www.sdrplay.com/docs/gr-sdrplay-workflow.pdf

Image
The above simplified flow is thanks to the excellent GNU radio source blocks created by Frank Werner-Krippendorf (HB9FXQ) for the SDRplay RSP family.

Image
Above: An RSP2-based FM receiver using the new SDRplay source block within GNU radio

Educators and developers may be interested in a project we did in conjunction with RS Components who sell both our SDRplay SDR receivers and the Pi-Top. We showed how easy it is to put an RSP receiver into a pi-top computer. The pi-top is (quoting from the pi-top website http://www.pi-top.com ) “a modular laptop that gives you the tools to complete amazing DIY projects and bring your inventions to life. It’s the perfect tool to help you learn to code, create awesome devices, and take your knowledge to the next level”. The objective was to create a highly portable and self-contained Raspberry Pi/Linux platform capable of exploring the radio spectrum (e.g. using Cubic SDR) and new radio architectures (e.g. using GNU Radio).

Image

Above: The Pi-Top Laptop with RSP1A board inserted, running Cubic SDR

here's a link to a video about the Pi-Top SDRplay project here: https://youtu.be/C4U1r-lF-YI

Reason: No reason

GregR
Posts: 2
Joined: Wed Oct 17, 2018 10:24 am

Re: GNU Radio support for educational use

Post by GregR » Wed Oct 17, 2018 11:30 am

This is great! I have been building and installing GNU Radio Companion and the gr-osmosdr in various ways over the past few days, and nothing worked.
I am using Ubuntu 18.04.

I'm getting signs of life on a Dell laptop. However, on my desktop (Lenovo Thinkserver), it is not working.

I have an RSP2. There is an example included with gr-sdrplay. This has several sources from the menu (no module specified) -> SDRPlay.
I am guessing that the idea here is to delete all of the sources except for the one you are using.
Initially only the RSP1 source was working. Now after some playing with it the RSP2 source is now working.

How does the RSP2 driver work in Linux? Is it a kernel module?
I can see the device being recognized by using the command lsusb.
What should I be looking for to determine if the driver is recognizing the SDRPlay device plugged into USB?

On my laptop, I can see in the GNU Radio Companion console window that that SDRPlay is recognized:
Using SDRPlay RSP2 (serial number)

I do not see this on my desktop. From the console:

Generating: '/home/sdr/top_block.py'

Executing: /usr/bin/python -u /home/sdr/top_block.py

Traceback (most recent call last):
File "/home/sdr/top_block.py", line 229, in <module>
main()
File "/home/sdr/top_block.py", line 217, in main
tb = top_block_cls()
File "/home/sdr/top_block.py", line 113, in __init__
self.sdrplay_rsp2_source_0 = sdrplay.rsp2_source(100e6, 1536, True, 40, True, True,
AttributeError: 'module' object has no attribute 'rsp2_source'

>>> Done

Any ideas? Permission problem?

73 Greg KF5N
Last edited by GregR on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason

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

Re: GNU Radio support for educational use

Post by sdrplay » Fri Oct 19, 2018 7:25 am

I'm not sure I can help on why you seem to have one system working and the other doesn't. I've used Ubuntu 16.04 and 18.04 and from a clean install, if I follow the gr-sdrplay workflow, then it all just works.

I've not come across that error message before. As long as you have the correct driver installed from our downloads page, and the device is showing up in a 'lsusb' report, then that should be all that is needed for this to work.

The example grc file that comes with the gr-sdrplay installation has all 4 source blocks instantiated. You can just disable or enable the relevant source block for the RSP that you have. Obviously when you are building your own grc files, you can just instantiate the RSP source block you need.

Looking online for answers to the error message, I came across these potential solutions...

Install swig by using 'sudo apt-get install swig'

Make sure /usr/local/lib is in /etc/ld.so.conf, if not, add it and then run 'sudo ldconfig'

Hope that helps,

Best regards,

SDRplay Support

Reason: No reason

DK7OB
Posts: 79
Joined: Thu Mar 24, 2016 7:14 am

Re: GNU Radio support for educational use

Post by DK7OB » Fri Oct 19, 2018 8:03 am

That's great news!

I am running the RSP1A with gqrx using soapysdrplay with good success but it always seemed a bit clunky to me. I'm going to play with gr-sdrplay in grc and if that's working, I try it with gqrx.

Thanks a lot!
Wolf DK7OB

Reason: No reason

GregR
Posts: 2
Joined: Wed Oct 17, 2018 10:24 am

Re: GNU Radio support for educational use

Post by GregR » Mon Oct 22, 2018 11:59 pm

I was able to make SDRPlay work on the stubborn computer. I uninstalled Gnu Radio Companion, and re-installed. It all worked perfectly after that!

I have installed Gnu Radio + SDRPlay on computer #3. This is a fresh install of Debian Stretch. I did find one dependency which is not listed:

sudo apt-get install iibboost-all-dev

The above installation fixed a problem with make. There was an error about not finding a symbol for a Boost library.
The install of Boost libraries fixed that.

I have simple AM and FM broadcast receiver flowgraphs working. Nice!

73 Greg
Last edited by GregR on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason

yangyi0506
Posts: 1
Joined: Sun Mar 03, 2019 7:27 pm

Re: GNU Radio support for educational use

Post by yangyi0506 » Sun Mar 03, 2019 9:50 pm

I'm trying to use gr-sdrplay now. After installing it as the flow diagram and run a simple grc file to receive the signal from rsp2, it says "ImportError: No module named sdrplay". I just plugged the rsp2 into my laptop and ran this file. Is there any other step I need to do? Thank you!
Last edited by yangyi0506 on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason

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

Re: GNU Radio support for educational use

Post by sdrplay » Tue Mar 05, 2019 6:52 am

Have you followed this - https://www.sdrplay.com/docs/gr-sdrplay-workflow.pdf including downloading and installing the correct API for your OS/processor?

Best regards,

SDRplay Support

Reason: No reason

Post Reply