Working software-defined radio with a TV tuner card.

[Balint Seeber] just sent in a small yet timely project he’s been working on: a software radio source block for the Realtek RTL2832U. Now with a cheap USB TV tuner card, you can jump right into the world of software-defined radio.

[Balint]‘s code comes just a week after hackaday and other outlets posted stories about using a $20 USB TV capture dongle for software defined radio. At the time, these capture cards could only write data directly to a file. With [Balint]‘s work, anyone can use a cheap tv tuner dongle with HDSDR, Winrad, or GNU Radio. If you’ve ever thought about trying out software-defined radio, now might be the time.

Elsewhere on the Internet, a surprisingly active RTL-SDR subreddit popped up dedicated to using the Realtek RTL2832U tuner for software defined radio. There’s an awesome compatibility chart listing compatible USB dongles. The cheapest (so far, and subject to change) is the Unikoo UK001T available for $11 on eBay.

With his source block, [Balint] can listen to anything on the radio between 64-1700 MHz. The sample depth is 8 bits and the sample rate can be anything up to 3.2 MHz. You can watch [Balint] testing out his $20 GNU Radio rig after the break.

Comments

  1. Mike says:

    How much processing power does this take to stream? I’d love to see someone integrate this into MightyOhm’s radio if possible.

  2. xrayspex says:

    Not nit picking, genuinely curious: is there a reason that he pronounces GNU as gee-in-yoo rather than ga-noo? Is it a different acronym for gnu radio?

    • Graham says:

      He’s probably just pronouncing all parts of the acronym instead of saying it phonetically. Like I said Ay-Tee-Mega and not at-mega.

    • Jay says:

      A lot of nerds, including myself, are not surrounded by other nerds. It was years between first reading the acronym GNU and finally hearing someone else say it. I still hear gee-en-you in my head when I read it.

      • Mike says:

        Exactly. I still don’t really know how to say ‘gif’. And although I knew what a ‘GUI’ was, the first time I heard someone say “gooey interface” I looked at them like they were retarded.

        • Scott says:

          I remember back in about ’91 there was a big debate about that on the boards. According to the Compuserve docs (they developed the format) it if jiff -like the peanut butter. if you can find a copy of the old DOS program cshow, the docs will explain it.

      • jokkebk says:

        Also, as a geek who speaks Finnish, using the English word equivalents like “gnu” in normal speech would sound just silly, because the languages sound completely different. So even when speaking English, I tend to use the acronym versions of GNU, GUI and similar terms. And of course, I don’t even hear the “word equivalents” anywhere.

        On the plus side, I can perfectly pronounce “Linux”, just like Torvalds does it, without any extra effort (he’s also Finnish :)!

    • Hahaha :) It’s an old habit I should probably get out of!

  3. Dave says:

    If someone knows a source for one of these tuners in Canada or the USA please post it up :)

    • rasz says:

      just visit that subreddit link
      cheapest tuner so far is $10.99 with free shipping, but people are still waiting for delivery so its not 100% confirmed working (only word of a seller who claims its Realtek/E4000 combo)

      Im waiting for confirmation to order shitton of them :)

  4. Doktor Jeep says:

    This is some good stuff right here.

  5. Aud1073cH says:

    I’d love to see this as a broad band (all 64 to 1700MHz) RF spectrum analyzer. I work with wireless microphones, intercoms, etc. and a cheap analyzer would be a really cool tool.

    Only I’m more of a hardware hacker, and don’t do much code yet. …Anyone?

    • draeath says:

      Not really possible, because you need different filters for the extremes in that range (and the filters would be hardware).

      That said, you can stick this behind a receiver meant for what you want to listen to and just frequency-shift it down to the working range of the SDR gear. This same principle is used in heterodyne receivers.

      • Aud1073cH says:

        So these tuners only have a single limited bandpass filter?
        Could the entire range be scanned very quickly? Forget demodulating the signal, just continuously sweep and get a SNR for each frequency to display.

        I wouldn’t care to actually listen to each band, just to see where there is noise in the spectrum (or where there are unused bands where I can set my gear).

      • Aud1073cH says:

        I meant “broad-band” as in seeing all 64 to 1700MHz simultaneously, insteady of only one channel, e.g. TV channel 30, at a time. not frequencies above its range.
        In case I wasn’t clear (my fault)

      • malvineous says:

        @Aud1073cH: I’m no expert, but it seems this device can sample up to ~3MHz. Which if I understand correctly means you can pick a single centre frequency between 64-1700MHz and see 1.5MHz either side of it at the same time. I think the USRP has something like 100MHz bandwidth, but if you wanted to see the entire spectrum at the same time you’d need 1.7GHz bandwidth. That amount of bandwidth would generate many gigabytes of data per second, so you’d need something like Thunderbolt or 10 gigabit Ethernet to get the data into a PC for processing, and it likely wouldn’t be possible to do it in real time.

    • I CANNOT believe all your base is back, this time with a whole radio station! http://wgih.listen2myradio.com

      why won’t this meme DIE!!!?!?!!

    • ken says:

      Check out “RF Explorer” It is a pocket spectrum analyzer for $129.00 That covers 200 to 900mhz.
      In May an enhancement will be released that covers 15mhz to 2.7ghz. It is in beta testing right now. I am a beta tester and it works very well.

  6. Doktor Jeep says:

    This will be SDR’s answer to DD-WRT. Is there a way to migrate this to other tuners? How do we know?

    • rasz says:

      Normal DVB-T tuners decode on the chip and dump pure mpeg stream.

      the key enabler here is a magic/undocumented/debug mode RTL2832U has that lets you just dump sampled data thru usb.

      Basically you get 2 channel USB 3MHz ADC + 70-17000Hz tuner for $11-20.

      You could repurpose any RTL2832U tuner into 2 channel PC 3Msps oscilloscope if you wanted by just cutting 4 traces and adding analog stage – cheapest PC oscilloscope ever.

      Funcube is the same tuner(e4000) + USB Audio card. 16bit but 96KHz.

  7. asheets says:

    Waiting for the proliferation of web sites running WedSDR with these inexpensive setups…

    http://www.websdr.org

  8. not exactly dc to daylight, but close enough for less than two sawbucks.

    Need to add trunk-tracking, scanning, CTCSS, PSK31 decoding…

  9. teknick says:

    I guess I should have waited a few days before ordering a Funcube Dongle from http://www.funcubedongle.com. These look like they accomplish pretty much the same thing, but MUCH cheaper.

    • The FCD has its advantages: 16-bit resolution and no separate kernel drivers required on Windows as it appears as a sound card & HID device. Also, supported by plenty of software projects (and in GNU Radio tree now IIRC).

      Of course it only does 96 kHz, but if you’re purely after narrow-band signals, it’s great. I’m using two at the moment for dual-channel monitoring via BorIP! http://wiki.spench.net/wiki/BorIP

  10. Cyk says:

    I wonder if a Chumby One would be powerful enough to decode DAB+ using such a USB dongle.

  11. g2-efdca34af7cf17db4cb180afae714b09 says:

    That post last week, and especially this post have changed my mind on how to do a project I have planned for later this year. (I don’t have time right now). I’m thinking this might be a good reciever to cover a decent portion of a ham band simultaneously, with software picking out different FM and GMSK signals in a band. Might even be able to have it monitor both the input and output frequencies for a repeater to automatically have it tell you if you are in simplex range of another station…… Much work to do when I am done with 6.002x

  12. hampuusi says:
  13. If people have already downloaded the Windows installer and/or GNU Radio source code, please download/update to the latest versions:

    BETA #5, and
    SVN:r661/git:feaf6c8

    to enjoy performance improvements! No doubt more will be on the way, but it’s time for me to get some sleep :)

    To keep up-to-date, you can follow me @spenchdotnet

  14. Mike says:

    This looks very cool,
    but I am wondering if anyone has actually listened to anything with this? If so, what are they listening to?

    Can you decode PSK31 for example with this?

    • I’ve used it to listen to NBFM transmissions from nearby repeaters (and with test AM and FM signals from a signal generator).

      Would be great to see how it handles PSK31! I imagine it would for stronger signals. Good test for that modulation’s ability to withstand a cheap receiver…

  15. Dino says:

    Sorry for the noob question, but can you use this process to make an emitter? Take input from microphone or wave file to send on the air

  16. Greenaum says:

    Dino, no. Transmitters and receivers are very different, though they have some elements in common. You can’t make one out of the other.

    You can get radio transmitters of all different types, including a few cheap kits for broadcasting FM with a few watts. They’re usually illegal to use, and their signal output quality is pretty bad. You can spend a few dollars on that, up to thousands for proper professional transmitters.

    If you just want to send audio, there are a number of radios that use public allocated frequencies, like walkie-talkies but longer range.

  17. BETA #6 and r663/ac9a7953b6:
    * Corrected tuning bug with FC0013 (no more I2C failures)
    * Added support for Dexatek Technology dongle (1d19:1101)
    * Gain range is printed, and input out-of-range gain is clipped to range supported by tuner

    GNU Radio: http://wiki.spench.net/wiki/Gr-baz#rtl_source_c
    Windows: http://wiki.spench.net/wiki/USRP_Interfaces

  18. zacdee316 says:

    I’m not to knowledgeable about SDRs, but would something similar to this be possible with a PCI tuner? This one (http://www.hauppauge.com/site/products/data_hvr1600.html) in particular.

  19. This is a weak hack, but it’s kind of fun. “All your Christian Radio Station Belong To Us” rotfl!

  20. oh sorry forgot to post the web site… it’s a Christian music radio station and for some reason it’s playing all your base are belong to us lol it’s like aliens took over or something http://wgih.listen2myradio.com

  21. sdrlurk says:

    I just ordered one to checkout. I suspect I’ll be disappointed with the performance, compared to a simple ‘ol analog xcvr.

    My take is, the 8 bit ADC will establish a dynamic range of a mere 48dB. A decent radio should have a range of 120dB.

    Consider a strong nearby NB (5KHz) voice signal near (within the couple MHz bandwidth) of a similar weak signal. Won’t the tuner AGC attenuate the gain to push the weak signal well below the ADC range?

    This might be fixed by filtering the baseband-width of the tuner output. But at the expense of viewing an MHz of spectrum at a time.

    Even so, this hack can still make a fine, cheap specan for viewing general signals, a scope, and hacked digital video transmissions.

  22. therian says:

    this is REVOLUTIONARY. I was waiting for this to happen since I got interested in radios as kid. Finally super cheap all band receiver / spectrum analyzer for starting in ham hobby. Probably this will resume interest in RF and we will see again diy experimental circuits in popular electronic magazines

  23. therian says:

    I cant describe how exited I am, this is huge, SDR available to anyone is bigger achievement than putting man on the Moon. This hack leave no room for excuse: “analog electronics is too hard, I rather continue connecting module A to module B” This literally give you RF vision.
    This hack is payback for all patience that it took to ignore years of artsy fartsty blinking arducrap and all change BS

  24. Hackineer says:

    Get your tuners while you can. I ordered my $11 tuner off eBay from a Hong Kong seller last week. Although his Buy-It-Now auction said there were plenty in stock, I received an email from him saying I would not be receiving mine because they are out of stock. I noticed today the prices of these things on eBay have at least quadrupled.

    I also expect the various organizations who represent copyright holders will be actively trying to put a stop to this. Such cheap and available hardware could pose a threat to things like broadcast flags. I bet the next batch of chips Realtek produces will have this functionality disabled.

    • Cathy Garrett says:

      I did the same things as you, only I got NO reason given, just a refund through PayPal.

      • Cathy Garrett says:

        And now I see sellers specificly targetting this application, even going so far as to include a GNU Radio window capture, and the prices are indeed tripling and more.

    • malvineous says:

      This is Realtek we’re talking about. My money is on them spotting a new market and the next chip being a dedicated SDR with “no idea it could be used for things like that.” As usual, the recording industry won’t realise what’s happening for a while yet, so there’s still time…

      Not to mention this mode wasn’t exactly advertised, so it would be quite simple to slip it into another RF product and claim innocence when it gets “hacked”.

      • sdrlurk says:

        I doubt the market for SDR would be anything like DTV.

        It would be very nice to have specs on DTV dongles with hardware decoding.

        Part of demodulating the OFDM DTV signal is the Fourier transform, and if the dongle does it, the host PC doesn’t have to. Might make it possible to use small, wimpy notepad computers too.

  25. Doktor Jeep says:

    Now I know what do to with all those cheap tuners at Goodwill.
    :-)
    But yes, like those DD-WRT capable routers, get them while you can.

  26. Doktor Jeep says:

    Look at some of the prices of existing solutions here: http://en.wikipedia.org/wiki/List_of_software-defined_radios

    Of course the RealTek devices are going to get sucked up. This is like finding a late model Ford Mustang for 500 bucks.

    • Bill says:

      Remember that they’re radically different markets. SDRs are a few hundred or maybe a few thousand hobbyists. Cheap TV tuner dongles are a few million people who want to watch TV for cheap, and to the extent that it’s for hobbyists, it’s hobbyists who want to use their PC to watch and record TV. And most of the people making the dongles are integrating commercial chips and a few other cheap parts.

  27. Hi all,

    Thank you to all of you who have tested the code so far and provided feedback!

    I have just released completely re-written GNU Radio code with new GRC Source block, addition of FC0012 and support for all devices in compatibility table (those with E4000/FC0012/FC0013). Custom devices can easily be added in GRC block using ‘Custom USB’ parameters. The Source block now makes use of new C++ ‘librtl2832++’ OO API, which can be pulled out and used separately for easy device control!

    To make sure this device actually works properly, I successfully tested it with OP25 by having it capture an encrypted P25 signal, which was then decrypted/decoded and sent to the soundcard.

    Check it out (along with notes about new code): http://www.youtube.com/watch?v=wShOLgW2tmI

    Source code: http://wiki.spench.net/wiki/Gr-baz#rtl_source_c

    Updates to the Windows plugin will arrive very soon!

    PS: Reported rapid tuning issue may still exist (only happens for me if sample rates are not set correctly in a flowgraph), so take the tuning easy until a good fix is found :)

    • Sbfox says:

      Hi Balint,
      Superb demo, very interesting project you got there. Just started reading about FunCube, however after browsing around there are cheaper options. Thanks again for the introduction. Keep it up mate. Cheers.
      Sam

  28. Eniac says:

    Has anybody tried this with an older tv/video card…ie.. the video cards with built in tv tuner?
    I realize these older versions would only receive on the now defunct vhf/uhf tv bands. But these bands are going to be taken up by other radio services….any experience?

    Eniac

    • malvineous says:

      The problem isn’t the tuner. A lot of people seem to be assuming anything that can receive TV can be converted into an SDR, as if TV reception was the magic key enabling this. The key was actually the Realtek demodulator chip having a special SDR mode. It doesn’t matter that it’s a TV device, in theory any RF device (e.g. wi-fi, bluetooth, etc.) could do this, as long as one of the chips also has an SDR mode like the Realtek. Most of them don’t or we’d know about it already.

      The clue here was that the card supported both digital TV and FM reception, both of which use very different RF “protocols.” If you’re looking for other devices that are likely to support SDR, aim for those with wide protocol support as well. And look at new devices being released, because old devices:

      (1) already have drivers so if there is SDR support we’d know already,

      (2) older computers weren’t powerful enough to decode SDR signals so even if there was SDR support the manufacturer couldn’t make use of it in their official drivers, and

      (3) if you don’t know how to write your own SDR drivers for your old card nobody else will do it for you, because old cards can’t be bought new any more so nobody would benefit from the enormous amount of work involved.

      Sorry for the negative attitude but spending 6+ months getting poor quality SDR on an old card maybe two people still own isn’t really sensible against spending even $50 on a Realtek that will work as soon as it’s delivered. I know it’d be cool to get SDR on something you already own with a quick download but it’s just not going to happen.

      • Eniac says:

        Yes malvineous, you are right! I did a bit-o-research on those cards. There is a distinct difference between software controlled vs software defined.
        I wasn’t so concerned about the “TV” part but if these old analog cards can tune those “bands” (FM included) it can tune between them. There are a lot of radio services above, below, and in between the various VHF and UHF TV bands.

  29. Paladin says:

    I downloaded the installer found here:
    http://wiki.spench.net wiki/USRP_Interfaces#BETA_Download

    But it didn’t install EXTIO-DLL so SDHDR can’t find it. Does any body know where to get the files without using the “automatic” installer ??

  30. Imbroglio says:

    Be advised when trying to order compatible devices from overseas sources: some of them are not permitted in the US and so cannot be shipped.

  31. Deeply Shrouded says:

    What about the WinTV HVR-1800?
    Can anything be done with that?

  32. SPS Kannan says:

    Is it possible to use RTL based TV Tuner card with WebSDR?

    Is there any other software doing jobs like WebSDR?

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s