A Software-Defined Radio For The Masses
A Software-Defined Radio For The Masses
8900 Marybank Dr
Austin, TX 78750
[email protected]
can completely change its functionality. This allows easy upgrade to new
modes and improved performance
without the need to replace hardware.
SDRs can also be easily modified to
accommodate the operating needs of
individual applications. There is a distinct difference between a radio that
internally uses software for some of its
functions and a radio that can be completely redefined in the field through
modification of software. The latter is
a software-defined radio.
This SDR convergence is occurring
because of advances in software and
silicon that allow digital processing of
radio-frequency signals. Many of
these designs incorporate mathematical functions into hardware to perform
all of the digitization, frequency selection, and down-conversion to base-
Jul/Aug 2002 13
band. Such systems can be quite complex and somewhat out of reach to
most amateurs.
One problem has been that unless
you are a math wizard and proficient
in programming C++ or assembly language, you are out of luck. Each can be
somewhat daunting to the amateur as
well as to many professionals. Two
years ago, I set out to attack this challenge armed with a fascination for
technology and a 25-year-old, virtually unused electrical engineering degree. I had studied most of the math in
college and even some of the signal
processing theory, but 25 years is a
long time. I found that it really was a
challenge to learn many of the disciplines required because much of the
literature was written from a mathematicians perspective.
Now that I am beginning to grasp
many of the concepts involved in software radios, I want to share with the
Amateur Radio community what I
have learned without using much
more than simple mathematical concepts. Further, a software radio
should have as little hardware as possible. If you have a PC with a sound
card, you already have most of the
required hardware. With as few as
three integrated circuits you can be up
and running with a Tayloe detector
an innovative, yet simple, direct-conversion receiver. With less than a
dozen chips, you can build a transceiver that will outperform much of
the commercial gear on the market.
Approach the Theory
In this article series, I have chosen to
focus on practical implementation
rather than on detailed theory. There
are basic facts that must be understood
to build a software radio. However,
much like working with integrated circuits, you dont have to know how to
create the IC in order to use it in a design. The convention I have chosen is to
describe practical applications followed by references where appropriate
for more detailed study. One of the
easier to comprehend references I have
found is The Scientist and Engineers
Guide to Digital Signal Processing by
Steven W. Smith. It is free for download
over the Internet at www.DSPGuide.
com. I consider it required reading for
those who want to dig deeper into
implementation as well as theory. I will
refer to it as the DSP Guide many
times in this article series for further
study.
So get out your four-function calculator (okay, maybe you need six or
14 Jul/Aug 2002
(Eq 1)
D-to-A conversion. Also refer to Doug Smiths article, Signals, Samples, and Stuff: A DSP Tutorial.1
What you need to know for now is that if we adhere to the
Nyquist criterion in Eq 1, we can accurately sample, process and recreate virtually any desired waveform. The
sampled signal will consist of a series of numbers in computer memory measured at time intervals equal to the
sampling rate. Since we now know the amplitude of the
signal at discrete time intervals, we can process the digitized signal in software with a precision and flexibility not
possible with analog circuits.
From RF to a PCs Sound Card
Our objective is to convert a modulated radio-frequency
signal from the frequency domain to the time domain for
software processing. In the frequency domain, we measure
amplitude versus frequency (as with a spectrum analyzer);
in the time domain, we measure amplitude versus time (as
with an oscilloscope).
In this application, we choose to use a standard 16-bit PC
sound card that has a maximum sampling rate of
44,100 Hz. According to Eq 1, this means that the maximum-bandwidth signal we can accommodate is 22,050 Hz.
With quadrature sampling, discussed later, this can actually be extended to 44 kHz. Most sound cards have built-in
antialiasing filters that cut off sharply at around 20 kHz.
(For a couple hundred dollars more, PC sound cards are
now available that support 24 bits at a 96-kHz sampling
rate with up to 105 dB of dynamic range.)
Most commercial and amateur DSP designs use dedicated
DSPs that sample intermediate frequencies (IFs) of 40 kHz
or above. They use traditional analog superheterodyne techniques for down-conversion and filtering. With the advent of
very-high-speed and wide-bandwidth ADCs, it is now possible to directly sample signals up through the entire HF
range and even into the low VHF range. For example, the
Analog Devices AD9430 A/D converter is specified with
sample rates up to 210 Msps at 12 bits of resolution and a
700-MHz bandwidth. That 700-MHz bandwidth can be used
in under-sampling applications, a topic that is beyond the
scope of this article series.
The goal of my project is to build a PC-based softwaredefined radio that uses as little external hardware as possible while maximizing dynamic range and flexibility. To
do so, we will need to convert the RF signal to audio frequencies in a way that allows removal of the unwanted
mixing products or images caused by the down-conversion
process. The simplest way to accomplish this while maintaining wide dynamic range is to use D-C techniques to
translate the modulated RF signal directly to baseband.
1
Jul/Aug 2002 15
16 Jul/Aug 2002
mt = I t2 + Qt2
(Eq 3)
It
Therefore, if we measured the instantaneous values of I and Q, we
would know everything we needed to
know about the signal at a given moment in time. This is true whether we
are dealing with continuous analog
signals or discrete sampled signals.
With I and Q, we can demodulate AM
signals directly using Eq 3 and FM
signals using Eq 4. To demodulate
SSB takes one more step. Quadrature
signals can be used analytically to remove the image frequencies and leave
only the desired sideband.
The mathematical equations for
quadrature signals are difficult but
are very understandable with a little
study.2 I highly recommend that you
read the online article, Quadrature
t = tan 1
Fig 6Quadrature sampling mixer: The RF carrier, fc, is fed to parallel mixers. The local
oscillator (Sine) is fed to the lower-channel mixer directly and is delayed by 90 (Cosine)
to feed the upper-channel mixer. The low-pass filters provide antialias filtering before
analog-to-digital conversion. The upper channel provides the in-phase (I(t)) signal and the
lower channel provides the quadrature (Q(t)) signal. In the PC SDR the low-pass filters
and A/D converters are integrated on the PC sound card.
BWbin =
44100
= 10.7666 Hz and
4096
f center = n10.7666 Hz
Fig 8Complex FFT output: The output of a complex FFT may be thought of as a series
of band-pass filters aligned around the carrier frequency, fc, at bin 0. N represents the
number of FFT bins. The upper sideband is located in bins 1 through (N/2)1 and the
lower sideband is located in bins N/2 to N1. The center frequency and bandwidth of
each bin may be calculated using Eqs 5 and 6.
Jul/Aug 2002 17
18 Jul/Aug 2002
Fig 9SDR receiver software architecture: The I and Q signals are fed from the soundcard input directly to a 4096-bin complex FFT. Band-pass filter coefficients are
precomputed and converted to the frequency domain using another FFT. The frequencydomain filter is then multiplied by the frequency-domain signal to provide brick-wall
filtering. The filtered signal is then converted to the time domain using the inverse FFT.
Adaptive noise and notch filtering and digital AGC follow in the time domain.
Fig 10Tayloe detector: The switch rotates at the carrier frequency so that each
capacitor samples the signal once each revolution. The 0 and 180 capacitors
differentially sum to provide the in-phase (I) signal and the 90 and 270 capacitors sum
to provide the quadrature (Q) signal.
G=
Rf
4Rant
(Eq 7)
For example, with a feedback resistance, Rf , of 3.3 k and antenna impedance, Rant, of 50 , the resulting
gain of the input stage is:
G=
3300
= 16.5
4 50
Jul/Aug 2002 19
(Eq 8)
nRant Cs
fc
(Eq 9)
BWdet
By example, if we assume the sampling capacitor to be 0.27 F and the
antenna impedance to be 50 , then
BW and Q are computed as follows:
Qdet =
BWdet =
Qdet =
1
( )(4)(50)(2.7 10 7 )
= 5895 Hz
14.001 10 6
= 2375
5895
20 Jul/Aug 2002
SDR Applications
At the time of this writing, the typical entry-level PC now runs at a clock
frequency greater than 1 GHz and
costs only a few hundred dollars. We
now have exceptional processing
power at our disposal to perform DSP
tasks that were once only dreams. The
transfer of knowledge from the aca-
Fig 13Alias summing on Tayloe detector output: Since the Tayloe detector samples the
signal the sum frequency (f c + f s) and its image (f c f s) are located at the first alias
frequency. The alias signals sum with the baseband signals to eliminate the mixing
product loss associated with traditional mixers. In a typical mixer, the sum frequency
energy is lost through filtering thereby increasing the noise figure of the device.
Fig 14PC SDR receiver hardware architecture: After band-pass filtering the antenna is
fed directly to the Tayloe detector, which in turn provides I and Q outputs at baseband. A
DDS and a divide-by-four Johnson counter drive the Tayloe detector demultiplexer. The
LT1115s offer ultra-low noise-differential summing and amplification prior to the widedynamic-range analog AGC circuit formed by the SSM2164 and AD8307 log amplifier.
11D.
Gerald became a ham in 1967 during high school, first as a Novice and
then a General class as WA5RXV. He
completed his Advanced class license
and became KE5OH before finishing
high school and received his First
Class Radiotelephone license while
working in the television broadcast
industry during college. After 25 years
of inactivity, Gerald returned to the active amateur ranks in 1997 when he
completed the requirements for Extra
class license and became AC5OG.
Gerald lives in Austin, Texas, and is
currently CEO of Sixth Market Inc, a
hedge fund that trades equities using
artificial-intelligence software. Gerald
previously founded and ran five technology companies spanning hardware,
software and electronic manufacturing.
Gerald holds a Bachelor of Science Degree in Electrical Engineering from
Mississippi Stage University.
Gerald is a member of the ARRL
SDR working Group and currently
enjoys homebrew software-radio development, 6-meter DX and satellite operations.
Jul/Aug 2002 21
A Software-Defined Radio
for the Masses, Part 2
Come learn how to use a PC sound card to enter
the wonderful world of digital signal processing.
8900 Marybank Dr
Austin, TX 78750
[email protected]
10 Sept/Oct 2002
Very early PC sound cards were lowperformance, 8-bit mono versions. Today, virtually all PCs come with
16-bit stereo cards of sufficient quality
to be used in a software-defined radio.
Such a card will allow us to demodulate, filter and display up to approximately a 44-kHz bandwidth, assuming
a 44-kHz sampling rate. (The bandwidth is 44 kHz, rather than 22 kHz,
because the use of two channels effectively doubles the sampling rateEd.)
For high-performance applications, it is
important to select a card that offers a
high dynamic rangeon the order of
90 dB. If you are just getting started,
most PC sound cards will allow you to
begin experimentation, although they
Fig 1Direct quadrature conversion mixer to sound-card interface used in the authors
prototype.
Sept/Oct 2002 11
12 Sept/Oct 2002
Fig 4Registration of the DirectX8 for Visual Basic Type Library in the Visual
Basic IDE.
Option Explicit
Define Constants
Const Fs As Long = 44100
Sampling frequency Hz
Const NFFT As Long = 4096
Number of FFT bins
Const BLKSIZE As Long = 2048
Capture/play block size
Const CAPTURESIZE As Long = 4096
Capture Buffer size
Define DirectX Objects
Dim dx As New DirectX8
DirectX object
Dim ds As DirectSound8
DirectSound object
Dim dspb As DirectSoundPrimaryBuffer8 Primary buffer object
Dim dsc As DirectSoundCapture8
Capture object
Dim dsb As DirectSoundSecondaryBuffer8 Output Buffer object
Dim dscb As DirectSoundCaptureBuffer8 Capture Buffer object
Define Type Definitions
Dim dscbd As DSCBUFFERDESC
Dim dsbd As DSBUFFERDESC
Dim dspbd As WAVEFORMATEX
Dim CapCurs As DSCURSORS
Dim PlyCurs As DSCURSORS
Define loop counter variables for timing the capture event cycle
Dim TimeStart As Double
Start time for DirectX8Event loop
Dim TimeEnd As Double
Ending time for DirectX8Event loop
Dim AvgCtr As Long
Counts number of events to average
Dim AvgTime As Double
Stores the average event cycle time
Set up Event variables for the Capture Buffer
Implements DirectXEvent8
Allows DirectX Events
Dim hEvent(1) As Long
Handle for DirectX Event
Dim EVNT(1) As DSBPOSITIONNOTIFY
Notify position array
Dim Receiving As Boolean
In Receive mode if true
Dim FirstPass As Boolean
Denotes first pass from Start
Fig 5Declaration of variables, buffers, events and objects. This code is located in the General section of the module or form.
Sept/Oct 2002 13
Set up the DirectSound Objects and the Capture and Play Buffers
Sub CreateDevices()
On Local Error Resume Next
Set ds = dx.DirectSoundCreate(vbNullString)
DirectSound object
Set dsc = dx.DirectSoundCaptureCreate(vbNullString)
DirectSound Capture
Check to se if Sound Card is properly installed
If Err.Number <> 0 Then
MsgBox Unable to start DirectSound. Check proper sound card installation
End
End If
Set the cooperative level to allow the Primary Buffer format to be set
ds.SetCooperativeLevel Me.hWnd, DSSCL_PRIORITY
Set up format for capture buffer
With dscbd
With .fxFormat
.nFormatTag = WAVE_FORMAT_PCM
.nChannels = 2
Stereo
.lSamplesPerSec = Fs
Sampling rate in Hz
.nBitsPerSample = 16
16 bit samples
.nBlockAlign = .nBitsPerSample / 8 * .nChannels
.lAvgBytesPerSec = .lSamplesPerSec * .nBlockAlign
End With
.lFlags = DSCBCAPS_DEFAULT
.lBufferBytes = (dscbd.fxFormat.nBlockAlign * CAPTURESIZE) Buffer Size
CaptureBytes = .lBufferBytes \ 2
Bytes for 1/2 of capture buffer
End With
Set dscb = dsc.CreateCaptureBuffer(dscbd)
14 Sept/Oct 2002
dscb.SetNotificationPositions 2, EVNT()
End Sub
Fig 7Create the DirectX events.
Stop Playback
Stop Capture
Dim i As Integer
For i = 0 To UBound(hEvent)
Kill DirectX Events
DoEvents
If hEvent(i) Then dx.DestroyEvent hEvent(i)
Next
Set
Set
Set
Set
Set
dx = Nothing
ds = Nothing
dsc = Nothing
dsb = Nothing
dscb = Nothing
Unload Me
End Sub
Fig 8Create and destroy the DirectSound Devices and events.
Sept/Oct 2002 15
16 Sept/Oct 2002
Process the Capture events, call DSP routines, and output to Secondary Play Buffer
Private Sub DirectXEvent8_DXCallback (ByVal eventid As Long)
StartTimer
With dsb
Reference DirectSoundBuffer
.GetCurrentPosition PlyCurs
If true the write is overlapping the lWrite cursor due to processor loading
If PlyCurs.lWrite >= StartAddr _
And PlyCurs.lWrite <= EndAddr Then
FirstPass = True
Restart play buffer
OutPtr = 0
StartAddr = 0
End If
If true the write is overlapping the lPlay cursor due to processor loading
If PlyCurs.lPlay >= StartAddr _
And PlyCurs.lPlay <= EndAddr Then
FirstPass = True
Restart play buffer
OutPtr = 0
StartAddr = 0
End If
Write outBuffer to DirectX circular Secondary Buffer. NOTE: writing inBuffer causes
direct pass through. Replace
with outBuffer below to when using DSP subroutine for modulation/demodulation
.WriteBuffer StartAddr, CaptureBytes, inBuffer(0), DSBLOCK_DEFAULT
OutPtr = IIf(OutPtr >= 3, 0, OutPtr + 1)
If FirstPass = True Then
Pass = Pass + 1
If Pass = 3 Then
FirstPass = False
Pass = 0
.SetCurrentPosition 0
.Play DSBPLAY_LOOPING
End If
End If
Counts 0 to 3
End With
StopTimer
End Sub
Fig 10Process the DirectXEvent8 event. Note that the example code passes the inBuffer() directly to the DirectSoundBuffer
without processing. The DSP subroutine call has been commented out for this illustration so that the audio input to the sound
card will be passed directly to the audio output with a 185 ms delay. Destroy objects and events on exit.
Sept/Oct 2002 17
Fig 11Code for parsing the stereo inBuffer() into in-phase and quadrature signals. This code must be imbedded into the DSP
subroutine.
18 Sept/Oct 2002
3You
A Software-Defined Radio
for the Masses, Part 3
Learn how to use DSP to make the PC sound-card interface
from Part 2 into a functional software-defined radio.
We also explore a powerful filtering technique
called FFT fast-convolution filtering.
By Gerald Youngblood, AC5OG
8900 Marybank Dr
Austin, TX 78750
[email protected]
Nov/Dec 2002 27
DSP code receives the captured signal and then outputs the processed
signal data.
This article extends the sound-card
interface to a functional SDR receiver
demonstration. To accomplish this, the
following functions are implemented
in software:
Split the stereo sound buffers into I
and Q channels.
order As Long
filterM(NFFT) As Double
filterP(NFFT) As Double
RealIn(NFFT) As Double
RealOut(NFFT) As Double
ImagIn(NFFT) As Double
ImagOut(NFFT) As Double
Private
Private
Private
Private
Public
Public
Public
Public
Public
Public
Public
Public
RealOut_1(NFFT)
RealOut_2(NFFT)
ImagOut_1(NFFT)
ImagOut_2(NFFT)
As
As
As
As
Double
Double
Double
Double
FHigh As Long
FLow As Long
Fl As Double
Fh As Double
SSB As Boolean
USB As Boolean
TX As Boolean
IFShift As Boolean
AGC enabled
AGC AGCHang time factor
Saves the AGC Mode selection
Save RX Hang time setting
AGC AGCHang time buffer counter
Peak filtered output signal
Gain AGCHang time buffer
Gain state setting for AGC
AGC Gain during previous input block
AGC attack time steps
AGC Gain in dB
Temp buffer to compute Gain
Maximum AGC Gain factor
Private
Private
Private
Private
FFTBins As Long
M(NFFT) As Double
P(NFFT) As Double
S As Long
28 Nov/Dec 2002
Fig 6Offset baseband IF diagram. The local oscillator is shifted by 11.025 kHz so that
the desired-signal carrier frequency is centered at an 11,025-Hz offset within the FFT
output. To shift the signal for subsequent filtering the desired bins are simply copied to
center the carrier frequency, fc, at 0 Hz.
Nov/Dec 2002 29
IFShift = True
If IFShift = True Then
For S = 0 To 1023
If USB Then
M(S) = M(S + 1024)
P(S) = P(S + 1024)
Else
M(S + 3072) = M(S + 1)
P(S + 3072) = P(S + 1)
End If
Next
End If
SSB or CW Modes
Zero out lower sideband
Fig 9FFT fast-convolution-filtering block diagram. The filter impulse-response coefficients are first converted to the frequency
domain using the FFT and stored for repeated use by the filter routine. Each signal block is transformed by the FFT and subsequently
multiplied by the filter frequency-response magnitudes. The resulting filtered signal is transformed back into the time domain using the
inverse FFT. The Overlap/Add routine corrects the signal for circular convolution.
30 Nov/Dec 2002
(bin 0), as shown in Fig 4. Fig 10 illustrates the process of FFT convolution
of a transformed filter impulse response with a transformed input signal. Once the signal is transformed
back to the time domain by the inverse
FFT, we must then perform a process
called the overlap/add method. This
is because the process of convolution
produces an output signal that is
FFT Fast-Convolution
Filtering Magic
Fig 10FFT fast convolution filtering output. When the filter-magnitude coefficients are
multiplied by the signal-bin values, the resulting output bins contain values only within
the pass-band of the filter.
Public
Static
Static
Static
Static
Erase Ih
Fh = FHigh / Fs
Fl = FLow / Fs
BinSize = Fs / NFFT
order = NFFT
Dim O As Long
For O = 1 To 16
order = order \ 2
If order = 1 Then
order = O
Exit For
End If
Next
Fig 11Code for the generating bandpass filter coefficients in the frequency domain.
Nov/Dec 2002 31
equal in length to the sum of the input samples plus the filter taps minus one. I will not attempt to explain
the concept here because it is best described in the references.13
Fig 11 provides the source code for
producing the frequency-domain
band-pass filter coefficients. The
CalcFilter subroutine is passed the
low-frequency cutoff, FLow, and the
high-frequency cutoff, FHigh, for the
filter response. The cutoff frequencies
are then converted to their respective
fractions of the sampling rate for use
by the filter-generation routine,
nspdFirBandpass. The FFT order is
also determined in this subroutine,
based on the size of the FFT, NFFT.
The nspdFirBandpass computes the
impulse response of the band-pass filter of bandwidth Fl() to Fh() and a
length of FILTERTAPS. It then places
the result in the array variable Rh().
The NSP_WinBlackmanOpt causes
the impulse response to be windowed
by a Blackman window function. For
a discussion of windowing, refer to the
DSP Guide.14 The value of 1 that is
passed to the routine causes the result to be normalized.
Next, the impulse response is converted to the frequency domain by
nspzrFftNip. The input parameters
are Rh(), the real part of the impulse
response, and Ih(), the imaginary part
that has been set to zero. NSP_Forw
tells the routine to perform the forward FFT. We next convert the frequency-domain result of the FFT, reH()
and imH(), to polar form using the
nspdbrCartToPolar routine. The filter
magnitudes, filterM(), and filter phase,
filterP(), are stored for use in the FFT
fast convolution filter. Other than
when we manually change the bandpass filter selection, the filter response
does not change. This means that we
only have to calculate the filter response once when the filter is first selected by the user.
Fig 12 provides the code for an FFT
fast-convolution filter. Using the
nspdbMpy2 routine, the signal-spectrum magnitude bins, M(), are multiplied by the filter frequency-response
magnitude bins, filterM(), to generate
the resulting in-place filtered magnitude-response bins, M(). We then use
nspdbAdd2 to add the signal phase
bins, P(), to the filter phase bins,
filterP(), with the result stored inplace in the filtered phase-response
bins, P(). Notice that FFT convolution
can also be performed in Cartesian
coordinates using the method shown
in Fig 13, although this method requires more computational resources.
Other uses of the frequency-domain
magnitude values include FFT aver-
32 Nov/Dec 2002
bandwidth noise input and FFT averaging of the signal over several seconds. This provides a good picture of
the frequency response and shape of
Fig 13Alternate FFT fast convolution filtering code using cartesian vectors.
Fig 14Actual 500-Hz CW filter pass-band display. FFT fast-convolution filtering is used
with 2048 filter taps to produce a 1.05 shape factor from 3 dB to 60 dB down and over
120 dB of stop-band attenuation just 250 Hz beyond the 3 dB points.
the filter. The shape factor of the 2048tap filter is 1.05 from the 3-dB to the
60-dB points (most manufacturers
measure from 6 dB to 60 dB, a more
lenient specification). Notice that the
stop-band attenuation is greater than
120 dB at roughly 250 Hz from the
3-dB points. This is truly a brick-wall
filter!
An interesting fact about this
method is that the window is applied
to the filter impulse response rather
than the input signal. The filter response is normalized so signals within
the passband are not attenuated in the
frequency domain. I believe that this
normalization of the filter response
removes the usual attenuation asso-
ciated with windowing the signal before performing the FFT. To overcome
such windowing attenuation, it is typical to apply a 50-75% overlap in the
time-domain sampling process and
average the FFTs in the frequency
domain. I would appreciate comments
from knowledgeable readers on this
hypothesis.
The IFFT and Overlap/Add
Conversion Back to the Time
Domain
The digital AGC code in Fig 16 provides fast-attack and -decay gain
End If
Fig 16 Digital AGC code.
Nov/Dec 2002 33
34 Nov/Dec 2002
The final step is to format the processed signal for output to the DAC.
When receiving, the RealOut() signal
is copied, sample by sample, into both
the left and right channels. For
transmiting, RealOut() is copied to the
right channel and ImagOut() is copied to the left channel of the DAC. If
binaural receiving is desired, the I and
Q signal can optionally be sent to the
right and left channels respectively,
just as in the transmit mode.
Controlling the
Demonstration Code
End Sub
Private Sub cmdFilter_Click(Index As Integer)
Select Case Index
Case 0
CalcFilter 300, 3000
Case 1
CalcFilter 500, 1000
Case 2
CalcFilter 700, 800
End Select
2.7KHz Filter
500Hz Filter
100Hz Filter
End Sub
Private Sub cmdMode_Click(Index As Integer)
Select Case Index
Case 0
SSB
USB
Case 1
SSB
USB
End Select
End Sub
Fig 18 Control code for the demonstration front panel.
Nov/Dec 2002 35
36 Nov/Dec 2002
8R.
1Notes
20 Mar/Apr 2003
ity of SDR hardware on which to experiment. A significant advance toward this end has been seen in the
pages of QEX over the last year, and
it continues into 2003.
This series began in Part 1 with a
general description of digital signal
processing (DSP) in SDRs.3 Part 2 described Visual Basic source code to
implement a full-duplex, quadrature
interface on a PC sound card.4 Part 3
described the use of DSP to make the
PC sound-card interface into a functional software-defined radio.5 It also
explored the filtering technique called
FFT fast-convolution filtering. In this
final article, I will describe the SDR1000 transceiver hardware including
an analysis of gain distribution, noise
figure and dynamic range. There is
also a discussion of frequency control
using the AD9854 quadrature DDS.
0-60 MHz
1 Hz
200 MHz, <1 ps RMS jitter
+6 dBm
44 kHz-192 kHz (depends on PC sound card)
1 W PEP
PC parallel port (DB-25 connector)
7 open-collector Darlington outputs
PTT, Code Key, 2 Spare TTL Inputs
Line in, Line out, Microphone in
13.8 V dc
Frequency Acceptable
(MHz)
NF (dB)
1.8
45
3.5
37
4.0
27
14.0
24
21.0
20
28.0
15
50.0
9
144.0
2
Mar/Apr 2003 21
22 Mar/Apr 2003
Fig 2QS4A210
insertion loss
versus frequency
Frequency
(MHz)
28
50
144
220
432
Mar/Apr 2003 23
(Eq 1)
n Rant CS
24 Mar/Apr 2003
Gain (dB)
20
7.5
40
1.8
60
1.0
en
nV/ Hz
nV/ Hz
nV/ Hz
in
0.8 pA/ Hz
0.8 pA/ Hz
0.8 pA/ Hz
NF (dB)
12.4
3.0
1.3
N 0q
Vpp
b
2
W/Hz
=
6 fs R
(Eq 2)
where
VP-P= peak-to-peak voltage range
b = number of valid bits of resolution
fs = A/D converter sampling rate
R = input resistance
N0q = quantizing noise density
(Eq 3)
For a 16-bit A/D converter having
a maximum signal level (without input attenuation) of 12.8 VP-P, the minimum quantum level is 70.2 dBm.
Once the quantizing level is known,
we can compute the minimum gain required from Eq 4:
Gain = quantizing level kTB + analog NF
(Eq 4)
+ atmospheric NF 10 log BW
10
where:
V 0.707 2
pp
2b 2
quantizing = 10 log
dBm
10
level
50 0.001
Mar/Apr 2003 25
Table 5 Cascaded Noise Figure and Gain Analysis from the SDR-1000 Level Analysis Spreadsheet
dB
dB
Equivalent Power Factor
Equivalent Power Factor
Clipping Level
Clipping Level
Cascaded Gain
Cascaded Noise Factor
Cascaded Noise Figure
Output Noise
Noise Figure
Gain
Noise Factor
Gain
Vpk
dBm
dB
dB
dBm/Hz
BPF
0.0
0.0
1.00
1
T1-4
0.0
6.0
1.00
4
0.0
1.00
0.0
174.0
6.0
1.00
0.0
174.0
PI5V331
0.0
0.0
1.00
1
1.0
10.0
6.0
1.00
0.0
174.0
INA163
3.0
40.0
1.99
10,000
13.0
32.3
46.0
1.25
1.0
173.0
ADC
58.6
0.0
720,482
1
6.4
26.1
46.0
19.06
12.8
161.2
Band (Meters)
26 Mar/Apr 2003
160
80
40
30
20
17
15
12
10
6
Ext Noise
(dBm/Hz)
128
136
144
146
146
152
152
154
156
162
Ext NF
(dB)
46
38
30
28
28
22
22
20
18
12
9
10 Meters
1
18 dB
16 bits (98.1 dB)
6.4 V-peak (26.1 dBm)
70.2 dBm
7.2 dB
44.1 kHz
40.0 kHz
0.5 kHz
13.7 dBm
0.5 V peak (4.0 dBm)
51.4 dBm
60.0 dB
86.0
76.0
66.0
56.0
46.0
36.0
26.0
16.0
9.4
9.4
9.4
9.4
9.4
9.4
6.0
4.0
14.0
0.9
9.1
19.1
29.1
39.1
49.1
59.1
69.1
78.2
82.2
82.9
83.0
83.0
83.0
86.4
96.4
106.4
82.0
72.0
62.0
52.0
42.0
32.0
22.0
12.0
5.4
5.4
5.4
5.4
5.4
5.4
2.0
8.0
18.0
128
118
108
98
88
78
68
58
48
38
28
18
8
2
12
22
32
82
72
62
52
42
32
22
12
2
8
18
28
38
48
58
68
78
6
16
26
36
46
46.0
46.0
46.0
46.0
46.0
46.0
46.0
46.0
42.7
32.7
22.7
12.7
2.7
7.3
14.0
14.0
14.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
0.0
3.3
13.3
23.3
33.3
43.3
53.3
60.0
60.0
60.0
63.0
63.0
63.0
63.0
63.0
63.0
63.0
63.0
66.4
76.4
86.4
96.4
106.4
116.4
123.0
123.0
123.0
82.0
82.0
82.0
82.0
82.0
82.0
82.0
82.0
85.4
95.4
105.4
115.4
125.4
135.4
142.0
142.0
142.0
88.4
88.4
88.4
88.4
88.4
88.4
88.4
88.4
88.4
88.4
88.4
88.4
88.4
88.4
88.4
88.4
88.4
81.1
81.1
81.1
81.1
81.1
81.1
81.1
81.1
83.6
87.6
88.3
88.4
88.4
88.4
88.4
88.4
88.4
Digital
Gain
Required
(dB)
Output
S/N Ratio
in BW2
(dB)
Total
Noise
in BW2
(dBm)
Quantizing
Noise of
A/D in BW2
(dBm)
Noise in
A/D Input
in BW2
(dBm)
A/D
Signal
Level
(dBm)
Noise at
A/D Input
in BW1
(dBm)
Sound Card
AGC
Reduction
(dB)
Total
Analog
Gain
(dB)
Antenna
Overload
Level
(dBm)
Antenna INA
Signal
Output
Level
Level
(dBm)
(dBm)
Table 8SDR-1000 Level Analysis Detail for the 10-Meter Band with 40dB of INA Gain
Mar/Apr 2003 27
the 2.5-MHz filter has a low-pass characteristic; the rest are band-pass filters.
SDR-1000 Board Layout
For the final PC-board layout, I decided on a 34-inch form factor. The
receiver, exciter and DDS are located
on one board. The band-pass filter and
a 1-W driver amplifier are located on
a second board. The third board has a
PC parallel-port interface for control,
and power regulators for operation
from a 13.8-V dc power source. The
three boards sandwich together into
a small 342-inch module with rearmount connectors and no interconnection wiring required. The boards use
primarily surface-mount components,
except for the band-pass filter, which
uses mostly through-hole components.
Acknowledgments
I would like to thank David Brandon and Pascal Nelson of Analog Devices for their answering my questions
about the AD9854 DDS. My appreciation also goes to Mike Pendley,
WA5VTV, for his assistance in design
of the band-pass filters as well as his
ongoing advice.
Conclusion
28 Mar/Apr 2003
Mar/Apr 2003 29
30 Mar/Apr 2003
17R.
!!
Mar/Apr 2003 31