28123 Parallax Inc, 28123 Datasheet - Page 140

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
Programming Pushbutton Servo Control
Pushbutton servo control is not much different from pushbutton LED control.
code blocks are used to check the pushbutton states and either add or subtract from a
variable called
argument. If one of the pushbuttons is pressed, the value of
other pushbutton is pressed, the value of
statement is used to decide if the
too small (smaller than 500).
White
Black
Red
P15
P14
P13
P12
P11
P10
P9
P8
P7
P6
P5
P4
P3
P2
P1
P0
X2
X3
Test the pushbutton connected to P3 using the original version of
ReadPushbuttonState.bs2.
instructions on how to use it begins on page 77.
Modify the program so that it reads P4.
Run the modified program to test the pushbutton connected to P4.
Vdd
duration
15
14
X4
Vin
13 12
. This variable is used in the
X5
+
Vss
Red
Black
duration
The section that has this program and the
duration
variable is too large (greater than 1000) or
www.parallax.com
standard servo
PULSOUT
decreases. A nested
duration
command’s
Figure 4-23
Board of Education
Rev B Servo
Circuit with
Pushbutton Circuits
Added
increases. If the
Duration
IF…THEN
IF…THEN

Related parts for 28123