28123 Parallax Inc, 28123 Datasheet - Page 143

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
SUMMARY
This chapter introduced microcontrolled motion using a servo. A servo is a device that
moves to and holds a particular position based on electronic signals it receives. These
signals take the form of pulses that last anywhere between 1 and 2 ms, and they have to
be delivered every 20 ms for the servo to maintain its position.
A programmer can use the
signals. Since pulses have to be delivered every 20 ms for the servo to hold its position,
the
can be used to store the value used in the
This causes the servo’s horn to rotate in steps.
In this chapter, a variety of ways to get the values into the variables were presented. The
variable can receive the value from your Debug Terminal using the
The value of the variable can pass through a sequence of values if the same variable is
used as the index for a
make sweeping motions.
add or subtract from the variable used in the
based on whether or not a certain button is pressed. This allows both position control and
sweeping motions depending on how the program is constructed and how the pushbuttons
are operated.
Questions
PULSOUT
1. What are the four external parts on a servo? What are they used for?
2. Is an LED circuit required to make a servo work?
3. What command controls the low time in the signal sent to a servo? What
4. What programming element can you use to control the amount of time that a
5. How do you use the Debug Terminal to send messages to the BASIC Stamp?
6. What type of code block can you write to limit the servo’s range of motion?
command controls the high time?
servo holds a particular position?
What programming command is used to make the BASIC Stamp receive
messages from the Debug Terminal?
and
PAUSE
FOR…NEXT
commands are usually placed in some kind of loop. Variables
IF…THEN
PULSOUT
loop. This technique can be used to cause the servo to
statements can be used to monitor pushbuttons and
command to make the BASIC Stamp send these
PULSOUT
PULSOUT
command’s
command’s
Duration
Duration
DEBUGIN
command.
argument.
argument

Related parts for 28123