Video Tutorial: Installing GQRX and RTL-SDR on a Raspberry Pi

Over on his YouTube channel AVT Marketing has uploaded a new beginner friendly video that shows how to easily install and use GQRX on a Raspberry Pi single board Linux computer. GQRX is a Linux based general purpose SDR receiver program which is compatible with the RTL-SDR. The Raspberry Pi 3 has enough processing power run this software easily with the RTL-SDR.

The tutorial is a 2-part series, with the first video showing how to install the software from scratch. AVT shows every necessary step including installing git, cmake, build-essential, getting and installing the drivers from the Osmocom github and installing libusb. For someone very new to Linux this tutorial is a simple step by step start. The second video goes on to show how to actually use GQRX on the Raspberry Pi.

Installing RTL-SDR on a Raspberry Pi (Linux)

Using GQRX with RTL-SDR on a Raspberry Pi (Linux)

13 comments

  1. Edward

    This is the following message that I received:
    Found 1 device(s):
    using device 0: Generic, RTL28328UHIDIR, SN: 0000000000001

    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
    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…

    Then it hangs. I have follow the above instructions and the following instructions:
    [email protected] ~ $ sudo apt-get update
    [email protected] ~ $ sudo apt-get upgrade
    [email protected] ~ $ cat <no-rtl.conf
    blacklist dvb_usb_rtl28xxu
    blacklist rtl2832
    blacklist rtl2830
    EOF
    [email protected] ~ $ sudo mv no-rtl.conf /etc/modprobe.d/

    [email protected] ~ $ sudo apt-get install git-core
    [email protected] ~ $ sudo apt-get install git
    [email protected] ~ $ sudo apt-get install cmake
    [email protected] ~ $ sudo apt-get install libusb-1.0-0-dev
    [email protected] ~ $ sudo apt-get install build-essential

    [email protected] ~ $ git clone git://git.osmocom.org/rtl-sdr.git
    [email protected] ~ $ cd rtl-sdr/
    [email protected] ~/rtl-sdr $ mkdir build
    [email protected] ~/rtl-sdr $ cd build
    [email protected] ~/rtl-sdr/build $ cmake ../ -DINSTALL_UDEV_RULES=ON
    [email protected] ~/rtl-sdr/build $ make
    [email protected] ~/rtl-sdr/build $ sudo make install
    [email protected] ~/rtl-sdr/build $ sudo ldconfig
    [email protected] ~/rtl-sdr/build $ cd ~
    [email protected] ~ $ sudo cp ./rtl-sdr/rtl-sdr.rules /etc/udev/rules.d/
    [email protected] ~ $ sudo reboot

    [email protected] ~ $ sudo apt-get install libasound-dev
    [email protected] ~ $ sudo apt-get install libpulse-dev

    [email protected] ~ $ wget http://www.aishub.net/downloads/aisdecoder-1.0.0.tar.gz
    [email protected] ~ $ tar zxvf aisdecoder-1.0.0.tar.gz
    [email protected] ~ $ cd aisdecoder-1.0.0/
    [email protected] ~/aisdecoder-1.0.0 $ mkdir build
    [email protected] ~/aisdecoder-1.0.0 $ cd build/
    [email protected] ~/aisdecoder-1.0.0/build $ cmake ../ -DCMAKE_BUILD_TYPE=Release
    [email protected] ~/aisdecoder-1.0.0/build $ make
    [email protected] ~/aisdecoder-1.0.0/build $ sudo cp aisdecoder /usr/local/bin
    [email protected] ~/aisdecoder-1.0.0/build $ cd ~

    What other statements am I missing? I am using a Raspberry Pi 3 Model V1.2

    • tim_rtd

      Edward, when you run that rtl_test and everything is fine. It will print nothing out and appear hung. You have to cntrl-c to get out. It’s working…

      • Edward

        Thanks, the rtl_test cntrl-C works. When I proceed to the next step of starting gqrx, I received an error message stating:
        “Crash Detected!”

        “Gqrx has detected problems with the current configuration. Loading the configuration again could cause the application to crash. Do you want to edit the settings?”

        In the terminal, it reads “pulseaudio/pa_sink.cc: pa_simple_new() failed: connection refused
        Could not resolve property: Pattern10600

        Is there a setting I did not set?

        Thanks

        • tim_rtd

          Next yes, go to the configure menu. Select which Rtl dongle and at the bottom of the box you can select which audio device you want to use. ” Warning” raspberrys continue to be sensitive to audio devices and selections. Your not the only user to have sound issues. On a couple of mine I had to use a USB audio device. Keep trying…..

          • Ed

            I received the following message ““Gqrx has detected problems with the current configuration. Loading the configuration again could cause the application to crash. Do you want to edit the settings?” I click on yes and I do not see a configuration menu. I am using a 7 inch touch screen from raspberry pi. How do I change the configuration setting?
            Thanks

    • CHINMAY

      Double-clicking on gqrx icon pops up a box with three options “Execute” “Execute in terminal” and “cancel”
      None of these work
      -Chinmay

  2. Jason Charney

    So many things were wrong with Part 1 … like the fact that he installed the software into /etc/apt/

    # Start at the beginning by going home.
    cd ~
    # if you don’t have a Downloads directory in your home directory, create one.
    [ ! -d “~/Downloads” ] && mkdir ~/Downloads
    cd ~/Downloads
    # Download the things rtl-sdr needs
    sudo apt install git cmake build-essential libusb-1.0-0.dev
    # Git rtl-sdr
    git clone https://git.osmocom.org/rtl-sdr
    cd rtl-sdr
    # cmake projects are compiled from source with a build directory you must create.
    mkdir build && cd build
    # Run cmake for the parent directory
    # with the -DINSTALL_UDEV-RULES=ON argument, we don’t need to mess with any of the udev stuff because a /etc/udev/rules.d/rtl-sdr.rules file was already created.
    cmake ../ -DINSTALL_UDEV_RULES=ON
    # In typical UNIX fasion, we compile from source using ./install.sh && make && sudo make install
    # but with cmake projects, subsititute that install.sh part with cmake
    # So we need to do the other two parts.
    make && sudo make install
    # For good measure, let’s do an ldconfig
    sudo ldconfig
    # Create /etc/modprobe.d/blacklist-rtl.conf without opening a text editor!
    sudo bash -c “echo ‘blacklist dvb_usb_rtl28xxu’ >/etc/modprobe.d/blacklist-rtl.conf”
    # Plug in your SDR dongle and then reboot your raspberry pi
    sudo reboot
    rtl_test -t
    # rtl_test may look like a failure, but what matters is it should find your device. If it does you should be all set.
    # Download GQRX. There is a prebuilt binary for Raspberry Pi 3.
    cd ~/Downloads
    curl -SL https://github.com/csete/gqrx/releases/download/v2.9/gqrx-2.9-linux-armv6.tar.xz | tar xJv
    # `ls gqrx-2.9-linux-armv6` if you want to see what is in the directory.
    sudo apt-get install gnuradio libvolk1-bin libusb-1.0-0 gr-iqbal qt5-default libqt5svg5 libportaudio2
    # You need to run volk_profile for the user that is going to use this program.
    volk_profile
    cd ~
    # Create the ~/bin directory so you can call your program up with gqrx instead of ./gqrx
    [ ! -d “~/bin” ] && mkdir ~/bin
    ~/bin
    ln -s ~/Downloads/gqrx-2.9-linux-armv6/gqrx
    # And your done.

    The final result should be you can open GQRX but on your 7 inch Raspberry Pi screen it is too big! Something is missing to reduce the size of the application.

    Another issue is that within a few minutes, GQRX causes your Pi’s processor to heat up (hence that red themometer icon that shows up) or could try to slurp up power (lightning bolt!)

    I wonder. Is there an ncurses alternative that can be run in the command line? There might not be a waterfall or oscilloscope, but if numerical values can be used in lieu of waveforms.

  3. jim

    [email protected]:~ $ rtl_test -t
    rtl_test: error while loading shared libraries: librtlsdr.so.0: cannot open shared object file: No such file or directory

    I have reviewed all my entries and find no mistakes…

    [email protected]:~ $ history
    1 sudo apt update
    2 sudo apt install git
    3 sudo apt install cmake
    4 sudo apt install build-essential
    5 sudo apt install libusb-1.0-0-dev
    6 sudo git clone git://git.osmocom.org/rtl-sdr.git
    7 cd rtl-sdr/
    8 sudo mkdir build
    9 cd build
    10 sudo cmake ../ -DINSTALL_UDEV_RULES=ON
    11 SUDO MAKE
    12 sudo make
    13 sudo make install
    14 #sudo ldconfig
    15 sudo cp ../rtl-sdr.rules /etc/udev/rules.d/
    16 cd
    17 cd /etc
    18 cd modprobe.d
    19 sudo touch blacklist-rtl.conf
    20 ls
    21 sudo nano blacklist-rtl.conf
    22 cat blacklist-rtl.conf
    23 sudo halt
    24 rtl_test -t

Post a comment

You may use the following HTML:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>