This is only a preview of the July 1996 issue of Silicon Chip. You can view 25 of the 96 pages in the full issue, including the advertisments. For full access, purchase the issue for $10.00 or subscribe for access to the latest issues. Items relevant to "Build A VGA Digital Oscilloscope; Pt.1":
Articles in this series:
Items relevant to "Remote Control Extender For VCRs":
Items relevant to "Build A 2A SLA Battery Charger":
Items relevant to "A Three-Band Parametric Equaliser":
Articles in this series:
|
Build a
VGA digital
oscilloscope
How would you like a digital scope with a large
screen? This one is based on a VGA monitor
and displays two channels, one with a red trace
and one with a green trace. At the same time,
there is an electronically generated blue screen
graticule to make measurements easy.
PART 1: By JOHN CLARKE
Many readers would like to have an
oscilloscope but can’t quite raise the
$1000 or so you need for a fairly basic
scope these days. However, many readers do have a spare VGA monitor and
this can be pressed into useful service
with our new VGA Oscilloscope. Apart
26 Silicon Chip
from the need for a VGA monitor, it’s
a self-contained unit that doesn’t tie
up your computer.
No modifications are required to the
VGA monitor itself – it just plugs into
the VGA output on the test instrument
which we’ll call the Scope Adaptor for
convenience. When you turn both the
VGA monitor and the Scope Adaptor
on, the screen displays a large blue
graticule with seven divisions horizontally and eight verti
cally. Two
traces are also displayed, one red and
one green, for the two channel inputs.
The Scope Adaptor has knobs for
vertical sensitivity & trace position
on both channels, plus timebase and
trigger level controls. There are also
toggle switches for trigger source
selection, AC/DC coupling, timebase
magnification and a few others which
we will discuss later.
Most importantly, the Scope Adaptor has two BNC sockets for the two
channel inputs. These will accept
normal 1:1 and 10:1 scope probes.
Specifications
Bandwidth ......................................useful up to 100kHz
Timebase .......................................0.1s to 50µs per division in 11 ranges
Sensitivity .......................................10V to 50mV per division in 8 ranges
Resolution ......................................8-bit or 256 steps with 224 visible
Linearity .........................................±1 LSB
Calibration Accuracy ���������������������vertical <5%; horizontal <10% (50µs
position uncalibrated)
Input impedance .............................1MΩ
This photo shows the unit displaying
a sinewave in one channel and a
square wave in the other. Timebase
speeds range from 100ms to 50µs/
division.
Using the VGA Oscilloscope is just
like using any other scope. First, you
connect the scope probes to the circuit
to be measured and then adjust the
vertical sensitivity controls on both
channels to fill the screen.
This done, you adjust the timebase
control to give a reasonable number
of signal cycles on the screen. Finally, you adjust the vertical position
controls so that the two traces are
comfortably separated (or overlapping
if you wish).
To obtain a stable display, you will
probably need to adjust the trigger
level control and also select positive or
negative edge triggering with the Slope
switch. Or you can select between a
triggered or free-running display. As
we said above, driving the VGA Oscilloscope is little different from any
other scope – up to a point.
Where the new VGA Oscilloscope
does differ is that it also offers waveform storage, just like a digital storage
oscilloscope – and that is exactly
what it is.
It works in much the same way as
typical modern digital instruments
such as the Hewlett-Packard HP 54600
series scopes or the Tektronix TDS 300
series. It converts the incoming analog
signals into digital data and then stores
them in RAM. The digital data is then
processed in such a way as to generate
a raster display on the VGA monitor.
Mind you, this VGA Oscilloscope
does not have the extremely wide
bandwidth of the commercial oscilloscopes mentioned above; nor does
it have their price. However, it can be
used to monitor signals up to 100kHz,
making it a useful instrument for lots
of applications. And unlike the commercial scopes, it does have that large
VGA screen. To top it off, the display is
in full colour! Few commercial scopes
can boast a colour screen.
Some normal oscilloscope controls
are not provided on the Scope Adaptor. No brightness controls are provided since these are on the VGA monitor.
Focus is unnecessary since the trace
thickness is set by the circuitry.
A MAGnification control expands
the trace out by either a factor of two
or four. This feature can be useful for
high frequency signals above 20kHz
where it is difficult to see each waveform cycle in the x1 magnification.
The screen is redrawn at a rate set
by the UPDATE switch. The normal
setting redraws the trace every second
and this is seen on the screen as a
momentary trace blanking.
The other two positions of the
switch are slow and fast. These are
provided for low frequency signals and
for displaying real time audio signals
(music, speech, etc) respectively.
Waveform storage
A very useful feature of the VGA
Oscilloscope is its ability to store
a waveform and then display it indefinitely. This ena
bles viewing of
waveforms which cannot be readily
seen on a normal oscilloscope. With
the storage facility, you can capture
momentary pulses in a circuit and
view them at your leisure.
As noted above, the VGA Oscilloscope does not tie up your computer
Features
•
VGA display (no computer
required)
•
•
•
Dual trace
•
Timebase magnification (x2,
x4)
•
•
•
Free run and triggered display
•
•
•
Trigger level control
7 x 8 graticule
Calibrated timebase and volts/
division
Storage facility
Triggering on + or - slope and
Channel 1 or Channel 2
Vertical position for each trace
AC/DC/GND input coupling
July 1996 27
Fig.1: this block diagram shows the various signal processes inside the VGA
Oscilloscope.
since it directly drives the VGA
monitor. It operates best on a multisync monitor. With a standard VGA
monitor, the extreme right hand graticule line may not displayed. This is,
however, of little consequence.
Block diagram
Fig.1 shows the block diagram for
the VGA Oscilloscope. In essence,
signals for Channel 1 run along the
top of the diagram while signals for
Channel 2 run along the bottom of the
diagram. Let’s talk about Channel 1, on
the assumption that all operations will
be duplicated in Channel 2.
Channel 1 input signals are first
passed into a switchable attenuator
and amplifier (S1, S2, Q1, IC1 & IC2)
which sets the amplitude to suit the
following circuitry.
The
signals
are
then
passed to an analog-to-digital
(A-D) converter (IC3) which produc28 Silicon Chip
es 8-bit data which is then stored in
memory.
Initially, the A-D conversion operation is triggered either by the free run
oscillator which periodically retriggers the oscilloscope or by a trigger
signal from CH1 or CH2.
After each A-D conversion the new
digital value is stored in the next
memory address. The A-D conversion
rate and memory address is under the
control of the timebase oscillator (S5,
1C13, IC14, IC15) which clocks the
8-bit counter via the record switch
in IC16. This counter increments the
memory address.
256 memory locations are used to
store all the data for one screen display.
When all memory locations have been
filled, the end of count signal (IC17,
IC18) changes the chip select, read/
write block to switch the memory to
read mode. It also deselects the A-D
converter and switches IC16.
During this conversion time the
display trace is blanked. Note that
the timebase oscillator frequency
sets the rate of A-D conversions. At
fast rates, high frequencies can be
observed, while at slow conversion
rates low frequency signals are accurately traced.
If we want to store and view one
complete cycle of the input waveform,
the timebase must operate 256 times
faster than the input frequency. If the
timebase is slower than this then more
cycles will be seen. Conversely, if the
timebase is faster, then only a portion
of the full waveform will be observed.
When the memory is in the read
mode, the 8-bit counter is clocked from
the oscillator and line counter of the
VGA timebase circuit. The display/
record switch, IC16, performs this
function. This clocking rate is exactly
what is required for the memory contents to be displayed on the screen.
Screen display
In order to understand how the
information stored in memory is
displayed on the VGA screen, let us
look at Fig.2. The display on a VGA
monitor is made up of 480 horizontal
lines which are scanned by the red,
green and blue electron beams. A dot
will appear each time one of the beams
is is turned on for an instant. The respective beams are turned on by the R,
G or B signals on the VGA connector.
For simplicity, Fig.2 only shows 11
horizontal scan lines instead of 480
but you get the general picture.
The position of any dot on the screen
is dependent upon how long after the
line sync pulse the red, green or blue
gun is turned on and on what line is
being scanned at the time.
Each horizontal line begins with a
sync pulse and an entire set of lines
is preceded by a frame sync pulse.
This must be of sufficient duration for
the electron beam to return from the
bottom of the screen to the beginning
of line 1. The time to scan one line
is 32µs and to scan all 480 lines is
16.6ms. Thus, the horizontal scanning
frequency is 31.25kHz and the frame
rate is 60Hz.
This last frequency is called the
refresh rate.
Making a picture
So how do we get the dots on the
screen in order to make a picture
which means something?
We have already stated that we
have 256 memory locations which are
scanned for each line of the screen.
Each of these memory locations is
8-bits and therefore we can have a
value stored in each location which
ranges from 00000000 to 11111111;
ie, 256 values.
Let us consider that the top of the
screen corresponds to 11111111 and
the bottom of the screen is 00000000.
So as each line is scanned by the beam
of the VGA monitor, simultaneously
the 256 memory locations are being
scanned.
Now imagine that the top line is
being scanned and we come to memory
location 6 (actually address 00000101
when scanned from left to right) and
the value stored just happens to be
11111111. Yippee, we get a dot on
the screen which corresponds to that
memory location (or address).
Next, consider line 2 and we scan
across to memory location 5 and
the value stored just happens to be
11111110. Again, we get a dot at that
Fig.2: this diagram demonstrates the process of writing dots to
the screen. There are 256 bytes of memory for each channel and
each of the 256 lines on the screen corresponds to one of the
possible values stored in each memory location.
position. Further, as we scan further
across the same line we come to location 7 and the value is also 11111110.
Again, we got a dot on the screen.
Now we could go on and on with
this process and talk about all 256 lines
and 256 memory locations but you
should be starting to get the picture.
This is shown in abbreviated form in
Fig.2. This shows only 11 lines and
21 memory locations but the principle
is the same: if the value stored in a
memory location corresponds with the
line value we get a dot on the screen.
That’s the principle but how is it
done? Two magnitude comparators,
IC5 & IC6, actually compare the data
from each memory location with the
line being scanned and its screen value; ie, the screen’s 8-bit address which
comes from the line counter.
If the line value equals the data
value then a short pulse is produced
from the output of the comparator and
this is applied to the buffer (Q3, Q4 &
Q5) which drives the green gun, for
the Channel 1 trace.
Exactly the same process occurs for
Channel 2 input signals except that
they are stored in another 256 byte (8July 1996 29
Most of the componentry inside the VGA Oscilloscope adaptor is readily
available. The circuitry is mounted on three PC boards, with two small satellite
boards used to accommodate the RAM chips.
bit) memory. As the Channel 2 memory
is clocked out, its values are compared
by magnitude comparators IC11 and
IC12 and dot signals are generat
ed
for the red gun, corresponding to the
Channel 2 trace.
To recap, the analog input signals
are converted to digital data and clock
ed into memory at a rate which is set
by the timebase switch. The data is
then read out of memory at a fixed
rate, to suit the requirements of the
VGA monitor.
The remainder of Fig.1 is devoted
to the generation of VGA timebase
signals (ie, line and frame sync pulses)
and the graticule signal which drives
the blue gun.
Next month
The VGA Oscilloscope adaptor has most of the controls you would expect
to find on a conventional oscilloscope. Vertical input sensitivity ranges from
50mV/div to 10V/div.
30 Silicon Chip
So far, we’ve given you the overall
picture of how the VGA Oscilloscope
works. The circuit details are just a
teensy bit more complicated, as you
might expect. We will discuss these
next month and also publish the
SC
parts list.
|