|
Part 2: The Rest of the Story
by Dan Cross-Cole
Start ý All
the Pieces ý Using the DSP/FFT System
ý Sources and PDF
ALL THE PIECES
In the sampling circuitry, the audio
input should be fed through a capacitor to block any DC component
from the signal source (see Figure 1). The DSP board provides the
necessary isolation, but other inputs may not.
|
|
| Figure 1ýThe DSP/FFT system
uses the DSP board to provide different audio band-pass filters.
The amplifier shifts the filtered AC signals to the 0- to 5-VDC
range. The ADC board digitizes the audio and sends the data
to the PIA board, which plugs into the ISA bus of the docking
station. The laptop then uses the FFT program to display the
frequency components. |
Besides multiplying the signal by 10,
the amplifier adds 2.5 V to the signal, allowing an AC signal of 0.5
V (peak to peak) to just span the 0- to 5-V range of the analog-to-digital
converter (ADC) (see Figure 2).
 |
| Figure 2ýThe amplifier adds
2.5 V to the AC signal from the DSP board and provides a voltage
gain of 10. The output ranges between 0 and 5 VDC. |
The ADC board uses a commercial 1-MHz
oscillator module (see Figure 3). A 25-wire ribbon cable connects
the ADC to the peripheral interface adapter (PIA) circuit. Seasoned
readers will recognize this circuit from my book, 26 Hardware Projects
for the Home Computer.
 |
| Figure 3ýThe ADC conversion
board is connected to the DB-25 connector on the PIA board by
a ribbon cable. |
The PIA board is designed for an ISA
bus (see Figure 4). The PIA chip provides eight input bits, eight
output bits, one read/write signal, and seven control bits. For this
application, you only need the eight input (data) bits and three control
bits. These bits are controlled by the QuickBASIC FFT program.
|
|
Figure 4ýThe DB-25 connector
allows ribbon cables to connect to different devices (in this
case, the ADC board). |
The FFT program takes samples, calculates
the Fourier Coefficients, and then displays only the constants up
to about 1.5 kHz (see
Listing 1). Note that the program
is designed to interface to the hardwired ports on the PIA board.
If you choose to set up the ports differently on the PIA board, youýll
need to change the program.
The program also does a host of other
useful things. It sets up the PIA automatically, but you can manually
change the settings. To set up the FFT routine, type "F",
hit the enter key, and you should see the display appear. Fluent programmers
will discover that only a fraction of the total data available is
displayed.
PREVIOUS
NEXT
Circuit Cellar provides up-to-date information for engineers. Visit
www.circuitcellar.com for
more information and additional articles.
For subscription information, call (860) 875-2199, subscribe@circuitcellar.com
or subscribe online.
ýCircuit Cellar, the Magazine for Computer Applications. Posted with
permission. |