GNURadio and USRP2

Aus DL8RDS Wiki
Wechseln zu: Navigation, Suche

This project is a major masterproject which heads several smaller projects. It is my first occupation with Software Defined Radio and I am getting into this intersting field step by step.

I was literally shaken by the following video where this guy demonstrates that a software defined transceiver is able to act as a GSM base station. This made me understand that we're currently leaving the age where transceivers were built and we're entering the age where transceivers will be written in code. We're currently experiencing nothing less but the rise of a new technological basis for all types of wireless communication. Everything will change.

The USRP platform is being used by research departments worldwide, so I decided that it was a good investment that allows me to keep up with the developments that are currently being made.


Inhaltsverzeichnis

Scope: Get to know the USRP2 and get it running

  • 2010-10-20 Today my USRP2 arrived. Brought to me by FedEx. Got to pay VAT but well, that's fine.

Usrp2.jpg Usrp2-open-noboards.jpg Usrp2-open-lfrx.jpg

I decided to insert the LFRX receiver board first and only in order not to break the TX board for a undecent SWR. After a while I discovered that the tool

find_usrps

will identify the USRP2 when connected directly to the GBit port of my desktop computer. Well, it does. Obviously the USRP does react on network access. Now, the only thing it needs to do is to run. Therefore I tried out the tool

usrp2_fft.py

and it gave me a wonderful spectrum scope of short wave frequencies.

Projects

Receive the first signal

  • 2010-10-20 The same tool as above was well suitable as a proof that my USRP2 was actually working. So I decided to tune my Kenwood TS-450S to a frequency in the 14 MHz band and keep transmitting with FM in order to generate a signal. Well, that was the result!

Usrp2-fft.jpg

  • 2010-10-21 Today I understood that I am missing two things to operate the WBX transceiver module: One coax cable for the TRX and the necessary firmware to drive it. Will need to get it from somewhere...
  • 2010-10-22 I tried out a ssb receiver program. Worked mostly fine. The only downside is that it responded with a very strong delay. I still don't understand why.

Transmit the first signal

This experiment works exactly the other way round: I use the USRP2 as a transmitter and see if I can detect it with my Kenwood TS-450S shortwave receiver.

  • 2010-11-04 Great. I can transmit. But I see that my dummy load is really closed. I didn't get any signal out.

Here are the parameters:

  • Sample rate 200k
  • Signal source at 1 KHz, amplitude at a minimum of 0.001 - to make sure that a bad SWR does no harm. BTW, this is a good counter check that you can really influence the output power!
  • USRP2 sink: interpolation 500, frequency 14 MHz

Result: I hear a clear signal at 14.000 MHz, +/- 1 kHz

Status: confirmed, works!

Transmit a AM signal

Amplitude Modulation is the simplemost signal that you can generate. Here it comes:

GnuRadio USRP2 AM TRX.jpg

Please note that the incoming signal has a sampling rate of 44.1 kHz which equals 44100 bit per second or 44100 samples. In order to upconvert it to the 100 megasamples which are required by the FPGA, we will multiply it with a fractional figure, which we here need to indicate in reverse: 1:220507. This is factor 4.535 and gives us exactly 200000 samples per second. And these 200k samples will be interpolated by factor 500 in the USRP2 which makes 100 Megasamples.

Media:USRP2_AM_TX.grc

Status: confirmed, works!

Receive an AM singnal

Here's my AM receiver. I constructed it with the help of these fantastic tutorials from Professor Sharlene Katz, WB6FFE, from California State University:

That's really fantastic intraductory literature! And here it comes:

GnuRadio USRP2 AM RX.jpg

Note that we're using the USRP2 as a signal source, tuned to 7.100 kHz in the center of the 40m band. When I transmit a short signal, it will appear in the FFT displays and it will be audible in the speaker. There's a small delay, but that is not so serious. I want to demonstrate how it works in general. The decimation of 512 will downconvert the 100 Megasamples to 195312 samples / second.

The 256k cosine signal source multiplied upon the incoming signal will act as a VFO. Yes, my friends, that's it. This is a VFO.

After the application of the VFO shift, the signal will be downsampled by the factor of 4 to 48828 samples. Basically it is already slow enough to make it audible. In any case it is more or less slow enough to feed into a FFT. But it might make sense to apply a throttle before the FFT, because for some computers 48 kilosamples per second is still rather fast.

In order to level the volume to a reasonable degree, we here apply a ACG (Automatic Gain Control).

The demodulation will in fact be done by the Complex to Mag converter.

In order to adjust the volume, we multiply 0.5 received from a variable slider and then we do the last little resampling to feed the signal into the audio sink.

Status: confirmed, works!

Receive a Narrowband FM signal

We're getting more complex. The below given flowgraph comes from Alexandru Csete OZ9AEC:

GnuRadio USRP2 FM narrowbandRX.jpg

Status: confirmed, works!

Receive a Narrowband FM signal (2)

The following example implements a complex narrowband FM receiver from Alex Csete, with the modification that it works with the USRP2:

USRP2 FM narrowbandRX Csete2.jpg

I modified the original flowgraph so that it works with the USRP2 but I also changed it to work on the 70cm band.

Status: confirmed, works!

Receive a Wideband FM signal

Michel Barbeau provides a good FM radio receiver code on his website:

I have modified it so that it works for my scenario here in Munich with Radio Energy 93.3 and my sound card with a sampling rate of 44.1 Kilosamples/Second

Status: confirmed, works!

Update the SD card so that the USRP2 and the WBX board work together

In order to make the USRP2 work with the WBX board, I needed to update the firmware on the SD card.

Here is how I did it.

u2_flash_tool.py --dev=/dev/XXXX -t s/w Download/firmware-txrx.bin -w
u2_flash_tool.py --dev=/dev/XXXX -t fpga Download/u2_rev3.bin -w
  • That's it.

I did this in the SD card that came with the USRP2 from Ettus.

LSB transmitter using complex band pass filter

The below given transmitter scheme originates from Alexandru Csete OZ9AEC but contains my modification so that it works with the USRP2:

USRP2 LSB TX Complex Bandpass.jpg

Status: confirmed, works

Transmit a simple FM signal

The below example will be highly illegal in Germany, but I have not tried it out. The below flowgraph is taken from here:

GnuRadio USRP2 FM TRX.jpg

Status: confirmed, works. verified in the 70cm Amateur radio band.

Transmit a Narrowband FM signal

I tried this myself in the 70cm band:

GnuRadio USRP2 NBFM TRX.jpg

The first multiply block regulates the AF sensitivity and the second block regulates the transmit power.

Status: confirmed, works

Transmit a complex (stereo) FM signal

Since the below given flowgraph will also be rather illegal in Germany, I will just document it and not comment on it :-)

GnuRadio USRP2 FM stereo TX.jpg

Transmit a SSB signal

SSB signals are really rather complex. We need to eliminate one carrier and one sideband. Here is how it works:

GnuRadio USRP2 SSB TX.jpg

Status: unconfirmed, but looks good

Receive a SSB signal

The below example comes from here:

It has not yet been tested but has been adapted to the requirements of the USRP2:

GnuRadio USRP2 SSB RX.jpg

Transmit a D-ATV signal

I haven't tried this yet but here's a report in a British forum that reports that soneone has generated a D-ATV signal with the USRP:

Transmit a Digital Video Stream


Links

Movies

  • more to come

Communication

Meine Werkzeuge