An SDR Dongle
I actually could afford a new radio! A whole $20!
I've been drooling over software defined radios for a few years. I'm glad I waited instead of spending hundreds of dollars on technology that is still in its infancy. Somebody in the Jove group mentioned these and someone else bought something similar from somebody selling on Amazon. This comes from NooElec who also sells on eBay, but anyway it was only $19.95 with an antenna and a remote.
Things are changing fast so there's a lot of misinformation out there. It took me about a week to get it working at all, and so far it's only working in Windows. I've had $20 worth of fun with it already, but I'm not sure how practical it is for daily use mostly because it ties up a computer. My newest computer is 8 years old and it's the only one I've got with USB2.
Here's a screenshot of it running through SDR# on the 2 meter ham band. I'm listening to a QSO on a local repeater (where the red cursor line is) but another repeater in the opposite direction is seriously overloading the front end. Most of the peaks you see here go away when there's a break in the conversation and it unkeys. I was about ready to contact somebody about the spectral purity of the repeater until I considered how strong it is. I can see the mountain it's on about 20 miles away and it comes in on an HT with no antenna plugged into it. I'm listening on a 2 meter Slim Jim antenna in the attic so there's some gain there too.
I'm not having any trouble with the interference being close because I can turn down the filter width. I've already seen intermod happen several times from broadcast band FM transmitters though. It could use a preselector, but the frequency coverage is 24 to 1700 MHz, so it will need to be custom designed. Also the frequency is off a little: the repeater I'm listening to is on 146.985, not 146.97 MHz. I hear they drift too, but I haven't experienced that yet.
The biggest problem I've had is with RF trash from the computer(s) since I'm running 3 computers within about 5 feet. The dongle is plugged into a 6 foot USB exension cord, which let me move it about 4 feet away from the computer and stuff it into a coffee can for some RF shielding. On somebody's suggestion, I took the antenna that came with it and cut the plug off so I could solder on a chassis mount BNC jack to connect to remote antennas. The connector going into the dongle isn't anything I can match easily. I'm using antennas in the attic.
These dongles were designed to receive TV on, which they probably still do but I haven't any idea what to use for a driver or software in general. I don't care about that: I haven't watched anything on TV in months. Above is a screenshot from SDR Sharp which doesn't drive the dongle directly. There's a little command line program called rtl_tcp which is directly driving the USB connection and sending data out a TCP/IP connection. Most of this stuff could work with the dongle in one computer and controlled from another over a network.
But of course listening to the radio on them is just another use for them, and here's another. An increasing number of aircraft transmit position information by a system called ADS-B, which is easy to receive. It's transmitted on 1090 MHz and I'm using my 2 meter Slim Jim again here to receive it. The program doing the receiving is called ADSBSharp and it transmits over a TCP/IP connection to another program called Adsbcope that actually displays and plots on the screen. If you want to download Adsbcope, it's contained in a file labeled something like "ZIP-File with all relevant data", just get the latest one listed. ADSBSharp is by the same guy who writes SDR# and it requires the same .NET framework 3.5 from Microsoft, which is a 200+ meg download. I really wish he had steered clear of Microsoft products. And the .NET frameworks aren't interchangeable: if you've got 4.0 that isn't good enough, you have to have 3.5. There's another program called RTL1090 which will also interface to the dongle and output AVR over a TCP/IP connection to drive Adsbcope. I think it's Microsoft-free.
The simple way to start rtl1090 and adsbscope is to double-click on the rtl1090 exe file (later make shortcuts), then double click on adsbscope to open it. In adsbscope, go to other -> Network -> Network Setup, click the BEAST preset button then the Close button. Then click other -> Network again and check the "RAW data client active" box. Then click the Start button in rtl1090. Rtl1090 outputs BEAST format by default, and adsbscope understands it.
It's also possible to start rtl1090 with an /AVR flag on its command line and fiddle in adsbscope until you get it seeing the AVR (text) format (not binary) from rtl1090, but somewhat less predictable in starting.
Either method has to be done each time you start the programs up since they don't store this setup.
ADSBSharp sends AVR and Rtl1090 can, but if you want to check that they're working you can telnet to the IP address and port number like "telnet 127.0.0.1 47806" or in a web browser visit http://<ip>:<port>like http://127.0.0.1:47806. You should see something like this (at 5 - 15 or more lines per second):
*25C051721BEBDD; *83019BAE5F1920860E95AC716C0C; *96124C48E436555A50E0C4549AC4; *92AE808EF680D7838E221FC22962; *2000101F33FCC6; *898C864389B9E010D3FCB88D4E4E;
If you want to listen to pilots talking to towers while you're watching this and you've got a scanner that covers aircraft frequencies (most do), see Airnav to get frequencies for airports in your area.
There's another program called Zadig which is actually a USB driver and you'll need it for either the SDR or the Adsb stuff. This is only under Windows, Zadig is actually libusb 1.0 with a Windows wrapper. You'll want the bigger (5 meg) Windows version probably. There are some instructions here.
Another organization you should be aware of is Osmocom which can be trusted since it's a non-profit organization, but they have feet in both the Unix and Windows worlds. There's also a list of compatible devices since there are so many that do almost the same thing. They all use the RTL2832U chip, but the tuner chips vary, so they work slightly differently from a software standpoint, and they cover slightly different frequency ranges. They were all made as TV tuners though so the middle part of the range is common to all.
Osmocom produced a set of low level command-line programs including rtl_tcp that feeds raw samples out over a TCP/IP connection. That's not the same thing that RTL1090 and Adbharp do. Those output the AVR protocol for tracking planes which looks like a bunch of hexadecimal. There are two degrees of this information and so far most planes in the US don't transmit enough to be tracked. Notice that there are 49 planes in the table at the right above but only 10 in the position plot at the left. I think when the tracking line turns to a dotted line it's a projected position based on the last known position, speed and heading. The osmocom package now includes rtl_adsb, I haven't experimented with it.
The left picture above is a recommended antenna for monitoring ADSB transmissions on 1090 MHz. It's a collinear, usually made of wire. The coax center lead goes to the antenna, the shield goes to the base, which can be a disc like a base or just more wires in a circle, like a ground plane. 130 mm is about 5-1/8 inches, so this is about 16 inches tall. Image stolen from Sprut. The right picture is the dongle, image stolen from the seller.
Oh, and in case you're curious, this is all moving so fast that nobody has made any efforts to block cell phone reception. But it's almost all trunked, which means that you might hear a couple seconds of a conversation then it jumps to another frequency. There's really nothing to hear anyway.
Well, that's it so far, just Windows. I'm really hoping to get this going in Gnuradio but I'm stuck on wxPython and pyqt4. Without at least one of them I'll have no GUI interface. Gnuradio is really the most flexible application, since it's a framework within which you can define your own decoding schemes. For example GPS is also within the frequency range covered. There's a lot of math involved though. I've been spending too much time playing in Windows, which is pretty much a dead end.
Gnu Radio is easily the most versatile application imaginable because it's a toolkit for building applications. Most don't really require any coding since that's all been neatly packaged. You just drag blocks onto the screen, set the properties you want, connect them together, and save. When you click Generate it creates a program written in Python that you can run within Gnu Radio Companion (an IDE) or outside it.
I've got my installation mostly working, although I'm having trouble getting sound out of it. I can see by the scope that it's making sound, but nothing's coming out of my speakers. I've started doing a tutorial, but stopped when I found nothing coming out, and added things to it to try to diagnose.
At the left side of the screen is the main area for building things. At the right, under Blocks, are the building blocks you can choose from. You expand the category you're looking for, find the block you want, then drag it into the left side where you want it. Double -click on it to set properties. Next click on an "out" tab then click on the "in" tab you want to connect to and a line appears. The tabs are color-coded by variable type, the orange ones here are floats. Many blocks can use different types, or there are conversion blocks available too if you need them.
One nice thing about all this is that you don't have to know what you're doing. There are published examples, so it's perfectly possible to download one and use it or start experimenting from there. You can download a radio. Just make a backup before you start changing it in case you break something.
This is the flow diagram in the last picture actually running. Notice that the audio_sink there is grayed out because I set it to disabled. If I enable it this doesn't run because there's a sound problem. I'm generating an audio signal as a 1 KHz cosine wave, feeding it through a throttle block so it doesn't cause overflows by going too fast, then I feed it to a scope, an FFT, a wave file, and (disabled) to the speaker (the audio_sink).
From the tree of blocks at the left side of the screen I expanded all the branches and copied out the names of all the blocks below so you can see what there is to work with. One advantage of getting as much stuff working as possible when you start is so that there's a better chance of downloaded examples having everything they need to work.
For example I've got an RTL dongle, but if the flow diagram I downloaded uses a FunCube, there's a blank spot where the FunCube would appear because I didn't install that driver. I can drop in either OsmoSDR or RTLSDR sources and connect them instead.
Most of the working low level code inside the blocks is written in C++, but clicking Generate in the Gnuradio-companion generates Python which ties them all together. You can find one set of tutorials here, written by Sharlene Katz at csun.edu. Don't ask me questions about the math involved, I don't understand any of it, yet at least. You can probably get this to work under Windows, but you'll need compilers, and almost everything for Windows costs money. For unix it's free. If you're new to unix, try Ubuntu Linux. I got frustrated with it and replaced it in a week because it keeps you away from all the nitty-gritty details. Debian's a good step up if you find yourself in that boat, but I don't really like Linux at all, I prefer OpenBSD. It's all free.
Building Gnuradio under Windows is "not officially supported", but see this wiki page if you're interested in trying. If you're using a UHD (Ettus hardware) you can get a prebuilt executable for XP, Vista, 7 at Ettus. But much of Gnuradio is done in Python, so you'll want the right version of that too. It's a mess I'd rather stay away from. It isn't one program, it's maybe hundreds of them and they all have to work together. It's hard enough under anything non-Linux. You can use a viariety of compilers, there's an effort to build it with tools that are native to Windows. I'm glad to be retired from the Windows world.
But of course building or just installing things under unix isn't easy. I like to build everything from source code, then I can study bits of the source to see how things are done. Almost nothing is a stand-alone program: almost all programs use routines in libraries that may be part of other programs. In the long run once you've got enough libraries installed it isn't so bad, so I typically install a few big messy programs like The Gimp and Firefox first, that gets a lot of it over with. If something needs a language like Python you can find yourself installing database or imaging libraries for what seems like forever and it's nothing close to what you're trying to do. Get a big hard drive, accumulate lots of stuff, and try hard to not upgrade more than every few years. When a hard drive's warranty runs out is a good time to replace it and upgrade. Put the old one on the shelf in case you need to hook it back up and copy off something you forgot. Once you haven't needed anything from it in a few years, make it part of a RAID.
There's an archive of Gnu Radio projects at CGRAN and Gnuradio itself is at gnuradio.org. gr-air-modes Does ads-B.
AB1JX / Toys