Parallax Boe-Bot Student Manual page 126

Hide thumbs Also See for Boe-Bot:
Table of Contents

Advertisement

Page 112 · Robotics with the Boe-Bot
Using the DEBUGIN Command
By now, you are probably familiar with the
send messages from the BASIC Stamp to the Debug Terminal. The place the messages
are viewed is called the Receive windowpane because it's the place where messages
received from the BASIC Stamp are displayed. The Debug Terminal also has a Transmit
windowpane, which allows you to send information to your BASIC Stamp while a
program is running. You can use the
receive what you type into the Transmit windowpane and store it in one or more
variables.
The
command places the value you type in the Transmit windowpane into a
DEBUGIN
variable. In the next example program, a word variable named
to store the values the
DEBUGIN
pulseWidth
Now, the
command can be used to capture a decimal value that you enter into
DEBUGIN
the Debug Terminal's Transmit windowpane and store it in
DEBUGIN DEC pulseWidth
You can then program the BASIC Stamp to use this value. Here it is used in the
command's
PULSOUT
Duration
PULSOUT 12, pulseWidth
Example Program: TestServoSpeed.bs2
This program allows you to set the
it into the Debug Terminal's Transmit windowpane.
Continue this activity with the Boe-Bot sitting on its nose so that the wheels do
not touch the ground.
Enter, save, and run TestServoSpeed.bs2.
Point at the Debug Terminal's Transmit windowpane with your mouse, and click
it to activate the cursor in that window for typing.
Type 650 and then press the Enter key.
Verify that the servo turns full speed clockwise for six seconds.
DEBUG
command to make the BASIC Stamp
DEBUGIN
command receives.
VAR
Word
argument:
command's
PULSOUT
command and how it can be used to
pulseWidth
:
pulseWidth
argument by entering
Duration
will be used

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the Boe-Bot and is the answer not in the manual?

Questions and answers

Table of Contents

Save PDF