Using NooElec NESDR SMArt on a Raspberry Pi

RasPi LogoSo, you've got a Raspberry Pi (v2 or newer) and a NooElec NESDR SMArt and you would like to get them working together. By the time you have followed the steps in this post, you will be listening to your favorite FM radio station.

First let us take a moment to discuss the RasPi and radio software. The RasPi has plenty of power to run command line utilities to control the SDR dongle and play the audio, but doesn't really have the necessary computing power to run a full GUI-based SDR application. But this need not limit you to command line usage only.

I will also show you how to setup your RasPi to act as a server, feeding your app data, to a conventional PC over the network. You then run the GUI-based software on that PC. The software on your PC acts as the frontend to a radio receiver on the backend.

With this second option, you can use any frontend software you choose and get all the provided bells and whistles. Some of your options are: qgrx, CubicSDR, and SDR# (SDRSharp).

For this example I am going to use the RASPBIAN STRETCH LITE distro. (Minimal image based on Debian Stretch) which does not come with a GUI. I chose that distro because chances are (after going through this tutorial) you will probably end up using your RasPi as a server for another application on another computer. This way you won't be burdening the RasPi with the GUI. This means you will probably also access and administer your RasPi via SSH.

The first step to installing any software on just about any Linux computer is to update the operating system software and get the latest libraries.

Since we are talking about the RasPi, this is the code you need to type

sudo apt-get update
sudo apt-get upgrade

Answer Yes to any questions asking you if it should make changes. What these steps are doing is updating your computer.


(note: Everything can be done directly on the RasPi itself. SSH is only a convenience.)

Secure Shell is a means of remotely operating a computer. It allows you to run a console/terminal on one computer and have that operate on a remote computer.

For example, Once I get my RasPi booted and updated I open up the SSH port and run the SSH daemon. Then I can physically take my RasPi, detach the keyboard, mouse, and monitor and stick it somewhere out of the way. I then use my multi-monitored main workstation. I put up a tutorial or reference document on one monitor and open an SSH session to the RasPi on another monitor. I can then copy and paste from the documentation straight into the terminal.

On the minimal Raspbian distro, the SSH daemon is installed, but not yet enabled. You need to enable and then start the SSH service.

You'll need to type this

sudo systemctl enable ssh
sudo systemctl start ssh

Damn Yankees

The minimal distro of Raspbian is pre-configured for GB English. That includes a GB English keyboard layout. If you are a Yankee, like me, then you want to, um, correct, that to US English (and the US English keyboard). To set the keyboard on the RasPi to a setting other than GB English, use the following: Set the language using sudo raspi-config and then sudo reboot. Once the RasPi has rebooted, you will be using the language settings you chose. (I mention this because the next section uses the "pipe" character (|) and it is in different places on the US and GB keyboard layouts.)

With the update & upgrade completed, your RasPi is up to date and knows where to find the latest versions of the packages available for your use. The package that we are interested in is rtl-sdr.

sudo apt-get install rtl-sdr

When that package is installed, it installs some drivers that conflict with the drivers already installed on the RasPi. What is needed is to remove the original drivers so the new drivers can be utilized. You do this by "blacklisting" the old drivers, so they don't load.

echo 'blacklist dvb_usb_rtl28xxu' | sudo tee --append /etc/modprobe.d/blacklist-dvb_usb_rtl28xxu.conf

Then do a sudo reboot
With things rebooted, it is time to test the installation.


Results of a passing test.

Then play a radio station. Change the frequency to a station in your area.

rtl_fm -f 93.3e6 -M wbfm -s 200000 -r 48000 - | aplay -r 48000 -f S16_LE

Now that you have confirmed that the turner is capable of receiving radio signals, let's shut it down for now with a ctrl-c.

The command to get the turner working to receive remote direction is simple enough. The only tricky part is knowing your proper IP address.

rtl_tcp -a

If you are going to be running a Windows box, you probably should start with SDR# (SDRSharp).

If you are on Windows 10, you may need to install Microsoft Visual C++ Redistributable 2012 64-bit. This will fix things if you get an error like "The type initializer for 'PortAudioSharp.PortAudioAPI' threw an exception." when attempting to run SDRSharp.

Fire up SDR# and it will be set to use a local AirSpy dongle. Change it to RTL-SDR (tcp). Then click on the settings cog and enter the IP address of your RasPi. Then tune in to your favorite FM radio station. You should hear everything just fine.

SDR# at startup.

Setting the source.

From here you should start to experiment and join the fabulous SDR community.

Comments 7

  1. Why wouldn’t I just use it on the other computer then? Why even bother with the raspi? This tutorial should say here’s how you use a raspi with a nooelec.. step one throw raspi in trash and plug nooelec into your pc.

    1. Post

      I believe this is the way to set up a listening station when a few things are at play. For one, in my situation, I want to sit in my comfy chair with my large monitor (on my PC) when I listen, but my antenna comes into the house in another part of the house from where my office is. I then place the RasPi in the basement, where the antenna comes in, and place the SDR dongle on that RasPi. I then put the RasPi on my wired network and listen to things in my office with SDR#.

  2. I am using Nooelec smart and raspberry pi.
    When I enter rtl-test, I can see the message
    R82xx Pll not locked
    Please can you help

  3. Hi,
    just tried out your tut an it worked very fine till trying to connect via TCP.
    When connecting on WindowsPC to the static-IP Raspberry, it tells me, that the remote computer (raspberry) does not allow the connection to SDR# on Port 1234.
    Do i have to adjust my network/router or should i execute any further commands on my raspberry to make it work?

    Starting rtl_test gives me a nice fm radio station, so the NooElec itself works properly on raspberry and the raspberry can be reached by ping from my WindowsPC.

    Thanks for your tut and you help.

  4. Hi,
    I followed your instructions, but I don’t get any sound from the rtl_fm command, and no sound or visual indication of a signal from gqrx. When I run rtl_test I get the following output:

    Found 1 device(s):
    0: Realtek, RTL2838UHIDIR, SN: 00000001

    Using device 0: Generic RTL2832U OEM
    Found Rafael Micro R820T tuner
    Supported gain values (29): 0.0 0.9 1.4 2.7 3.7 7.7 8.7 12.5 14.4 15.7 16.6 19.7 20.7 22.9 25.4 28.0 29.7 32.8 33.8 36.4 37.2 38.6 40.2 42.1 43.4 43.9 44.5 48.0 49.6
    [R82XX] PLL not locked!
    Sampling at 2048000 S/s.

    Info: This tool will continuously read from the device, and report if
    samples get lost. If you observe no further output, everything is fine.

    Reading samples in async mode…
    Allocating 15 zero-copy buffers
    lost at least 52 bytes
    Do you have any idea what the problem might be?
    Thanks in advance, Paul K

  5. Post

    You can’t always trust rtl_fm in the sense that it could be an audio issue with your computer setup. But you should be getting a visual indication in gqrx. Your favorite FM radio station might not be the strongest in your area. For testing purposes you should use the strongest signal available. So, if you have only been testing against one transmitter, try testing against other stations in your area.

    If that doesn’t work, you will want to study your antenna connection to make sure that is in good condition.

    Beyond that, I suggest posting in

Leave a Reply

Your email address will not be published. Required fields are marked *