In my spare time between projects here at Mindtribe, I am always looking for something to keep my mind busy. Recently, I have become fascinated with the idea of a software-defined radio, or SDR for short.

From a very high level, the concept behind an SDR is to use high speed digital electronics to replace functional blocks, like frequency mixing and modulation/demodulation, that traditionally require the use of high speed analog electronics. The advantage of using digital blocks is that they are easily configured through firmware/software. This approach gives the system a new level of flexibility that has traditionally not been available with a fully analog radio. However, when learning something new, it is good practice to review the background and why it is necessary.

For instance, learning to do differential equations before Laplace transforms. I thought it would be a good exercise to build a simple analog radio in order to gain some appreciation for the advantages of the SDR. There are a number of different radio architectures, but I decided on a quick single transistor FM transmitter.

Hartley Oscillator

Now, as with any radio design, you will need an oscillator to generate the carrier frequency, the simplest of these being the LC oscillator.

LC oscillators use some gain device, an NPN BJT in our case, and some resonant LC tank circuit that effectively acts as a band-pass filter. The circuit relies on positive feedback to actively amplify signal that is within the bandwidth of the tank circuit.

The circuit found below is a variation of a Hartley LC oscillator that I found in The Art of Electronics, one of my favorite electrical references. I ran the oscillator circuit through a quick SPICE simulation to ensure that it was actually going to oscillate and at approximately what frequency. The circuit demonstrated a resonant peak around 49MHz, as seen in the frequency plot below. The majority of the component values were chosen depending on what was readily available in our lab. The inductor was made with 10 loops of 22 AWG magnet wire, with a diameter of about an ⅛ of an inch. A hand-wound inductor was used to allow the user to tune the frequency of the oscillator by adjusting the coil spacing and therefore the resonant peak of the LC tank circuit. Plus, who doesn’t find the appearance of a hand-wound inductor on a board cool? So how do you tell if this is working?

Unfortunately, you can’t directly probe the collector of the BJT without changing the resonant frequency of the circuit. This is due to the internal capacitance of the probe. What you need to measure is the signal across a second coil that couples to the first, sort of like a step-down transformer.

If you take a couple of turns from the same magnet wire that was used for the inductor and hook it up to the probe as below, you can see that the oscillator is working.

Modulation

So the board is oscillating, now what?

Well to do anything useful with it, you will need to find a way to push and pull the frequency of the oscillator, or in other words frequency modulate the carrier frequency. With the current circuit this is actually fairly easy. The frequency of the oscillator can be moved by applying a small varying voltage to the base of the transistor. This varying signal could be a number of things: a signal generator, music from a computer or phone, voice from a mic, etc. Of course, using this method of modulation is prone to large amounts of noise due to stability of the center frequency, but for this demo, it will work well enough.

Closing the loop

So now you should in theory have a working FM transmitter. How do you test it?

Well you could build an FM receiver, which would almost be identical, just in reverse. However, I believe this would be an excellent opportunity to demonstrate the utility of SDR. With a $20 USB dongle from Amazon and the following tutorial, you can operate your own SDR receiver from your computer. http://spectrum.ieee.org/geek-life/hands-on/a-40-softwaredefined-radio.

With GQRX installed on your computer, you can browse the spectrum and locate your signal. It should be located around 49MHz, where the oscillator was tuned to. You should allow for some drift due to external connections to the board. For this example, the board is broadcasting a 49.5MHz carrier wave modulated at 6kHz. The image below shows the GQRX interface with the transmitted and demodulated spectrum. Congratulations, you have just built your first FM transmitter!

It is important to note that the value of this circuit is not its performance; the satisfaction comes from its simplicity. It is the fact that you can achieve FM transmission with so few components.

There are a number of things that we didn’t touch on such as filtering and impedance matching. Additionally, we’ve only scratched the surface of SDR and the GQRX utility. I would like to encourage you to play with it and find some local frequencies around your area.

I hope to be back soon with a post on some of the more interesting details of SDR architecture and functionality.