28123 Parallax Inc, 28123 Datasheet - Page 135
![TEXT WHAT'S A MICROCONTROLLER](/photos/6/49/64955/mfg_28123_sml.jpg)
28123
Manufacturer Part Number
28123
Description
TEXT WHAT'S A MICROCONTROLLER
Manufacturer
Parallax Inc
Type
Programmingr
Datasheet
1.28123.pdf
(340 pages)
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
- Current page: 135 of 340
- Download datasheet (6Mb)
counter
this:
You can also make the servo turn the opposite direction by counting down instead of
counting up. In PBASIC,
argument is larger than the
FOR…NEXT
You can combine counting down with a
quickly in the clockwise direction like this:
The trick to getting the servo to turn at different rates is to use these
count up and down with different step sizes. The next example program uses these
techniques to make the servo’s horn rotate back and forth at different rates.
Example Program: ServoVelocities.bs2
' What's a Microcontroller - ServoVelocities.bs2
' Rotate the servo counterclockwise slowly, then clockwise rapidly.
' {$STAMP BS2}
' {$PBASIC 2.5}
counter
DO
DEBUG "Pulse width increment by 8", CR
FOR counter = 500 TO 1000 STEP 8
NEXT
PULSOUT 14, counter
PAUSE 7
DEBUG DEC5 counter, CR, CRSRUP
√
√
√
FOR counter = 500 TO 1000 STEP 8
FOR counter = 1000 TO 500
FOR counter = 1000 TO 500 STEP 20
each time through the loop (instead of 1) by modifying the
Enter and run the program.
As the program runs, watch how the value of
Terminal.
Also, watch how the servo behaves differently through the two different
FOR…NEXT
loop count from 1000 to 500:
VAR
loops. Both the servo’s direction and speed change.
Word
FOR…NEXT
EndValue
loops will also count backwards if the
argument. Here is an example of how to make a
STEP
argument to get the servo to rotate more
counter
changes in the Debug
FOR…NEXT
FOR
statement like
StartValue
loops to
Related parts for 28123
Image
Part Number
Description
Manufacturer
Datasheet
Request
R
![30008](/images/manufacturer_photos/0/5/515/parallax_inc_tmb.jpg)
Part Number:
Description:
Microcontroller Modules & Accessories DISCONTINUED BY PARALLAX
Manufacturer:
Parallax Inc
![70009](/photos/26/92/269208/70009-l_tmb.jpg)
Part Number:
Description:
BOOK UNDERSTANDING SIGNALS
Manufacturer:
Parallax Inc
Datasheet:
![27404](/photos/26/91/269197/27404-l_tmb.jpg)
Part Number:
Description:
COMPETITION RING FOR SUMOBOT
Manufacturer:
Parallax Inc
Datasheet:
![70016](/photos/8/99/89966/mfg_70016_tmb.jpg)
Part Number:
Description:
TEXT INFRARED REMOTE FOR BOE-BOT
Manufacturer:
Parallax Inc
Datasheet:
![28135](/images/manufacturer_photos/0/5/515/parallax_inc_tmb.jpg)
Part Number:
Description:
BOARD EXPERIMENT+LCD NX-1000
Manufacturer:
Parallax Inc
Datasheet:
![28023](/photos/9/30/93020/mfg_28023_tmb.jpg)
Part Number:
Description:
CONTROLLER 16SERVO MOTOR CONTROL
Manufacturer:
Parallax Inc
Datasheet:
![30010](/photos/9/30/93025/mfg_30010_tmb.jpg)
Part Number:
Description:
BASIC STAMP LOGIC ANALYZER
Manufacturer:
Parallax Inc
Datasheet:
![SX18AC/SO](/images/manufacturer_photos/0/5/515/parallax_inc_tmb.jpg)
Part Number:
Description:
IC MCU 2K FLASH 50MHZ SO-18
Manufacturer:
Parallax Inc
Datasheet: