Download Print this page

Ramsey Electronics Laser Beam Communicator Manual page 6

Advertisement

for you, and also digitizes the incoming audio from the microphone with an
internal analog to digital converter and converts it to our 18kHz PWM signal.
Before we convert the audio from the microphone however, we have to first
boost the microphone's small output of only a few milivolts up to a usable
level of a few volts. This is done with U1A, a high gain stage. This stage has
a gain of 100, so a small signal of only 100uV will be amplified to a signal of
10mV. The next two stages are low pass filtering. If you compare this filter
with the one on the receiver you will see that they are the same. It is a 6kHz
sharp low-pass filter.
Why do we low-pass filter the audio before digitizing it? It is to prevent
signals more than 1/2 of the sampling rate from being digitized and then
transposed when they are received. While this may be what you want for a
voice scrambler, it is not what we want for transmitting audio. This magical
1/2 of the sampling rate is called the Nyquist frequency. Any incoming
frequency above this 1/2 point is not decoded as expected. For example, if a
10kHz signal came in and was digitized at a rate of 18kHz, we would actually
get a 1kHz signal at the output of the receiver instead of the intended 10kHz.
You can figure this out by realizing that with a Nyquist frequency of 9kHz
(our sampling rate is 18kHz), anything over the Nyquist will be seen as the
(incoming frequency - Nyquist frequency). So 10kHz - 9kHz = 1kHz.
So this may be more information than you really wanted to read, but the
Nyquist frequency is very important in many aspects of digital sound. When
you are playing MP3s on your computer, they are usually listed as having a
certain sampling rate, usually 128kHz. This means that the best frequency
response of the audio clip is 64kHz, which is pretty good. The practical
reproduction is actually more like 80% of the Nyquist. You may find some
audio files which are sampled at 32kHz, which means the highest they can
reproduce is 16kHz, this means that the 80% mark is 12kHz, which for
decent music reproduction is pretty poor. Since we are only reproducing
voice we can stay down at a sampling rate of 18kHz, so the highest we can
reproduce is 9kHz, and we filter down to 6kHz to hit that 80% mark for
decent voice audio.
Ok, so now we have filtered audio ready to sample. The microcontroller
samples the filtered audio at a rate of 18kHz, but how is it performing the
automatic gain control (AGC)? It does this by looking at the largest values of
the incoming samples, and turning pins 11, 12, and 13 into high impedance
(off) or low impedance (on) to vary the gain of U1:B, which is set up to be a
non-inverting opamp with variable gain. The gain is found by the simple
formula of Av = 1 + Rf/Ri. Rf is R20, which is a 100k reistor, and Ri can be
any combination of R17, 18, 19, and 24. With all three pins on, R18, 19, 24,
LBC6K • 6

Advertisement

loading