Gnuradio Document

download Gnuradio Document

of 3

Transcript of Gnuradio Document

  • 8/12/2019 Gnuradio Document

    1/3

    GNU Radio

    Manu T S - [email protected]

    January 16, 2014

    Disclaimer

    This document is in no way a comprehensive guide on how to use GNU Radio. The author gives noguarantee on the authenticity of the contents. Contents are largely blatant copies of web-pages on GNURadio. Please report errors, technical or otherwise, to [email protected].

    1 Introduction

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

    2 Getting Started

    If youve never touched GNU Radio before, this document will get you started with a running installationof GNU Radio and will show you how to take your rst steps with this software radio tool.

    2.1 Software Radio / Software Dened RadioThe terms software radio and software dened radio mean the same in this document. We use bothterms interchangeably. software radio is a radio system which performs the required signal processingin software instead of using dedicated integrated circuits in hardware. The benet is that since softwarecan be easily replaced in the radio system, the same hardware can be used to create many kinds of radiosfor many different transmission standards; thus, one software radio can used for a variety of applications!

    2.2 Where does GNU Radio come inGNU Radio provides blocks that performs all the signal processing. One can use it to write applicationsto receive data out of digital streams or to push data into digital streams, which is then transmitted using

    hardware. GNU Radio has lters, channel codes, synchronization elements, equalizers, demodulators,vocoders, decoders, and many other elements (in the GNU Radio jargon, we call these elements blocks)which are typically found in radio systems. More importantly, it includes a method of connecting theseblocks and then manages how data is passed from one block to another. Extending GNU Radio is alsoquite easy; if you nd a specic block that is missing, you can quickly create and add it.

    Since GNU Radio is software, it can only handle digital data. Usually, complex baseband samplesare the input data type for receivers and the output data type for transmitters. Analog hardware is thenused to shift the signal to the desired center frequency. That requirement aside, any data type can bepassed from one block to another - be it bits, bytes, vectors, bursts or more complex data types.

    GNU Radio applications are primarily written using the Python programming language, while thesupplied, performance-critical signal processing blocks are implemented in C++ using processor oatingpoint extensions, where available. Thus, the developer is able to implement real-time, high-throughputradio systems in a simple-to-use, rapid-application-development environment.

    1

  • 8/12/2019 Gnuradio Document

    2/3

    2.3 Installing GNU RadioWith the proxy-less Internet access and scripts to automate the installation, installing GNU Radio hasbecome a childs play. In the past that was not the case. That said, there are some technicalities thatwe should be careful about.

    2.3.0 Running GNU Radio from LiveDVDDownload the DVD from http://gnuradio.org/redmine/projects/gnuradio/wiki/GNURadioLiveDVD .Burn it onto a DVD/pendrive and boot from it. This allows you to run GNU Radio without installingit. We will have a copy of the image, and you can take it from us if needed.

    2.3.1 Installing GNU Radio on Windows

    There are two options.

    Install the precompiled binaries from Ettus Research. Refer http://gnuradio.org/redmine/projects/gnuradio/wiki/BinaryPackages#Binaries-from-Ettus-Research-Linux-Windows

    Build GNU Radio from source.- Help yourself :)

    2.3.2 Installing GNU Radio on Linux

    There are many options.

    Install precompiled binaries that come with the distribution. For example in an Ubuntu system sudo apt-get install gnuradio should do it. If you are using Fedora/CentOS sudo yum installgnuradio should work. If your package manager does not nd those binaries, you can install fromsource. By installing binaries, you are likely to end up with an older version of GNU Radio.

    Install from source using build-gnuradio script. This is known to work for Ubuntu, redhat, fedora,Debian, mint and OpenSuse. This scripts automates all the things that one would do if s/he wereto install GNU Radio from source. Make sure you are connected to Internet. Make sure you have

    logged in at internet.iitb.ac.in. Update your package-list before you proceed. For example inUbuntu runsudo apt-get update

    Open a terminal and run the following command.wget http://www.sbrac.org/les/build-gnuradio && chmod a+x ./build-gnuradio && ./build-gnuradio

    This takes about 2-4 hours. Stay patient and see if it works. If it works, then you should have aworking installation of GNU Radio.It is possible that wget command does not work. In that case, open the page http://www.sbrac.org/files/build-gnuradio , and save the page to your computer. Then, open a terminal, cd tothe directory in which you saved the page and run the following command.chmod a+x ./build-gnuradio && ./build-gnuradio

    The last time (Jan 10, 2014) I tried it on Ubuntu 12.04 LTS 64 bit, this thing did not work in onego, because one of the dependency (git-core) was failing. These are the steps that I followed.

    mkdir /home/user/build Saved the page http://www.sbrac.org/les/build-gnuradio in /home/user/build directory cd /home/user/build sudo apt-get update sudo apt-get install git git-core chmod a+x build-gnuradio ./build-gnuradio

    gnuradio-companion (if the window pops up, you are done)

    2

    http://gnuradio.org/redmine/projects/gnuradio/wiki/GNURadioLiveDVDhttp://gnuradio.org/redmine/projects/gnuradio/wiki/BinaryPackages#Binaries-from-Ettus-Research-Linux-Windowshttp://gnuradio.org/redmine/projects/gnuradio/wiki/BinaryPackages#Binaries-from-Ettus-Research-Linux-Windowshttp://www.sbrac.org/files/build-gnuradiohttp://www.sbrac.org/files/build-gnuradiohttp://www.sbrac.org/files/build-gnuradiohttp://www.sbrac.org/files/build-gnuradiohttp://gnuradio.org/redmine/projects/gnuradio/wiki/BinaryPackages#Binaries-from-Ettus-Research-Linux-Windowshttp://gnuradio.org/redmine/projects/gnuradio/wiki/BinaryPackages#Binaries-from-Ettus-Research-Linux-Windowshttp://gnuradio.org/redmine/projects/gnuradio/wiki/GNURadioLiveDVD
  • 8/12/2019 Gnuradio Document

    3/3

    Install using PyBOMBS. This is now the official tool for installation. This installs GNU Radio toa local directory (a directory within your home directory or any directory with write permission isgood enough.) With this you will have to export environment variables(PKG_CONFIG_PATH,PYTHONPATH, LD_LIBRARY_PATH) on each terminal you want to run GNU Radio. Dontworry, it is quite easy. Follow the steps given below.We are going to download the source to /home/user/build and install GNU Radio in /home/user/install.By build directory we mean /home/user/build and by install prex we mean /home/user/install.You have to replace user with your username.

    sudo apt-get update (or whichever suits you) sudo apt-get install git (or whichever suits you) mkdir /home/user/build mkdir /home/user/install cd /home/user/build git clone https://github.com/pybombs/pybombs.git cd pybombs

    ./pybombs cong (When asked for install prex enter /home/user/install. You are free tochange other options if you know what you are doing. Else just press Enter for all otheroptions.)

    ./pybombs install gnuradio (and hope it works.) ./pybombs env cd /home/user/install source setup_env.sh ./bin/gnuradio_companion (if the window pops up, you are done)

    Remember, with the above installation you have to run source /home/user/install/setup_env.shevery time you want to run GNU Radio application. This command sets the environment variables

    for you. Do it all by yourself. The above two bullets showed how we can make things easy. You are free to

    do it all by yourself. Download the source, install prerequisites, compile and install. :)

    3 Now What?

    We hope to ll in this section with some basic examples very soon. For now, play around with GNU Radio.Visit http://gnuradio.org/redmine/projects/gnuradio/wiki to know more about GNU Radio.

    4 Need Help?

    Feel free to email me for any help. During day I would be available in GL-502(opposite to VLSI Lab),GG Building. In case you need any help, just walk in. GNU Radio has a very helpful community. Forany help you can put a mail to [email protected] mailing list.

    3

    https://github.com/pybombs/pybombs.githttp://gnuradio.org/redmine/projects/gnuradio/wikihttp://gnuradio.org/redmine/projects/gnuradio/wikihttps://github.com/pybombs/pybombs.git