Sdrx User Manual

  1. Introduction
  2. Compilation
  3. Operation
  4. Spectrum Displays
  5. Stations List
  6. Bugs and annoyances
  7. Version history
  8. Copying

1. Introduction
Currently sdrx is mainly a project intended for teaching myself the development of Software Defined Radio functions and Digital Signal Processing. I have built into sdrx an FFT-based Spectrum Display and Demodulators for Frequency Modulated and Amplitude Modulated radio transmissions, Single Sideband (USB/LSB) signals and for CW (Morse code) transmissions. Sdrx has Controls for setting up RTL2832x-based SDR dongles via librtlsdr, Mirics-based SDR receivers via libmirsdrapi-rsp and Perseus receivers via libperseus-sdr.

These include the Center Frequency Spin Dial and direct Text Entry widget for entering the Receiver Center Frequency, selectable Automatic Frequency Control (AFC), Signal Strength Indicator (of progress bar type), Combo Boxes for selecting ADC Sampling Rate, ADC Buffer Size, FFT/Spectrum Bandwidth, Modulation Mode, Weaver Frequency and Demodulator Bandwidth. Receiver Gain Mode (Manual/Auto/Audio Derived) can be selected by activating the relevant Radio Button and a Slider Control is available for setting the Receiver Gain manually. The decay rate of the Audio Derived AGC (ADAGC system) can be set by a Slider Control, from very slow to very fast as needed. A selectable Noise Activated Squelch with a Slider Control is available but in FM mode only.

As of version 0.9-beta, Sdrx includes functions for receiving and decoding Time Signal stations on VLF and Long Wave. Currently Sdrx can receive time and date data from MSF on 60kHz, RBU on 66.667kHz, DCF77 on 77.5kHz and TDF/Allouis on 162kHz. The detection of data bits and the synchronization signals is done by pattern matching rather than hard threshold-ing, so that Sdrx can successfully copy weak time station signals even well outside the official range. For example, the MSF signal on 60kHz can quite often be received and decoded even though it is about 3500km away! Development of time station receiving and decoding functions was done using a Perseus SDR receiver and a 1/4l GP antenna for the 30m amateur band (7.5m high).

Sdrx includes a Chebyshev Low Pass Filter which is used as a Low Pass "Roofing Filter" of the Sample Stream from the SDR dongle and also for setting the bandwidth of the FFT-based Spectrum Display. Individual demodulator functions also use Chebyshev filters to set the Demodulator Bandwidth according to the user's selection of Modulation Mode and for narrowing signal input to the AFC function. Play Back of demodulated signals is via the computer's Sound Card and by using the ALSA sound system API.

2. Compilation
Please note that I use Void Linux AMD64 which is a "bleeding edge" type distribution, so there may be compilation and/or run time difficulties, if you are using a relatively old distro. This is mostly true of the basic dependencies like GTK+-2 and Glade-2. Other dependencies are the RTLSDR library librtlsdr, the Mirics SDRplay_RSP_MiricsAPI-Linux library and the Perseus API.

To compile the package, it may be preferable to first run the included "autogen.sh" script in the package's top directory, to produce a fresh build environment. Then the "configure" script can be run with optional parameters to override the default settings and compiler flags, e.g: ./configure --prefix=/usr CFLAGS="-g -O2" will override the default /usr/local installation prefix and the "-Wall -O2" compiler flags.

Running "make" in the package's top directory should produce the executable binary in src/. Running "make install" will install the binary into /usr/local/bin by default or under the specified prefix. At this time it is also necessary to manually copy Sdrx's working directory, .sdrx, to the user's home directory. This directory contains two files, the "sdrxrc" configuration file which will have to be edited by the user as required, and the "stations" file which contains a default listing of some stations. This file must only be edited by activating the "Stations List" button and using the "Station Listing" editor window. This is described later in this documentation.

3. Operation
Before running sdrx, it may be necessary to customize some entries in the ~/.sdrx/sdrxrc configuration text file in your home directory. These are the items that will need editing:

The GTK+-2 user interface:
Sdrx's Main window contains the following widgets:

4. FFT Spectrum Display Window
As of version 1.1, Sdrx has a separate Window for the FFT-generated Spectrum and Amplitude Displays of the incoming radio transmission. The lower display is in the "Waterfall" style and the upper in an "Oscilloscope" style. The width of both the displays corresponds to the currently selected Bandwidth of the FFT-Spectrum Filter. As of version 1.3, the Spectrum display has a frequency scale that has a range equal to the FFT bandwidth, either side of the current Center Frequency. In order to keep this in the center of the display (marked by a vertical bright cyan line), the frequency scale is shifted horizontally as required.
At the left side of the Spectrum display, there is a Relative Signal Level scale, calibrated from 0 to -80dB, relative to the strongest signal in the FFT bandwidth. This can be used to compare the Signal strength of different stations or signals in the Spectrum display.

5. Stations List
As of version 0.8-beta, Sdrx includes a "Stations List" window, which can be opened by clicking the "Stations List" Button at the bottom left of the Sdrx main window. This window can be used to select a Station that is already saved in the ~/.sdrx/stations file, make and save a new Stations List entry, edit an existing entry and delete it if so desired. Clicking on a row in this window will enter the Frequency and Mode of the Station into Srdx and into the Receiver, if already activated. Also, clicking the "Up" or "Down" buttons will move the selection accordingly, to the next or previous row, again entering Station data into Sdrx and the Receiver. The "Delete" button removes the selected Row from the List, while the "New" button enters a new blank row into the list, to be edited by the user. This can be done manually, by selecting the blank row and entering the Station Name, the Frequency and the Mode. It is also possible to enter the last two from the current settings of Sdrx, by clicking with the middle button on to the blank row. The Name of the Station will still have to be entered manually. Finally, clicking the "Save" button will save all entries in the Stations List window to the ~/.sdrx/stations file in the user's directory.

As of version 0.9 beta, Sdrx has functions to receive, decode and display the Date, Time, Summer Time in Effect, Leap Second, DUT1, Parity Bit status and other data as transmitted by Time and Frequency Reference stations on VLF frequencies. Currently Sdrx can receive such data from the German DCF77 on 77.5kHz, the Russian RBU on 66.667kHz and British MSF on 60kHz. Currently development of this functionality is done using the Perseus SDR receiver and a Ground Plane antenna for the 10 MHz band (7.5m high). The first two stations are about 2500km away and MSF is 3500km away but in good weather conditions (no thunderstorms) it can be received and decoded successfully!
The time decoding function is activated from the Time Stations toggle button, which opens the Time Stations window for further action. In this window, the Time Station Combo Box allows selection of the Time station, while the Receive toggle button starts the relevant receiving and decoding functions. The Time Stations window has a display for the Date and Time, as well as many indicators for Status decodes and error conditions, depending on the Time Station. Some stations (e.g. RBU and MSF) transmit DUT1 too, while RBU transmits Julian Day and DUT data also.
Please note that even in good conditions, it takes a few minutes for Sdrx to sync with the time station and correctly decode date and time data.

6. Bugs and annoyances
I have fixed whatever bugs I came across testing sdrx but there may be some hiding, waiting for the right conditions to appear.

7. Version history
Version 0.1-beta This is the first release of sdrx and my first attempt at writing a significant DSP/SDR Receiver application. It used a 2-pole Butterworth LPF and had a WBFM de-modulator. Play back was done by piping the o/p of the de-modulator to "aplay"

Version 0.2-beta I added a de-modulator for AM transmissions and Playback functionality by ALSA sound API. Changed the synchronization method between the async streaming function and the rest of sdrx, from a polling loop to using mutexes under pthreads.

Version 0.3-beta Added De-modulators for SSB and CW, using the Weaver Detector method. I also changed the Low Pass Filter to a 6-pole Chebyshev type for sharper cutoff and for operation with the Weaver SSB De-modulator.

Version 0.4-beta Added a "Spin Dial" for entering the Tuner center frequency. It has ten digits and each is individually variable by pointing to it and scrolling the mouse or trackball.

Version 0.5-beta Added support for the SDRPlay RSP1 SDR Receiver via the SDRplay_RSP_MiricsAPI-Linux library.

Version 0.6-beta Added additional GUI widgets (combo boxes, radio buttons, entry widgets and sliders) to give the user more choice and control over the parameters and settings affecting the operation of Sdrx. Made some changes to the AFC code to improve stability and facilitate Synchronous AM Demodulation by locking the Sdrx center frequency to the incoming AM signal's carrier frequency. Added a simple Signal Strength indicator widget (progress bar).

Version 0.7-beta Added support for the Mikrotelecom Perseus direct sampling SDR Receiver, via the libperseus-sdr library. Also improved the Audio Derived AGC function since it is the only way to automatically control the "Gain" (more correctly scale the audio output) of direct sampling receivers.

Version 0.8-beta Added a Stations List window, to allow saving station data to a file (~/.sdrx/stations) and loading and selecting stations from this file as desired by the user.

Version 0.9-beta I have modified the GUI to increase the size of the "Scope" display and re-organize the various widgets in the main window. Developed functions to receive, decode and display Date, Time, DUT1, Julian Day and other data and status flags from VLF Time stations (DCF77 on 77.5kHz, RBU on 66.667kHz and MSF on 60kHz) and TDF/Allouis on 162kHz LW.

Version 0.9 Fixed a bug that caused seg faults when Sdrx was run under different window managers than my own (openbox). This happened when the spectrum/waterfall display was enabled, because the final size of the spectrum/waterfall drawing areas was different to the original size request, possibly due to the different sizes of window decorations under different window managers.

Version 1.0 Fixed a bug in the function that tunes Sdrx to a frequency selected by clicking on the Spectrum display. It was possible to end up with a negative center frequency request that naturally resulted in an error message.

Version 1.1 Fixed a bug in the function that displays the waterfall. Pixel values were calculated incorrectly and so the pseudo-colors in the waterfall were not right. Also moved the Waterfall and Scope displays into a separate window so that they will only be displayed when the Spectrum button is toggled ON. The spectrum display can be "frozen" by toggling the Spectrum button OFF. The size of these displays has also been increased since they are now in an independent window.

Version 1.2 I calibrated the Signal Strength indicator using a borrowed signal generator, to show signal strength in dBm. I works, hopefully well enough, with the Perseus SDR and the SdrPlay RSP1 receivers. With RTL-SDR devices, there seems to be no signal strength data returned in Hardware AGC mode. I also added code that controls Perseus attenuators automatically, depending on signal strength. Fixed some obscure bugs that surfaced during this effort.

Version 1.3 I re-calibrated the Signal Strength indicator using a borrowed signal generator, to show signal strength in dBm. It works well enough, at least with the Perseus SDR and the SdrPlay RSP1 receivers. With RTL-SDR devices, there seems to be no signal strength data returned in Hardware AGC mode.
I added a Frequency scale at the bottom of the Spectrum display with a range equal to the FFT bandwidth, and a relative Level scale in dB at the left side so that signal strength of different stations can be compared. The Spectrum display is now logarithmic rather than linear
I also added code that controls Perseus attenuators automatically, depending on signal strength. Fixed some obscure bugs that surfaced during this effort.

8. Copying This software package is released under the GNU Public License. Please see the COPYING file for more details.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details

Last modified: Sat Mar 8 07:16:51 EET 2003