GNU Radio for Mere Mortals
A radio used to be a box of parts soldered together. GNU Radio is that box rebuilt in software: a free toolkit that processes signals — streams of numbers standing for radio waves — by joining small programs called blocks into chains called flowgraphs. A block that makes a tone, a block that filters it, a block that pulls a voice out of it, a block that writes the result to a file: join them and you have built a receiver. Rearrange them and you have built a different one. Nothing to unsolder.
This guide teaches that craft from the numbers up. It starts with what a sample is and why samples come in pairs, states the one law (Nyquist) that ties sample rate to what you can hear, and then builds, runs and measures real flowgraphs: a tone through a filter, a decimation done wrong on purpose and then done right, a complete simple receiver working on a recording, and a block written from scratch in Python. The limits are stated plainly, including the deepest one: a flowgraph is the clever part of a radio, not the whole of it, and on its own it cannot hear a thing.
The legal line is stated early and kept throughout: receiving is broadly lawful; transmitting is licensed. This guide teaches reception and signal processing only, and its lab transmitted nothing — it worked on signals it invented itself, inside one computer, with no antenna connected.
The lab behind this guide ran the real thing: GNU Radio 3.10.9.2, installed from the system packages on a small Linux machine. Against it the lab ran a synthetic tone plain and filtered and measured both files until the numbers confessed (a peak at 1,000 Hz, the filter's startup transient caught in the act); decimated a two-tone signal the wrong way and watched the unwanted tone forge itself an address at −4,000 Hz, then the right way and watched it vanish some 63 dB down; made a recording of a planted AM station and built the receiver that centred it, filtered it and read its 700 Hz test tone back within a few parts in a thousand; wrote a Python block whose 48,000 outputs were each exactly right; and built its first flowgraph a second time as a Companion drawing, whose generated program produced byte-identical output to the hand-written code.
What the lab could not do, it did not
fake. It has no SDR hardware, so every
hardware block — the dongle that would
stand where the lab's file source
stood — is taught from the projects'
documentation and labelled as such.
The Companion's canvas was opened
under a virtual display and held the
lab's drawing, but the click-by-click
craft of editing on a canvas leaves no
transcript, so it is described rather
than demonstrated. criteria.md keeps
the full ledger of what was run and
what was only read.
What this guide covers
- What GNU Radio is — the mental model: samples in, samples out, blocks and flowgraphs, and the legal line between receiving and transmitting, stated early
- Samples and IQ — why the numbers come in pairs, the rotating arrow, and strength from a sum a reader can check with a pencil
- Sample rate and Nyquist — the one law: sample at more than twice the highest frequency, or the signal folds and lies about its name
- Installing GNU Radio — the three honest routes, and the one command that proves the install and names its version
- The Companion — the graphical editor as a code generator, proven: the lab's drawing and its hand-written twin produce byte-identical output
- Your first flowgraph — a tone, a filter, two files, and the measurements that grade the diagram
- Sources and sinks — where numbers are born and where they go to be believed, including the file formats and the throttle's two rules
- Filters — the weighted sum that keeps some frequencies and removes others, and what steepness costs in taps
- Changing the rate — decimation done wrong (a forged tone at −4,000 Hz) and done right (the filter first, then the fall)
- Reading the spectrum — the FFT's portrait of a signal: an AM carrier and its sidebands, read like evidence, with bin widths named
- A simple receiver — tune, select, demodulate: the classic chain run end to end on a recording, its planted tone recovered
- Python blocks — writing a block from scratch, and verifying all 48,000 of its outputs
- Reading other people's flowgraphs —
the
.grcfile as a book: rates first, walk the chain, interrogate the paths, trust after reading - The neighbours — gqrx, SDR++, OpenWebRX, the vendor apps, and plain Python: what each does that GNU Radio doesn't, and the reverse
- Limits — a flowgraph is not a radio, the computer bill is real, drivers are the swamp, and the legal edges, stated plainly
- Troubleshooting — the instant finish, the garbled audio, the silent hardware, the holes in the waterfall, and the traps this guide's lab fell into so you don't have to
- Glossary — the terms, collected in one place
What it doesn't cover
Transmitting — designing or building transmitters is a licensed activity with its own literature, and this guide stays on the receiving side of the line it draws in chapter 1. Any particular SDR device's deep manual: the hardware chapters teach the seam, not a catalogue. GNU Radio's C++ internals and building the toolkit from source are pointed at, not taught. And the finished receivers of chapter 14 are recommended warmly precisely because this guide does not try to replace them: it teaches the workshop, not the shop.
How to use this guide
Read chapters 1 to 3 before touching
anything: the model, the numbers, and
the law are the whole foundation, and
they are short. Chapter 6 runs in the
same sitting as the install — keep the
rhythm of predict, run, measure from
the very first flowgraph, because that
rhythm is the skill the rest of the
guide is secretly teaching. Chapter 9
is not the optional chapter: the wrong
decimation takes ten minutes and will
save you a weekend someday. Chapters
11 and 12 repay doing with your own
hands on the keyboard, changing one
number at a time. The lab's scripts
live in gnu-radio-lab/, its
transcripts in gnu-radio-lab/transcripts/;
its notes are examples/lab-notes.txt
and its distilled commands
examples/commands.txt.
Part of the series
This guide is one of the For Mere Mortals guides: plain-language guides to the tools programmers and makers use.
Related guides:
License
The writing in this guide is licensed under CC BY 4.0. Code examples and lab scripts are licensed under the MIT License.