Jump to: navigation, search

Objective: Characterize several "sound cards" (USB and built-in) for use in SDR reception with "tiny" Linux-based computers in the Raspberry Pi / BeagleBone class. Specifically, we are interested in using SDR for a panadapter / spectrum analyzer display.

Test Systems

  • BeagleBoard XM development board. This is an ARM-based board with a rich set of interfaces, in particular a full capability built-in audio subsystem, with 16 bit sampling up to 48 kHz.
ALSA ID:  [omap3beagle ] omap3beagle
  • Sound Blaster SB1240 "X-Fi HD" external USB sound card, featuring 24-bit sampling up to 96 kHz and phono-level input.
ALSA ID:  [HD          ] USB-Audio - USB Sound Blaster HD
          Creative Technology USB Sound Blaster HD at ...
  • iConnex iKey-Audio. This is an inexpensive external USB card supporting 48 kHz 16 bit sampling with phono-level input.
          Burr-Brown from TI USB Audio CODEC at ...
  • Toshiba L645D-S4036 laptop running Ubuntu 12.04 Linux. This laptop has a stereo microphone input connector that supports 48 kHz 16 bit sampling.
ALSA ID:  [SB          ] HDA-Intel - HDA ATI SB
          HDA ATI SB at ...

Test Equipment

  • Elecraft KX3 Transceiver
  • Vectron 718Y3811 10 MHz OCXO
  • Tektronix CFG250 Function Generator
  • Misc. attenuators
  • Audio isolation transformer. For example, this one.
  • panadapter software (in development)


To understand a sound card, it would be ideal to measure basic electrical properties: sensitivity, noise, phase and amplitude vs frequency, linearity, etc. Unfortunately, the laboratory-grade instruments to make those measurements accurately are not available on my bench. But it is possible to combine data taken with fairly typical amateur radio equipment to get a pretty good evaluation of the merits of various sound systems for Software Defined Radio (SDR).

The Elecraft KX3 is an advanced design SDR transceiver that provides I and Q (in-phase and quadrature) audio outputs suitable for our tests. The KX3 is no doubt imperfect - in terms of local oscillator noise, linearity, etc., but it has shown very good results in careful bench tests. (See the Sherwood Engineering test data.) We use the KX3 as an I/Q signal generator to evaluate our sound cards. We drive the KX3 with a stable crystal oscillator to evaluate image suppression. As a secondary test, we can receive data from a complex off-air spectrum (AM/HD broadcast) to make a further judgement of how useful a given sound card may be in real-life situations.

All but one of our sound cards are limited to a maximum 48 kHz sampling, 16 bits, so this will be our measurement range - plus or minus 24 kHz from the receiver's center frequency. Wider bandwidths are desirable, but we find that the one card that supports 96 kHz encounters spurious signals from the KX3 at +/- 30 kHz.


BeagleBoard XM development board

Image tests

BB XM: 1 kHz offset
BB XM: 5 kHz offset
BB XM: 10 kHz offset
BB XM: 20 kHz offset

AM Test

BB XM: AM HD Broadcast


Note the narrow and weak noise peak at zero frequency. (A glitch of this sort is common in a direct conversion receiver setup. It reflects the amplitude roll-off, DC bias, and a noise peak at a very low audio frequency.) The signal at 1 kHz offset is down by 10-12 dB from the level at wider offsets.

The signal peaks at 5, 10, and 15 kHz are essentially flat. The width at -3 dB is about 3 frequency channels, ~300 Hz. (The power spectrum calculation does not use any windowing function.) The width at -30 dB is roughly 4 kHz.

The image response (signal reflected about zero frequency) is 30-35 dB down from the signal. We are not making any phase or amplitude corrections on the data. Image performance could probably be improved a good deal with such methods.

The spectrum baseline is flat within a few dB across the 48 kHz band.

The AM HD broadcast spectrum clearly shows the carrier (offset by -2 kHz), the conventional AM sidebands, and the rectangular digital sidebands. Weak adjacent station carriers at +/- 20 kHz are also visible.

Sound Blaster SB1240

Image tests

SB1240: 1 kHz offset
SB1240: 5 kHz offset
SB1240: 10 kHz offset
SB1240: 20 kHz offset
SB1240: 44 kHz offset
SB1240: AM HD broadcast


The SB1240 exhibits a strong DC peak. The tails (presumably noise sidebands) of the DC peak are quite broad. At -30 dB, the bandwidth is about 16 kHz. There are also spurious peaks at +/- 12 kHz, about -20 dB compared to the DC peak -- or the test signal level. The signal image is 30-35 dB below the signal.

The problems around zero offset show up clearly in the AM HD broadcast spectrum, where the various components are not clearly resolved. To some extent, this situation could be improved by removing the average DC peak from the data.

We made one test at 96 kHz sampling. (Note the plot scale indicates +/- 24 when it should say +/- 48 kHz.) We see a strong signal at +/- 31 kHz, which we attribute to the KX3. Other "spurs" at +/- 24 and +/- 12 kHz are also visible. With a different radio (such as a SoftRock), 96 kHz might be a useful sampling rate.

Note that the SB1240 provides a "phonograph" gain setting, which you might think is useful for I/Q reception, where audio signals can be rather weak. But don't use it! (See below.)

Later tests. The power falloff is much more apparent with the "phonograph" setting than "line". This reflects the frequency response of the phono preamp, i.e., the RIAA phono equalization, which reduces gain at 20 kHz by about 20 dB. The moral is to use "line" setting (or possibly a "mic preamp" if provided) for critical work. This should be OK for SDR as long as the input signal level is enough to engage several of the least significant ADC bits.

iConnex iKey-Audio

Image tests

iConnex: 1 kHz offset
iConnex: 5 kHz offset
iConnex: 10 kHz offset
iConnex: 20 kHz offset
iConnex: AM HD


The iConnex is an example of an inexpensive USB sound card. It does provide "phono" level stereo inputs and 48 kHz 16 bit sampling. It appears to be based on the Burr-Brown PCM2902 codec chip.

The iConnex demonstrates poor-to-nonexistent image rejection, without correction. At 1 kHz we see about 22 dB image rejection, decrease to zero dB at 10 kHz and NEGATIVE 10 dB at 20 kHz. There is a spur at +/- 12 kHz. The AM HD broadcast spectrum is very indistinct.

Part of the image problem could be alleviated by careful calibration in software, but at least in my view, it is too much for practical use.

Later tests. Like the SB1240, the iConnex high frequency response is degraded when using its phono input option. Unfortunately, changing to "line" input does nothing to improve the image rejection. We also tested the Behringer UCA202 USB Audio Interface. While it does not have the "phono" amplifier option, its performance is rather similar to the iConnex in terms of image rejection.

Toshiba L645D-S4036 laptop

Image tests

Toshiba L645D: 1 kHz offset
Toshiba L645D: 5 kHz offset
Toshiba L645D: 10 kHz offset
Toshiba L645D: 20 kHz offset
Toshiba L645D: AM HD Broadcast


The Toshiba laptop shows performance quite similar to the Beagleboard XM, except for a strong DC peak that is roughly equal to the test signal. The central peak does not carry wide noise sidebands, however.

Image responses are 30-35 dB down. The AM HD spectrum is very clear.

Correcting the Baseline on the SB1240

The baseline spectrum of the SB1240 USB sound card is relatively poor for our work, dominated by wide-band noise power around zero frequency (above). Is this a problem? Perhaps not if the objective is to demodulate a signal somewhere in the +/- 24 kHz bandpass. However, our interest has been to have a good "panadapter" display of the spectrum around the current working frequency. For this, a flat baseline is very desirable.

It is straightforward to measure the average signal-free response of the SB1240 and use this information to correct the spectrum. In principle, we just subtract the average noise spectrum from the observed signal+noise spectrum. Of course, there are still problems around zero frequency. The receiver is noisier out to several kHz from zero, so it may be harder to pick out weak signals. Also, there is an even greater problem close to zero frequency, where the sound card has poor sensitivity.

The noise spectrum from this sound card appears to have two components: a sharp ~ 8 channel (1 kHz) wide peak with a peak apparent power of 20 dB and a much broader component visible all the way to the +/- 12 kHz band edges with a peak power of also about 20 dB. We could simply estimate the noise power point-by-point by eye and enter in a numerical spectrum. However, it is more economical to make a least-squares power spectrum fit in two segments: the inner part +/- 8 channels and the outer part. (Making two segments reduces the required polynomial order to fit the data. We found that a single 9th order polynomial would represent the full spectrum well, but it required more than precision than 64-bit floating point could provide.)

SB1240 response with no signal
SB1240 corrected response

We can use a 2nd order fit for the central peak and a 3rd order fit for the extended part. The zero-signal corrected spectrum is shown at right. (We used LibreOffice Calc with the corelPolyGUI extension to make the fits.) Now, with no signal, things look pretty good.

Recall that we had an AM HD broadcast response like the one at right with no baseline correction.

SB1240 AM HD uncorrected baseline
SB1240 AM HD reception, corrected baseline

With correction, the HD broadcast looks much better, fairly similar to what we see with better sound cards on the BeagleBoard XM and the Toshiba laptop. Unfortunately, the central gap still causes problems when we are trying to view signals within ~ 1 kHz of the zero frequency at center. We might make some improvements, but it appears we will have to live with some problems there.

SB1240 Baseline - LibreOffice

The baseline fit with a polynomial is quite good. The graphs compare the observed data (points with scatter) against the best fit function. See corelPolyGUI documentation (in French) for more details.

Preliminary Conclusions

The driving factor in this investigation was to find a good cheap sound card to use with tiny Linux computer systems, like the Raspberry Pi or BeagleBone, which do not have on-board audio input. One would hope to find a solution that was priced comparably ($35-$45) to those CPU cards.

Alas, we have found no good solutions, at least among the USB sound cards. The Sound Blaster SB1240 is probably acceptable for many SDR projects, but it is not cheap (~$85). Its performance, uncorrected, is definitely poorer than built-in audio options on the BeagleBoard XM or on at least some PCs.

There are some non-USB audio solutions for the BeagleBone - an audio cape. It is priced lower (~$52), and it appears promising for SDR work, but it is not yet supported by the Linux version distributed for the latest BeagleBone Black CPU. (May, 2013)

For high performance, the best off-the-shelf solution (among those tested) still appears to be the BeagleBoard XM, a complete system at ~$152 that includes Ethernet, USB, audio, HDMI, RS-232, and more.