GNURadio and USRP2: Unterschied zwischen den Versionen

Aus DL8RDS Wiki
Wechseln zu: Navigation, Suche
(Transmit a Narrowband FM signal)
 
(21 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt)
Zeile 48: Zeile 48:
  
 
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.
 
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!
 
Status: confirmed, works!
Zeile 62: Zeile 64:
  
 
[[Image:GnuRadio_USRP2_AM_RX.jpg|400px]]
 
[[Image:GnuRadio_USRP2_AM_RX.jpg|400px]]
 +
 +
* [[Media:USRP2_AM_RX.grc]]
  
 
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.  
 
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.  
Zeile 83: Zeile 87:
  
 
[[Image:GnuRadio_USRP2_FM_narrowbandRX.jpg|400px]]
 
[[Image:GnuRadio_USRP2_FM_narrowbandRX.jpg|400px]]
 +
 +
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:
 +
 +
[[Image:USRP2_FM_narrowbandRX_Csete2.jpg|400px]]
 +
 +
I modified the original flowgraph so that it works with the USRP2 but I also changed it to work on the 70cm band.
 +
 +
* [[Media:USRP2_FM_narrowbandRX_Csete2.grc]]
  
 
Status: confirmed, works!
 
Status: confirmed, works!
Zeile 96: Zeile 111:
  
 
Status: confirmed, works!
 
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.
 +
 +
* First download the u2_flash_tool.py:
 +
** [[Media:u2_flash_tool.py]]
 +
* Then download the most recent FPGA firmware and the most recent U2 code from here:
 +
** http://code.ettus.com/redmine/ettus/projects/public/wiki/U2binaries
 +
** Be sure to download the "RAW Ethernet" FPGA image and the "Raw Ethernet, with WBX" Firmware image.
 +
* Then execute the following commands (here as root)
 +
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:
 +
 +
[[Image:USRP2_LSB_TX_Complex_Bandpass.jpg|400px]]
 +
 +
* [[Media:USRP2_LSB_TX_Complex_Bandpass.grc]]
 +
 +
Status: confirmed, works
  
 
=== Transmit a simple FM signal ===
 
=== Transmit a simple FM signal ===
Zeile 111: Zeile 152:
  
 
[[Image:GnuRadio_USRP2_NBFM_TRX.jpg|400px]]
 
[[Image:GnuRadio_USRP2_NBFM_TRX.jpg|400px]]
 +
 +
The first multiply block regulates the AF sensitivity and the second block regulates the transmit power.
 +
 +
* [[Media:usrp2_nbfm_tx.grc]]
  
 
Status: confirmed, works
 
Status: confirmed, works
Zeile 124: Zeile 169:
  
 
[[Image:GnuRadio_USRP2_SSB_TX.jpg|400px]]
 
[[Image:GnuRadio_USRP2_SSB_TX.jpg|400px]]
 +
 +
Status: unconfirmed, but looks good
  
 
=== Receive a SSB signal ===
 
=== Receive a SSB signal ===
Zeile 133: Zeile 180:
  
 
[[Image:GnuRadio_USRP2_SSB_RX.jpg|400px]]
 
[[Image:GnuRadio_USRP2_SSB_RX.jpg|400px]]
 +
 +
* [[Media:uspr2_ssb_rx_v05_LF_bin.grc]] A SSB receiver also from Alex Csete OZ9AEC
  
 
=== Transmit a D-ATV signal ===
 
=== Transmit a D-ATV signal ===
Zeile 164: Zeile 213:
 
* http://sourceforge.net/projects/sdr/ A complete Amateur Radio Transceiver implemented with USRP(1)
 
* http://sourceforge.net/projects/sdr/ A complete Amateur Radio Transceiver implemented with USRP(1)
 
* http://www.slideshare.net/csete/gnu-radio-and-the-universal-software-radio-peripheral-4889786 really cool flow graphs including analog Video mod and demod.
 
* http://www.slideshare.net/csete/gnu-radio-and-the-universal-software-radio-peripheral-4889786 really cool flow graphs including analog Video mod and demod.
 +
* http://www.danielgarcia.info/thesis/ prototype frame detector that does vertical and horizontal sync detection: decode PAL / NTSC in software usind GNURadio
 +
* http://www.youtube.com/watch?v=Yc3K3bUxPW8&feature=plcp GNURADIO: GNURADIO-COMPANION part-5 (Basic filtering)
 +
* http://www.youtube.com/watch?v=Ka540X5NjwE&feature=plcp GNURADIO: GNURADIO-COMPANION part-6-1 (Significance of sampling rate in simulations)
 +
* http://www.youtube.com/watch?v=7dvw-B_CGEg&feature=plcp GNURADIO: GNURADIO-COMPANION part-6-2 (Significance of sampling rate in simulations contd.)
 +
 +
== Movies ==
 +
* more to come
 +
 +
== Communication ==
 +
* http://lists.darc.de/mailman/listinfo/sdr DARC SDR mailing list

Aktuelle Version vom 25. Juni 2012, 17:56 Uhr

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.


1 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.

2 Projects

2.1 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.

2.2 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!

2.3 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!

2.4 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!

2.5 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!

2.6 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!

2.7 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!

2.8 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.

2.9 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

2.10 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.

2.11 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

2.12 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

2.13 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

2.14 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

2.15 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:

2.16 Transmit a Digital Video Stream


3 Links

4 Movies

  • more to come

5 Communication