Gnuradio/Wav to Waterfall
From charlesreid1
This covers my first foray into signal decoding with SDR and gnuradio.
Contents
Recording the Signal
I basically wanted to record a signal from an Amateur Radio WebSDR station, and figure out how to import it into gnuradio for signal analysis. Recording the signal was easy - the web interface actually has a recording capability. So it's as simple as clicking a button.
But these WebSDR recordings were single-channel - and I didn't know if I could use them in gnuradio.
Getting a Two-Channel SDR Wav File
Then I found an observatory that provides SDR data that's two channels, and a higher sample rate: http://to117.aai.ee/public_to117/Obs/SDR/HighRPM/Dish/
Getting Info about the Wav File
You can use the mediainfo
utility to get some info on the wav file:
mediainfo HDSDR_20140505_180828Z_437209kHz_RF.wav General Complete name : HDSDR_20140505_180828Z_437209kHz_RF.wav Format : Wave File size : 311 MiB Duration : 3mn 28s Overall bit rate mode : Constant Overall bit rate : 12.5 Mbps Audio Format : PCM Format settings, Endianness : Little Format settings, Sign : Signed Codec ID : 1 Duration : 3mn 28s Bit rate mode : Constant Bit rate : 12.5 Mbps Channel(s) : 2 channels Sampling rate : 391 KHz Bit depth : 16 bits Stream size : 311 MiB (100%)
Now we'll be able to use gnuradio to feed these two channels of sound data into a radio spectrum visualizer.
Note that we could also get that information by opening the Wav file in Audacity:
The Gnuradio Flowchart
The Wav File in Gnuradio
You can use the wav file as a source of sound data by using a "Wav File Source" block. Double click on the block, and pick your wav file to associate it with the block.
Float to Complex
You'll want to feed data from your Wav File Source block into a Float to Complex box. This is because the two channels of the Wav file correspond to the I and Q channels of the radio data. When you're hooking an SDR up to your computer, you're converting radio signals to IQ data; in this case, we're using the recorded Wav file as a stand-in for a real-time radio signal from an SDR.
Throttle
You'll want to throttle the data coming out of the wav file. By default, Gnuradio doesn't limit the speed at which you can extract data from a wav file - so if you wanted to analyze it all at once, in an instant, you could. The throttle makes sure the data is "played back" at the same sample rate that it was gathered at - so that we see the "real time" signal being played back.
Waterfall Sink
We want to pipe the result of all of this into a Waterfall widget, so that we can look at the spectrum visually.
The Result
Here's the resulting Gnuradio flowchart:
and the resulting output - with a very weak signal:
In the next part, Gnuradio/Frequencies of Interest, we'll take a look at that frequency of interest, and apply a filter to it so we can pick out the signal.
References
SDR Wav Files: http://to117.aai.ee/public_to117/Obs/SDR/HighRPM/Dish/
Steps: http://andres.svbtle.com/using-gnu-radio-to-show-iq-wav-file-on-waterfall-plot
Flags
radio all things radio.
Ham Radio: Notes on General class license: General Digital modes: Radio/Digital Modes
Ham Radio Hardware (Radios): Kenwood TS 440S: Radio/Kenwood/TS440S Kenwood TS 570S: Radio/Kenwood/TS570S Yaesu VX-6: Radio/Yaesu/VX-6 Digital Modes on Raspberry Pi: RaspberryPi/Digital Modes Digital Modes on Arduino: Arduino/Digital Modes DVB-T USB SDR Dongle: DVB-T USB SDR
Ham Radio Software: Software defined radio: SDR Comprehensive list of ham software: Andys Ham Radio Linux Direwolf (soundcard TNC/APRS modem): Direwolf Echolink (internet repeater system): Echolink Qsstv (Slow scan television): Qsstv Fldigi (fast light digital modes): Fldigi Xastir (APRS/AX25/TNC): Xastir RadioHead (packet library for microcontrollers): RadioHead
Category:Radio · Category:Kenwood · Category:Yaesu Flags · Template:RadioFlag · e |
SDR software defined radio
SDR Software: SDR through the web browser: WebSDR The "true" software defined radio: Gnuradio WAV file to Waterfall: Gnuradio/Wav to Waterfall Gqrx spectrum analyzer: Gqrx
Android + HackRF/SDR: Android/SDR Kali Linux + Gqrx + HackRF: Kali/HackRF Kali Linux + Gqrx + RTL-SDR Dongle: Kali/SDR Dongle
SDR Hardware: HackRF: HackRF · Kali/HackRF RTL-SDR Dongle: Kali/SDR Dongle FlightAware: FlightAware
|