Wednesday, September 16, 2015

Mystery signal: 877.875 MHz (Solved)

While using my SDRPlay RSP, I noticed a weird signal centered on 877.5 MHz.
Here is a picture of HDSDR receiving the signal on 5 MHz bandwidth:

It is 2.55 MHz wide, and I haven't seen anything like this on It could be some sort of cell phone tower signal

(Update 1/08/2016) I asked about this on the GNURadio mailing list and they say it's either IS-95 or CDMA 2000, both old cell phone signals. They also say it's actually 2 signals beside each other.

Friday, September 11, 2015

Watching ATSC HDTV on the SDRPlay RSP

One of the main reasons I got the SDRPlay RSP was its wide bandwidth. It can show up to 8 MHz of spectrum at once. I figured it should be able to watch TV. Turns out it can, but it's only designed to receive DVB-T.

Unfortunately, they only use that in Europe and a few other places. In North America we use ATSC.

In this article I will show how to use it to watch ATSC.

(Update 11/28/2015) See ATSC now possible on magnetic drives for updated info on sample rate and bit depth.

(Update 03/02/2016) You should use 7 MHz sampling instead of 8 MHz; it reduces bandwidth and space consumption and the narrower filter may help to block adjacent blowtorch stations. Also experiment with 8-bit recording, which cuts the file size and minimum write speed in half.


ATSC is 6 MHz wide, so you have more than enough bandwidth on the SDRPlay. In theory you should be able to watch North American TV channels. Imagine my consternation when I searched online and found plenty of info on watching DVB-T, but practically nothing on ATSC!

There was one way, using a program called GNURadio, but the ATSC system wasn't well documented. In fact, information on it was almost non-existent. I proceeded to search but without much success.

I'm a Windows user, so I tried installing GNURadio on Windows, but it was a huge mess, taking hours to compile and then it wouldn't even start. I gave up and decided to use Linux.

I downloaded the GNURadio Live DVD from their website. It is an ISO file containing a bootable Linux Ubuntu installation with GNURadio pre-installed. All you have to do is pop it in and reboot, and you've got a full-featured GNURadio installation.

But that still didn't explain how to make ATSC decoding happen. GNURadio uses blocks, which are little squares containing functions. You can drag them onto your workspace and draw wires between them to make stuff happen. I just needed to know which blocks to use. I found some instructions in the GNURadio repository, but they said to use certain blocks, such as ATSC Field Sync Demux, that I couldn't find.

I subscribed to the mailing list and asked about that. Ron Economos was very helpful and responded that the block I wanted had been renamed. He also offered to help me if I wanted to make the ATSC decoder work.

I continued to communicate with him and he said I should use the pre-made flowgraph file, "file_atsc_rx.grc". This contains the entire ATSC decoder in one block. It was a great idea, since I would've had to import and configure each individual block if I hadn't used this file.

I initially recorded a RAW IQ file in HDSDR (on Windows) and tried to decode it in GNURadio. It produced an unusable TS file. Then I tried a few more times. Sometimes I would get empty output files.

Finally, Ron told me that if there was any DC in the middle, it would break the decoder. I applied DC cancellation and got a working video file on September 7.

How to do it:

I'll assume you've got your SDRPlay's driver installed already. If not, you can find instructions on the SDRPlay website.

  1. The easiest way to use GNURadio is to download the latest Live DVD from It's over 1 GB, so start the download now so it can be done by the time you're ready for it.
  2. Install HDSDR. You can find it at
  3. Install the EXTIO plugin for the SDRPlay. It can be found at Make sure to install it in the HDSDR program folder.
  4. Connect an antenna to your SDRPlay. A rooftop Yagi is best, but "rabbit ears" will also work.
  5. Connect the USB connection to your computer. Turn on HDSDR.
  6. If everything is working, you will see a bright blue button labeled EXTIO. Click it. You will get a dialog similar to this:
  7. Under IF Bandwidth, choose 8 MHz. Make sure Sample Rate is set to 8.00
  8. Enable Tuner AGC is probably turned on for you, but if not, turn it on.
  9. Now click Advanced (at the bottom.) It should look like this:
  10. You *must* change Periodic to One Shot. Then change Tracking Period to 58.6 uS. Click Apply and Exit.
  11. Click Exit on the first dialog to return to HDSDR.
  12. There are some buttons on the bottom left. Click the one labeled Options [F7]. Then click Input Channel Calibration for RX.
  13. There's a button at the top-right labeled Off. Click it to change it to Auto.
  14. Click OK.
  15. Now you need to know the frequency of the TV station you want to record. To find a TV channel, go to or I prefer Enter your zip code and it will give you a list of the TV channels in your area.
  16. In the table of channels, you will see a column labeled RF Channel. I'll pick channel 12.
  17. You need to find the desired station's RF channel and look it up at In the table, find the channel and look under the Lower Edge column. That gives you the channel's lower edge frequency in megahertz. Add 3 to get the proper tuning frequency. The result will be used in the next step.
  18. Then, in HDSDR, tune the LO frequency to the result you got in the last step.
  19. In the buttons at the bottom of HDSDR, click Start [F2].
  20. You should now have a waterfall that looks like this:
  21. The stronger the signal, the greener, then redder, it'll get. Above is a great signal. If you have blue empty areas in the channel, repeat steps 16-18 to choose a stronger one. For example, this is what it should NOT look like:
  22. Now right-click the Record button (the red circle) and you will get this dialog:
  23. Under Recording Mode, make sure RF (full input signal) is checked, and uncheck (if checked) IF and AF.
  24. Change Recording Format to RAW and Sample Type to PCM16.
  25. (Optional) Beside RF (full input signal), change WAV file split size to 4095 MB (or higher).
  26. Lastly, change Recording Directory to point to a fast disk, preferably a RAM drive. You will need about 32 MiB/sec sustained write (28 MiB/sec if using 7 MHz) to avoid dropping samples. I use SoftPerfect RAM Disk, which is free.
  27. Click OK to close the dialog.
  28. Take a recording by clicking the Record button. You may be limited by storage space to a minute or two if using a RAM drive.
  29. When you're done recording (or your RAM drive runs out of space) click the Stop button twice.
  30. If you used a RAM drive, now is the time to move the file off of it and onto your normal hard drive.
  31. (Recommended) If you used a RAM drive, you should unmount it to free up the memory
  32. Now, when your Live DVD image finishes downloading, burn it to a DVD. Alternatively, you can boot the ISO file in a virtual machine, but that goes beyond this tutorial.
  33. Unlike Windows discs, this one doesn't ask you to "Press any key to start...", so it will boot up without intervention. It will take quite a while to start. When it does, there will be an icon labeled GRC on the desktop. Double-click it and wait for it to load.
  34. Click the Open button at the top.
  35. Click File System in the left sidebar.
  36. Navigate to usr/local/src/pybombs/src/gnuradio/gr-dtv/examples and open file_atsc_rx.grc
  37. There is a block labeled sample_rate. It will be set to "6.25M". Change it to 8000000. It should now say "8M"
  38. Double-click the block at the bottom labeled File Source. In the dialog that comes, click the "..." button beside the File field. Find and select your IQ file. Then click OK.
  39. Now double-click the File Sink block and save your output video file:
  40. Now click the Play button to execute the script:
  41. You'll get a terminal window. (The errors you see in the picture are nothing to worry about)
  42. Now boot back into Windows and open your TS file in VLC Media Player. VLC Media Player will let you choose which sub-channel to view, whereas most other players won't.


If your TS file is empty (0 bytes) then (most likely) you didn't cancel the DC bar in the middle of your spectrum recording. Experiment with your settings until it goes away. If you're sure you don't have a DC spike, then check to see that the sample rate in GNUradio matches your file's sample rate (you might have set GNUradio to 8 MHz and fed it a 7 MHz file, or vice versa).

If you get "!!! atsc_fs_checker: PN63 error count = xx" errors in your terminal window, then you experienced bad reception (or interference) during the recording. Take a new recording, adjust your antenna, or choose another station.