Parallax Boe-Bot Student Manual page 53

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

Advertisement

Solutions
Q1. The BASIC Stamp 2 microcontroller module.
Q2. Binary numbers.
Q3. The Debug Terminal.
Q4.
and
.
DEBUG
END
E1.
– This command is used to send a message from the BASIC Stamp to the
DEBUG
PC. The information is displayed on the Debug Terminal.
– This command is used to terminate a PBASIC program and put the BASIC
END
Stamp module into low-power mode.
E2. The asterisk multiplies the two operands 7 and 11, resulting in a product of 77.
The asterisk is the multiply operator.
E3. To fix the problem, add a carriage return, the
DEBUG DEC 7 * 11
DEBUG CR, DEC 7 + 11
P1. Here is a program to display a solution to the math problem:
' Robotics with the Boe-Bot - HelloBoeBotCh01Project01.bs2
' Adds together 4 numbers with DEBUG
'{$STAMP BS2}
'{$PBASIC 2.5}
DEBUG "What's 1+2+3+4?"
DEBUG CR, "The answer is: "
DEBUG DEC 1+2+3+4
END
P2. Prediction: It will print the character "M". This program tests this prediction:
' Robotics with the Boe-Bot - HelloBoeBotCh01Project02.bs2
' Prints ASCII 7 * 11
' {$STAMP BS2}
' {$PBASIC 2.5}
DEBUG
7 * 11
END
Chapter 1: Your Boe-Bot's Brain · Page 39
control character.
CR

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