EasyManuals Logo

Parallax Boe-Bot User Manual

Parallax Boe-Bot
360 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #274 background imageLoading...
Page #274 background image
Page 260 · Robotics with the Boe-Bot
pulseCount VAR Byte
The IF…THEN statements now set the value of pulseCount as well as the values of
pulseRight and pulseLeft. If both detectors can see the table, take one cautious pulse
forward.
IF (irDetectLeft = 0) AND (irDetectRight = 0) THEN
pulseCount = 1
pulseLeft = 850
pulseRight = 650
Else, if the right IR detector does not see the tabletop, rotate left 10 pulses.
ELSEIF (irDetectRight = 1) THEN
pulseCount = 10
pulseLeft = 650
pulseRight = 650
Else, if the left IR detector does not see the tabletop, rotate right 10 pulses.
ELSEIF (irDetectLeft = 1) THEN
pulseCount = 10
pulseLeft = 850
pulseRight = 850
Else, if neither detector can see the table top, back up 15 pulses and try again, hoping that
one of the detectors will see the drop-off before the other.
ELSE
pulseCount = 15
pulseLeft = 650
pulseRight = 850
ENDIF
Now that the value of pulseCount, pulseLeft, and pulseRight are set, this FOR…NEXT
loop delivers the specified number of pulses for the maneuver determined by the
pulseLeft and pulseRight variable.
FOR loopCount = 1 TO pulseCount
PULSOUT 13,pulseLeft
PULSOUT 12,pulseRight
PAUSE 20

Table of Contents

Other manuals for Parallax Boe-Bot

Questions and Answers:

Question and Answer IconNeed help?

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

Parallax Boe-Bot Specifications

General IconGeneral
BrandParallax
ModelBoe-Bot
CategoryRobotics
LanguageEnglish