28123 Parallax Inc, 28123 Datasheet - Page 78

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
Q8. No. The largest value a byte can hold is 255. The value 500 is out of range for a
Q9.
E1. The
E2. The
P1. The bi-color LED schematic, on the left, is unchanged from Figure 2-20 on page
byte.
HIGH 7
P13,
to be modified to count from 1 to 5000).
64. The yellow LED schematic is based on Figure 2-11 on page 48. For this
project P14 was changed to P13.
' What's a Microcontroller - Ch02Prj01_Countdown.bs2
' 10 Second Countdown with Red, Yellow, Green LED
' Red/Green:
' {$STAMP BS2}
' {$PBASIC 2.5}
DEBUG "Program Running!"
counter VAR Byte
P15
P14
counter VAR Word
FOR counter = 1 to 5000
NEXT
P13
counter
DEBUG ? counter, CR
HIGH 14
PAUSE 500
LOW 14
PAUSE 500
PAUSE Duration
HIGH 14
will cause the BASIC Stamp to internally connect I/O pin P7 to Vdd.
470 Ω
LED
Red
470
variable has to be changed to
and
Bicolor LED on P15, P14. Yellow: P13
LOW 14
1
2
Vss
must be reduced to 500ms / 4 = 125ms. To use I/O pin
have been replaced with
Green
LED
LED
P13
Word
DO
LOOP
HIGH 13
PAUSE 125
LOW 13
PAUSE 125
size, and the
HIGH 13
470
and
Vss
FOR
LOW 13
statement has
Yellow
LED
.

Related parts for 28123