28123 Parallax Inc, 28123 Datasheet - Page 189

TEXT WHAT'S A MICROCONTROLLER

28123

Manufacturer Part Number
28123
Description
TEXT WHAT'S A MICROCONTROLLER
Manufacturer
Parallax Inc
Type
Programmingr
Datasheet

Specifications of 28123

Style
Book
Title
What's a Microcontroller?
Contents
Whats a Microcontroller? Text
Product
Microcontroller Accessories
Core Processor
PIC16C57c
Flash
128 Bytes
Operating Supply Voltage
9 V
Board Size
31 mm x 16 mm
Lead Free Status / RoHS Status
Not applicable / Not applicable
NEXT
DIRH = %00000000
END
Your Turn – Displaying 0 through F Again
ACTIVITY #4: DISPLAYING THE POSITION OF A DIAL
In Chapter #5, Activity #4 you used the potentiometer to control the position of a servo.
In this activity, you will display the position of the potentiometer using the 7-segment
LED display.
Dial and Display Parts
(1) 7-segment LED display
(8) Resistors – 1 kΩ (brown-black-red)
(1) Potentiometer – 10 kΩ
(1) Resistor – 220 Ω (red-red-brown)
(1) Capacitor – 0.1 µF
(7) Jumper wires
Building the Dial and Display Circuits
Figure 6-14 shows a schematic of the potentiometer circuit that should be added to the
project. Figure 6-15 shows a wiring diagram of the circuit from Figure 6-14 combined
with the circuit from Figure 6-10 on Page 172.
DEBUG "
PAUSE 1000
Modify DisplayDigitsWithLookup.bs2 so that it counts from 0 through F in
hexadecimal. Don’t forget to update the
values.
Add the potentiometer circuit to the 7-segment LED display circuit as shown
in Figure 6-15.
", DEC2 index, "
%01110111, %11000100, %11110111, %11110110 ], OUTH
", BIN8 OUTH, CR
FOR…NEXT
loop’s
start
and
end

Related parts for 28123