Monday, April 24, 2017

rtl-sdr direct sampling on linux

There's a nicely put together rtf-sdr receiver box available on Ebay from China for about AU$45 with the direct sampling modification for HF already done for you and separate inputs for HF and VHF+.

There are several sellers so shop around.

You can see it on the right here and the box above it. (Click to enlarge)

Internally, it's an RTL2832U.

On my recent weekend visit to Kevin, VK2KB, I helped to get it going under Windows using SDR# software and this prompted me to get mine going at home under Fedora linux.

One mistake I've made before is that some USB cables seem to come wired only for charging and don't wire up the other USB connections. I wasn't seeing the device in lsusb and when I tailed the log (which, incidentally, has changed under Fedora since I last looked, to be sudo journalctl -f), there was no chatter as the device was plugged in. Trying alternate cables fixed this.

It turns out that GQRX finds the device just fine. To switch on direct sampling from the Q input, you set it like this:


CubicSDR saw the device but couldn't receive until I blacklisted the built-in TV reception driver by creating a file /etc/modprobe.d/blacklist.conf and entering blacklist dab_usb_rtl28xxu in it. Then I rebooted.

After that, the CubicSDR device config looks like this:


And it receives 40m SSB like this:


(There's not much on at this time of day).

Update

To answer Carlo's comment below. Here's the wiring from dongle to board (marked in red).


12 comments:

Girardi said...

Dear Mr. Marks,

I have bought the same SDR but the results for
HF are very poor.

Not even the strongest medium wave stations
can be listened.

The antenna is just a random wire (2 meters).

Could you comment the details of the complete set (computer, antenna, cables) ?

Maybe my SDR has some broken part...

Yours.

Peter Marks said...

Dear Girardi,

2 meters of wire is not really enough for HF reception. It will probably be fine for FM (100Mhz) but not for 1MHz etc.

First check that you can hear local FM stations so make sure your SDR is working, then try a long wire, perhaps 10m running out the window to a near by tree or structure.

Yours.

Girardi said...

Dear Mr. Marks,

Ok, thank you!
I can listen the local FM station, so part of the circuit is fine.
I will try a longer wire.

The antenna you tested with was also a long wire or a professional
one ?

Yours.

Peter Marks said...

Dear Girardi,

The antenna I use is a long co-ax run to a dipole strung up between a tree and the house.

Yours.

Girardi said...

Dear Mr. Marks,

I made another test with a longer wire (10 meters) and now I can
receive some ham transmissions and few broadcast stations.
I am really disappointed with this sdr performance since
my very cheap shortwave radio with 30 cm telescopic antenna
is more sensitive :)

Thank you a lot for you help,

Mauricio Girardi.

ronny brenes said...

yo uso win7 por q no me funciona en linux no hay problema pero en win7 no funciona

Drummer said...

Hello Mr. Marks,

I recently bought a similar SDR unit on ebay and unfortunately it was a defective unit. The seller decided that it would too costly and a hassle to have to return it so they gave me a partial refund and said I could keep it. So, I decided to open it up and see if it might be a cold solder on the USB connector. Sure enough, there was. Now, the device is being recognized by my computer and I am able to pick up the VHF/UHF frequencies. However, I could not pick up any HF signals and noticed that the connecting to the HF antenna input made no difference. So, I looked and noticed that when I touched the area of the RTL board where the Q input was supposed to be connected to the HF antenna circuit (on your board it is where the labels C43 and L12 are), I was able to pick up local AM stations very clearly. I just want to verify where those solder points are connected to. My board has some extra holes on the antenna board and I want to verify if those solder points are really supposed to connect both boards together or if it is connecting elsewhere. I tried connecting a wire directly from the Q input to the SMA connector, but I think the extra components are loading the signal. I just get static. So, I'm trying to find out exactly where those points are suppose to connect. Thanks for you help.

- Carlo

Peter Marks said...

Hello Mr Carlo,

I have added an image to the post above showing the wiring from those two points in red.

Hope that helps.

Peter

Drummer said...

Thanks for the update. It seems that the signal can now reach up to the group of components around what looks like a transistor, but for some reason I'm just not getting anything from the SMA connector. Thought maybe it's missing some jumper on the back, but I couldn't find any connections that made a difference. Thanks anyway!

dayne waterlow said...

I just got one of these too and am having the same problem as drummer! Seems like the HF input is deaf! I did have to reflow the USB connector to get this thing recognized so I'm thinking there must be a solder problem somewhere.

Radiocose said...

Dear Mr. Marks,
I recentlly bought one of these little SDR boxes but I had to discover it didn't work on HF. After some investigation, I found that the transistor at the end of the HF branch (which is mainly in charge of generating a differential signal for the RTL2832 pins 4 and 5) did not show any voltage on the collector terminal. Then I connected it to the 3,3V output from the voltage regulator on the RTL dongle PCB and things got better. Anyway, I can't figure out where the power supply for the transistor should have come from actually. I found that it is connected to a solder point on the opposite side of the PCB (more or less directly under an electrolytic capacitor on the RTL dongle). Have you ever measured the voltage level on the transistor collector terminal? Many thanks for reading.
Daniele, Italy

paaguti said...

Hi

I stumbled across this post and it got me back to trying to get the RTLSDR device up & running.

I checked the transistor on the board and they had forgotten to hook it up to V+ . A bit of wire-wrapping wire between the regulator and the resistor did the magic. I'm currently thinking about a ferrite bead there, but am still undecided. What would be your gut feeling there?

Then I built a 9:1 balun for my long cable antenna. I'm on a 12th floor and using the central heating as my earth and well, I'm able to receive the full MW broadcast programme here in Madrid, Spain. Still 6 stations running :-) I did some preliminaries just after dawn and I was able to copy a couple of foreign broadcasters in SW and in the upper part of the MW.

Thanks for reviving the 'DX bug'

Greetings from the antipodes,
/Pedro A.