Parallax Boe-Bot Student Manual page 278

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

Advertisement

Page 264 · Robotics with the Boe-Bot
Solutions
Q1. 38.5 kHz is the frequency of the harmonic. Its fundamental frequency = 65536 –
38500 = 27036 Hz. The signals are sent for 1 millisecond, and the IR LED must
be connected to I/O Pin 2.
Q2. The command which stores the detector's output in a variable. For example,
irDetectLeft = IN9.
Q3. A low signal means IR at 38.5 kHz was detected, thus, an object was detected.
A high signal means no IR at 38.5kHz was detected, so, no object.
Q4. Electrically speaking, for both red and infrared LEDs, a smaller resistor will
cause the LED to glow more brightly. A bigger resistor results in dimmer LEDs.
In terms of results, brighter IR LEDs make it possible to detect objects that are
farther away.
E1. Change the
IF...THEN
IF (IN0 = 0) THEN
This will only monitor the right detector.
E2. The
pulseCount
motion depending on the situation.
P1. The FastIrRoaming.bs2 program can be combined with a
does nothing until it detects an object. A sample solution is shown below.
' -----[ Title ]-------------------------------------------------------
' Robotics with the Boe-Bot - MotionActivatedBoeBot.bs2
' Boe-Bot starts roaming when hand is waved in front of IR detectors.
' {$STAMP BS2}
' {$PBASIC 2.5}
' -----[ Variables ]---------------------------------------------------
irDetectLeft
irDetectRight
pulseLeft
pulseRight
' -----[ Initialization ]----------------------------------------------
DEBUG "Program Running!"
FREQOUT 4, 2000, 3000
start/reset.
to read:
variable allows the Boe-Bot to have adjustable distance of
VAR
Bit
VAR
Bit
VAR
Word
VAR
Word
loop that
DO...UNTIL
' Variable Declarations
' Signal program

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

Subscribe to Our Youtube Channel

Table of Contents

Save PDF