Course 1 – Introduction to SDR

Summary

Much of how radios work can be illustrated using ideas you already understand. In our introductory course, we build on those intuitions and show how they will apply to your SDR work. At the same time, we teach you how to use gnuradio and to build your first radio flowgraphs.

Course Result

You’ll be able to use gnuradio to build basic AM and FM radios using SDR hardware. You’ll also understand how to build filters, gain stages, modulators, demodulators and more.

Prerequisites

No previous engineering or SDR knowledge is necessary – we start from the beginning.

You will not need to bring anything to the class. You will use our laptops and SDR hardware.

Description

My brother and I co-authored the Field Expedient SDR book series and have taught SDR to students who possessed widely varying degrees of proficiency. Based on these experiences, we believe that it takes four days of training for a newcomer to become proficient building analog and digital radios with gnuradio and SDR.

This course comprises the first half of that four days, and is for those who have no prior experience with SDR or have gotten stuck trying to learn via online tutorials. Combined with our second course, this solid foundation better enables InfoSec professionals to put SDRs to work detecting, intercepting and analyzing wireless vulnerabilities. This foundation is also useful for building digital transmitters to exploit RF vulnerabilities or to exfiltrate data.

As with our book series, this class avoids highly mathematical engineering lectures and focuses on teaching through 25 practical, hands-on exercises. Though we avoid the heavy math, we will carefully and methodically study digital radio design so that you can build your own gnuradio flowgraphs with confidence when needed.

We start off the class with a 10,000 foot view of radios, signals, tuning and modulation – just enough to get a basic idea. We then move to Analog to Digital Conversion and its reverse, Digital to Analog Conversion. We don’t cover these these topics exhaustively, but rather focus on their importance to the SDR world.

Armed with these basic concepts, we next dive into how gnuradio works: flowgraphs, sources, sinks, blocks, etc. We build a few simple flowgraphs to see these elements in action.

Next, we build an AM radio receiver, using a data file as input rather than SDR hardware. Most of this radio doesn’t make sense yet, but the process of building it further hones our gnuradio abilities. As we progress in this class, we can also refer back to this radio to illustrate key concepts.

We then spend a while talking about the Frequency Domain, FFTs, filters, gain and decibels. Because filters are an incredibly important tool, we work through several different projects to solidify our expertise.

Then we turn our attention to tuning, another concept that applies to nearly every radio you can build. In a series of exercises, we work through frequency shifting and channel filtering. Next, we learn about amplitude modulation in more detail, followed by sampling rate changes such as decimation and interpolation.

After fully delving into all the details of our AM receiver, we convert it to an FM receiver, noting the similarities and differences. We also clean up our flowgraph, employing a number of gnuradio best-practices. Finally, we get rid of the input data files we’ve been using and operate our flowgraph using real SDR hardware.

We next spend some time going over essential radio and SDR terminology: spectrum, propagation, frequency bands and baseband. We also work through projects showing how each of the three basic modulation types work: amplitude, frequency and phase. We also spend a fair amount of time talking about noise, including the computation of signal-to-noise ratio and how to mitigate noise in real-world systems.

There are a number of issues to consider when using SDR hardware to transmit and receive signals, and we learn about antenna selection, SDR hardware specs, SDR hardware configuration, the DC spike and more. Finally, we’re ready to transmit and receive a number of analog signals at very low power as a capstone to everything we’ve learned.

Thanks to gnuradio’s excellent simulation capabilities, we’ll work through a number of our projects without plugging in any SDR hardware. This will result in cleaner and more deterministic exercises, but we won’t stop there. We’ll also build and operate the key designs in hardware to build experience working through the kinks that invariably occur in real-world projects. To keep things entertaining, a few of our projects will be competitive, Capture the Flag-style exercises.

When you’ve finished the class, you’ll understand a host of key radio concepts, such as the sample rates, the frequency domain, filters, modulation, bandwidth, propagation, decimation, interpolation and much more. You’ll also be proficient in using SDR hardware, knowing how to configure the SDR as well as they type of antenna to use. Armed with this knowledge you’ll not only be able to build analog receivers and transmitters, you’ll know how they work. Finally, your new SDR foundation will prepare you for understanding and implementing the myriad of SDR resources you find online.

Outline

Day 1
  1. Discuss class goals and methods
  2. Goals for Day 1
  3. Why SDR Matters
  4. Simple Radio Model
  5. Defining Signals
  6. Channels and Tuning
  7. Modulation Basics
  8. Slightly Less Simple Radio Model
  9. Analog to Digital Conversion
  10. ADC/DAC Parameters
  11. Sample Rates
  12. Minimum Sample Rates and Consequences of Violation
  13. Project 1 – Simple Number Generator
  14. Project 2 – Simple Arithmetic Flowgraph
  15. Revisit Goal of using gnuradio to demonstrate radio theory
  16. Project 3 – Build AM Receiver as Alien Technology
  17. Review components of AM Radio from 10,000 ft
  18. Break for Lunch
  19. Recap Morning Material
  20. Frequency – What is it?
  21. Sound and Your Pre-existing Intuitions
  22. Audio Spectrum
  23. Project 4 – Tone Generator
  24. Frequency Domain
  25. Project 5 – C Major Chord
  26. Gain
  27. Project 6 – Programmable Gain
  28. Decibels
  29. Filter Theory
  30. LPF Example
  31. Filter Transition Width
  32. Project 7 – C Major Chord Filtering (LPF, HPF, BPF, BRF)
  33. Project 8 (Capture the Flag) – Filter Race (Extract Voice from Noise)
  34. Review AM Radio Receiver – Block by Block
  35. File Source
  36. Record and Playback
  37. Tuning
  38. Project 9 – Shifting via Complex Multiplication
  39. Project 10 – Tuner (shift and channel filter)
  40. Demodulation
  41. Complex Numbers (very light coverage at this point)
  42. AM Demod Block – Audio Filter
  43. Resampling Theory
  44. Project 11 – Decimation
  45. Additional Challenges with Interpolation
  46. Project 12 – Interpolation
  47. Project 13 – Fractional Resampling
  48. Sampling Rates and Flowgraph Performance
  49. Project 14 (CTF) – Find and Demodulate AM Radio Message Hidden at multiple locations in RF Haystack
Day 2
  1. Goals for Day 2
  2. Project 15 – Convert AM Radio to FM
  3. Project 16 – Optimize Flowgraph with Parameterization and Freq Xlating FIR Filter
  4. Project 17 – Convert Flowgraph to use SDR HW
  5. Terminology
  6. Spectrum
  7. RF Propagation
  8. Frequency Bands
  9. Baseband Definition
  10. Bandwidth versus Channel Width
  11. Modulation – Deeper Dive
  12. Project 18 – Frequency Modulation
  13. Project 19 – Phase Modulation
  14. Project 20 – Using Waterfall Plots
  15. Noise
  16. Signal to Noise Ratio
  17. Project 21 – SNR Measurements
  18. Break for Lunch
  19. Goals for Afternoon
  20. SDR Hardware
  21. Key SDR Specs
  22. Configuring the SDR
  23. Project 22 – SDR Receive Gain
  24. The DC Spike and What to Do About It
  25. Antenna Types
  26. Antenna Characteristics
  27. Antenna Orientation
  28. How Your Computer Affects SDR Work
  29. Noise Mitigation
  30. Transmission
  31. Project 23 – Simple Analog Transmitter/Receiver (IQ File-based)
  32. IQ File Naming Conventions
  33. Project 24 – Hardware-based, Low Power Analog Transmitter
  34. Project 25 (CTF) – Locate and demodulate analog mystery transmissions
  35. Quick Look Ahead at Digital
  36. Class Wrap-Up
  37. Suggested Next Steps for Students