Soldering a 7-Segment Display Circuit Board

advertisement
EGR 278
Digital Logic Lab
File: N278L6A2
Lab # 6
Soldering a 7-Segment Display Circuit Board
A.
Objective
Students will gain experience in the use of 7-segment displays and soldering as they solder a
small circuit board containing a 7-segment display, a 7447 driver, and the required currentlimiting resistors.
B.
Materials
Breadboard
5V Power Supply
Wire, switches, etc.
Seven 220, 270, or 330 ohm resistors
Common-anode 7-segment display (MAN72 or other)
7447 BCD-to-7-segment decoder/driver (common anode)
14 pin IC socket (provided by instructor)
16 pin IC socket (provided by instructor)
Radio Shack General-Purpose IC PC Board (Cat. No. 276-150) (provided by instructor)
Soldering equipment
Web page: “How To Solder” – ©2001 Mondotronics, Inc. 0105.10 v1.0
C.
Introduction
BCD-to-7-segment decoders
One decoder of special interest is a BCD-to-7-segment decoder. Its purpose is to decode BCD
inputs (the binary codes corresponding to the decimal values 0 - 9) in order to light the
appropriate segments on a 7-segment display. The decoder, therefore, will need 7 outputs in
order to control the 7 segments, which are labeled a through g. Diagrams of the decoder and a 7segment display are shown below.
(MSB) A
B
C
D
BCD -to7-segment
decoder
a
b
c
d
e
f
g
Figure 5: BCD to 7-segment decoder
(with active-HIGH inputs and outputs)
a
f
e
g
d
b
c
7-segment display
Page 2
The decoder should function as follows:
if ABCD = 0000, the display should light the digit 0 (segments a, b, c, d, e, f)
if ABCD = 0001, the display should light the digit 1 (segments b, c)
if ABCD = 0010, the display should light the digit 2 (segments a, b, d, e, g)
.
.
if ABCD = 1001, the display should light the digit 9 (segments a, b, c, f, g)
Note that inputs ABCD = 1010 to ABCD = 1111 correspond to illegal inputs. The designer may
wish to treat these inputs as “don’t cares” or perhaps generate a blank display or special unique
symbols.
If the illegal inputs are treated as “don’t cares”, the truth table would look as follows:
Inputs
Outputs
A
B
C
D
a
b
c
d
e
f
g
0
0
0
0
1
1
1
1
1
1
0
0
0
0
1
0
1
1
0
0
0
0
0
0
1
0
1
1
0
1
1
0
1
0
0
1
1
1
1
1
1
0
0
1
0
1
0
0
0
1
1
0
0
1
1
0
1
0
1
1
0
1
1
0
1
1
0
1
1
0
1
0
1
1
1
1
1
0
1
1
1
1
1
1
0
0
0
0
1
0
0
0
1
1
1
1
1
1
1
1
0
0
1
1
1
1
0
0
1
1
1
0
1
0
x
x
x
x
x
x
x
1
0
1
1
x
x
x
x
x
x
x
1
1
0
0
x
x
x
x
x
x
x
1
1
0
1
x
x
x
x
x
x
x
1
1
1
0
x
x
x
x
x
x
x
1
1
1
1
x
x
x
x
x
x
x
Only 2 of the 7 required K-Maps for the 7 outputs are shown below.
CD
AB 00
00 1
01
0
11
1
10
1
CD
AB 00
00 1
01
1
11
1
10
1
01
0
1
1
1
01
1
0
1
0
11
x
x
x
x
11
x
x
x
x
10
1
1
x
x
10
1
1
x
x
K-map for segment a
K-map for segment b
Page 3
The corresponding outputs are:
a = A + C + B• D + B• D
b = B + C•D + C•D
Once the expressions for all 7 outputs are obtained, the circuit can be implemented.
There are several commercially available BCD-to-7-segment decoder IC’s. The 7448 is such a
device with active-HIGH outputs. The 7447 is a similar device with active-LOW outputs. Recall
from earlier experiments that LEDs can be lit using either active-HIGH or active-LOW outputs.
Thus, there are two types of 7-segment displays: common-cathode displays which require activeHIGH outputs to light the display and common-anode displays which require active-LOW
outputs to light the display. Note that each of the 7 LEDs that make up a 7-segment display
require a current-limiting resistor. The two types of displays and decoders are illustrated below.
(MSB) A
B
C
D
7448
a
b
c
d
e
f
g
Figure 6: BCD to 7-segment decoder
(with active-HIGH and outputs)
(MSB) A
B
C
D
7447
a
b
c
d
e
f
g
Figure 7: BCD to 7-segment decoder
(with active-LOW outputs)
a
b
c
d
e
f
g
a
f
b
g
anode
e
c
d
a
Common-cathode
7-segment display
a
b
c
d
e
f
g
cathode
Typical segment
a
f
g
b
cathode
e
d
c
Common-anode
7-segment display
anode
+5V
a
Typical segment
Note that the common-cathode display has all cathodes common (tied together) to ground. Thus, a
HIGH input “forward biases” the diode and it emits light. (A diode is forward biased when a positive
voltage is placed across it from anode to cathode.) The common-anode display, on the other hand, has
all anodes common (tied together) to the supply voltage. Thus, a LOW input forward biases the diode
and it emits light.
Page 4
Soldering a general-purpose IC board
Since a 7-segment display and driver will be needed in several future experiments and may be
handy for other projects, soldering them onto a circuit board is very useful. For small projects IC
boards are commonly available. One such board is shown below.
Radio Shack General-Purpose IC PC Board (bottom view shown)
Cat. No. 276-150A
(Bottom View – copper pads)
Gnd
+5V
U1
U1
U2
U3
(Top View – white pads)
Notes:
1) The copper pads are on the bottom of the board.
Place components on the top (white pads) of the
board so that the pins extend through to the bottom of
the board (copper pads).
2) The center of the board is designed for a single row
of IC’s. The 25 rows of pins will allow for up to
three 14-pin or 16-pin IC’s (see the illustration
below).
3) The two long center runs on the board are often used
for the 5V and ground connections (see the
illustration below).
4) Two wires and/or components are soldered together
by putting them through two holes in the same copper
pad. Solder will readily adhere to the wires and the
copper pads, but will not stick to the surrounding
fiberglass board.
5) Plan your circuit board layout carefully before you
begin soldering.
6) When possible, it is a good idea to solder an IC
socket onto the board rather than the IC itself so that
the IC is not damaged by soldering and so that it can
be easily removed for testing or replacement.
7) When soldering sensitive components onto a board
such as transistors, it is a good idea to “heat sink” the
component (for example, you might connect an
alligator clip between the component and the
soldering iron to absorb the heat).
8) Read the sheet “How to Solder” for further
information.
Page 5
Soldering a 7-segment display and driver board
A circuit board with a 7-segment display and a 7447 can be constructed as follows:
Components:
• 7-segment common-anode display
• 7447
• 14-pin IC socket
• 16-pin IC socket
• Seven 220 or 270 or 330 ohm resistors
• Wire
Gnd
Inputs:
• BCD inputs labeled D, C, B, A (D = MSB)
• +5V
• Ground
+5V
Name
U1
7
U1
4
4
7
(MSB) D
C
B
(LSB) A
Note: Only 3 of the 7 resistors are
shown and most wires are not
shown.
U2
(Top View – white pads)
7-segment display
14-pin socket
7447
16-pin socket
(Side View)
Page 6
D.
Preliminary Work
1.
Generate full circuit documentation for a circuit consisting of a 7447 used to drive a
common-anode 7-segment display. Include current-limiting resistors and input switches.
2.
Carefully determine the layout for a circuit board consisting of a common-anode 7segment display, 7447, and the required current-limiting resistors. Determine the exact
placement of all components and all wires. Note that the board should have 6 clearly
labeled inputs for +5V, ground, D, C, B, and A, where D is the MSB. No connections are
necessary for LT, RBI, or RBO. Draw your final layout clearly showing exactly which
holes will be used on the board. Note: A diagram of the circuit board is available on the
following page if you would like to use it.
Check the data sheet for the 7447 to determine the function of LT, BI / RBO, RBI . Write
out a clear description of each.
3.
E.
4.
Show how to connect four 7447 IC’s (using a simple block diagram) such that leading zeros
will not be displayed (for example, the displays will show (blank)607 rather than 0607).
5.
Check the data sheet for the 7447 to determine the pattern that is lit on the 7-segment
display for each of the illegal inputs. Illustrate the results with sketches.
Laboratory Work
1.
Solder the circuit board using the layout determined in step 2 of the Preliminary Work.
2.
Test the circuit board for all 16 possible input switch combinations to verify proper
operation.
3.
Perform further tests on the circuit as follows:
a) Test the LT input. Verify that it works as expected.
b) Set RBI LOW and display a 0 on the 7-segment display. Check the value of
BI / RBO . Set RBI LOW and display a 3 on the 7-segment display. Check the value
of BI / RBO . Explain the results in your report.
c) Display a 0 on the 7-segment display. Switch the RBI input from HIGH to LOW and
note the effect. Explain the results in your report.
Radio Shack
General-Purpose IC PC Board
Cat. No. 276-150A
U1
U3
(Top View – white pads)
Download