Linux

Add useful snippets of code or links to entire SDR projects.
sdrplay
Posts: 978
Joined: Wed Jan 07, 2015 7:58 am

Linux

Post by sdrplay » Mon Jun 08, 2015 12:57 am

A thread to collate issues with Linux builds. Feel free to post code snippets or error messages. The more information provided, the easier it will be to help...

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

MikeR
Posts: 9
Joined: Sat Jun 06, 2015 7:13 pm
Location: Finland
Contact:

Re: Linux

Post by MikeR » Mon Jun 08, 2015 5:44 pm

dockerised SDRPlay deployment - discuss.

host still requires the driver.

test apps + additional downloaded apps sit in a container.

one container for all distros.

may solve the distro headace if usb sharing is possible.

It may make a neat cross distro server setup without the need to manage all the build tools over those distros.

Still thinking about this...

-M
Last edited by MikeR on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason

TonyHoyle
Posts: 13
Joined: Sun May 24, 2015 9:59 pm

Re: Linux

Post by TonyHoyle » Mon Jun 08, 2015 10:00 pm

As far as build tools go, cmake is pretty universal. autoconf if that proves to be an issue..

I looked into installing docker on the raspberry pi and it looks like a pretty involved manual process - far harder than simply giving people simple build instructions, let alone a .deb.

My general rule is if it isn't in the base install, think twice before adding it, otherwise things spiral out of control quite quickly. gnuradio for example has 500mb of dependencies (of course licensing issues mean you couldn't distribute a binary that used both gnuradio and the SDRPlay anyway, which probably makes it moot as it's a nonstarter for anything other than developers).

TBH I'm not planning to spend ages on this.. If there's another client/server format to implement I'll probably give it a go.
Last edited by TonyHoyle on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason

AH6DL
Posts: 49
Joined: Sun Jun 14, 2015 7:24 am

Working GRC receivers for SDRplay in Linux

Post by AH6DL » Mon Jun 22, 2015 1:45 am

I've got SDRplay working reasonably well with GNUradio, allowing me to create some receivers for reception of FM radio and also narrowband FM and AM transmissions.

I suggest trying this first with the gr-osmosdr installation instructions available in the Downloads section http://sdrplay.com/downloads.html . If you run into problems, see my post http://sdrplay.com/community/viewtopic. ... t=123#p484 describing some changes I made to SDRplay source code in gr-osmosdr that seemed to help.

These receivers run in GNUradio companion. I'm posting them as a starting point for those interested to play with and improve.

Wideband FM Receiver:
GRC flow graph (text) at: http://www.transmitter.com/sdrplay/sdrp ... 21.grc.txt
Image


Narrowband FM and AM receiver (full frequency range):
GRC flow graph (text) at: http://www.transmitter.com/sdrplay/sdrp ... 21.grc.txt

Image

Some tips and observations when using these receivers:
1) DC removal and IQ balance change with gain changes. Play around with the RF Gain control to find the sweet spot looking at the RF FFT displays.
2) Changing RF gain is likely to result in buffer underflows. Not sure why this is happening. It seems to be more of a problem on the WBFM receiver.
3) Changing baseband and IF gain in the gr-osmocom source block appears to have no effect on the SDRplay.
4) Yes, you may hear some "static" on the output. I haven't put any filters after the demodulator. They might help.
5) The SDRplay has excellent performance -- equal to the other SDR's I've tested here on known weak signals.
6) If you don't like the defaults or layout, it is easy to change them in the flow graph.
7) When adding or changing blocks, keep the sampling rate in mind. These receivers are based on a 2.048 Mbps sampling rate and changing that will require modifying the other blocks to end up with a 48 kHz audio sampling rate on the output. The major problem with GQRX not working appears to be the SDRplay code not sending a valid sampling rates to GQRX, as evidenced by the blank Sample Rate box.

Let me know how these work for you and please post your improvements and enhancements!

UPDATE:
-- Removed the rational resampler before the WBFM receiver and that solved several problems, including static on WBFM signals. Also added a filter on the audio output for good measure. Flow graph image (above) and link updated. Note that the WBFM PLL stereo receiver will work, but it is noisy. This is a known problem with that block. Search for Marcus Leech's comments on the WBFM PLL. He has a better way to do it. Adding his stereo demod is on the to-do list.
--- Yes, the user interface on both of these is horrible. My first goal was getting it working. As I find some time I'll dress them up. One complication is avoiding the DC carrier. Right now you have to do that manually by selecting a center frequency removed from the desired signal(s) and then using the offset tuning to tune in the station. I'm sure that can be fixed with some simple arithmetic, just need to figure out the best way to do it while still providing a "wide" spectrum view.

73...
...Doug AH6DL
Last edited by AH6DL 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: Linux

Post by sdrplay » Thu Jul 16, 2015 10:16 pm

We have pushed an update to the gr-osmosdr master repository. We are continuing to look at this but would appreciate any feedback on this update.

The master library can be found at: http://git.osmocom.org/gr-osmosdr/ or git://git.osmocom.org/gr-osmosdr/

Best regards,

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

Sasan
Posts: 124
Joined: Sat Jun 27, 2015 1:15 am
Location: Berlin

Re: Linux

Post by Sasan » Thu Jul 16, 2015 11:25 pm

Hi
Is there any difference between Linux and OSX for gr-osmosdr's SDRPlay support?
I cloned the repo and built it successfully on Mac OS X 10.10.4 and finally did "make install"
Everything went without problem.
Now when I plug my SDRPlay, open GNURadio (3.7.7.1) and try to build a simple FM receiver (using an osmocom source), grc gives this error:

Code: Select all

Using Volk machine: avx_64_mmx_orc
gr-osmosdr v0.1.4-46-gac1d8ec0 (0.1.5git) gnuradio 3.7.7
built-in source types: file fcd rtl rtl_tcp hackrf rfspace 

FATAL: No supported devices found to pick from.
What could have been wrong in my setup?
Best regards
Last edited by Sasan on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason
DF2HF, NM9A, EP2C

Sasan
Posts: 124
Joined: Sat Jun 27, 2015 1:15 am
Location: Berlin

Re: Linux

Post by Sasan » Thu Jul 16, 2015 11:53 pm

I had a mistake in my previous post. I should've enabled "ENABLE_NONFREE" when building the gr-osmosdr
Now grc shows the SDRPlay and inits it, but still I've got errors.
1-
I can't listen to the local FM station (I just hear a hiss. It might be my file's error. It's a sample from HackRF.
Address of file: http://greatscottgadgets.com/sdr/grc/lesson1.grc)

2- When I stop my flowgraph and start it again, some errors are generated. I've uploaded them here:
http://pastebin.com/JNiLsbmg
The most important section must be this:

Code: Select all

mir_sdr_SetGr: GR->60[36,24,0,0] gRset->0x224 DCCALmode=4 DCCALspd=1 GrToggle->1
libusb: warning [darwin_transfer_status] transfer error: unknown error (0xe000400e) (value = 0xe000400e)
Warning: DriverCallback() ISOCH transfer did not complete status = 1
I have to unplug and plug it again to be able to execute the flowgraph correctly.

Best regards
Last edited by Sasan on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason
DF2HF, NM9A, EP2C

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

Re: Linux

Post by sdrplay » Mon Jul 27, 2015 9:22 pm

The gr-osmosdr library has been updated. So worth trying again.

I have an easier method to build the 3rd party applications...

1. Install API as before
2. Install Gnu Radio using just...

wget http://www.sbrac.org/files/build-gnuradio && chmod a+x ./build-gnuradio && ./build-gnuradio

3. Then perform the gr-osmosdr build on top of Gnu Radio
4. Perform the GQRX build as before.

Hope that makes things a bit easier.

Feedback welcome.

Best regards,

SDRplay Support
Last edited by sdrplay on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason

Sasan
Posts: 124
Joined: Sat Jun 27, 2015 1:15 am
Location: Berlin

Re: Linux

Post by Sasan » Tue Jul 28, 2015 8:30 am

What does it have to do with SDRPlay?
The only changes that I can see are related to bladeRF
Did I miss anything?
Last edited by Sasan on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason
DF2HF, NM9A, EP2C

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

Re: Linux

Post by sdrplay » Tue Jul 28, 2015 9:39 am

Before that, 12 days ago - bug fixes

It's still a work in progress though.

Best regards,

SDRplay Support
Last edited by sdrplay on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason

Post Reply