Menü Bezárás

SDRLab: an RTL-SDR interface to LabVIEW for educational purposes

The RTL-SDR project aims to use cheap USB DVB-T receviers as Software Defined Radio receivers. I’ve recently made some SubVIs for LabVIEW that grab I/Q samples from these devices, and I’ve also implemented a demodulator for FM broadcasts.

It’s important to note that the corresponding National Instruments USRP hardware have much better performance and also able to transmit as well, so actually USRP is suitable for industrial purposes, while RTL-SDR might only be recommended for students and hobbyists. There’s a table below that shows a comparison between some parameters of the two systems. (However, these are also dependent on hardware configuration, e. g. for RTL-SDR dongles the tuner chip on the panel.)

NI USRP-2922RTL-SDR
Frequency range400 Mhz – 4.4 GHz50 MHz – 1800 MHz
Bandwidthmax. 40 MHzmax. 2 MHz
Bit depthmax. 16 bit8 bit
2×2 MIMO availableyesno
Transmit capabilityyesno

RTL-SDR devices also suffer from image rejection problems, „birdies” showing up in the spectrum, and intermodulation products. Anyway, they have quite a good sensitivity, and can be used to receive amateur radio operators, PMR walkie-talkies, FM radio and also TV audio. There have even been successful experiments to decode raw GSM packets and GPS signals with these devices.

Nevertheless, our project might help some people to start out with SDR and signal processing, particularly other students, who can’t afford costly hardware, but can buy a DVB-T tuner for ~15 USD, and might start to experiment with LabVIEW using real-world signals. Similarly LabVIEW supports cheap devices like Arduino with a free add-on. Considering the limitations of RTL-SDR, the software we release is useful mainly for educational purposes.

There’s a list of compatible hardware devices over here. You can also search for RTL-SDR or RTL2832U on eBay.

Requirements

  • An RTL-SDR compatible DVB-T dongle,
  • RTL-SDR windows binaries downloaded,
  • driver already set up (easiest way is to follow this tutorial and install the driver along with SDR#),
  • National Instruments LabVIEW 2011.

How to run

  • Unpack the supplied project and open sdrlab.lvproj.
  • Copy START_RTL_TCP.bat to the directory where rtl_tcp is located, and run it.
  • Now you can run the toplevel.vi that is supplied with the project, you can leave address and port settings as is and press Play.

Notes

  • In this version, after changing parameters like frequency and gain, you’ll have to wait about 10 seconds to hear the changes taking effect. It might help if you find the frequency of a strong FM broadcast station in SDR# before trying this program.
  • The project will run as well on Student Edition, without the Modulation Toolkit. (If LabVIEW complains about it, run sdrlab_no_mt.lvproj.) It may also run on the Linux version of LabVIEW, but you have to use the corresponding rtl_tcp version.
  • Anyway, if you want to use Modulation Toolkit for processing the I/Q samples grabbed from RTL-SDR, there’s a modulation_toolkit_example.vi included, which basically does something similar to toplevel.vi. (However, the support for this toolkit is only partially tested for now.)
  • rtl_tcp is quite bogous at the moment, many times it rather fails and exits than accepting the TCP connection, especially when you try to connect the second time. If it happens, pressing (or pressing and holding) Ctrl+C in the terminal window might help to restart it.

The project is available for download and use under the BSD licence:

I would like to say thanks to Ferenc Ender for his great course on LabVIEW I’ve taken at the university last year (and this software also started out as homework for this course). Also thanks to Alipio Fernandez for testing and feedback.

— András Retzler, HA7ILM

Vélemény, hozzászólás?