28123 Parallax Inc, 28123 Datasheet - Page 303

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
RETURN
Advanced Topic: Your Turn – Combining the two Programs
Now that both TerminalOperatedSensorArray.bs2 and ReusablePasswordChecker.bs2
have both been tested, the task is to combine the two. The final program should check
your password before allowing you to choose which sensor to read using the Debug
Terminal.
You will need to tab between each program while copying sections from
ReusablePasswordChecker.bs2 and pasting them into PasswordedSensorTerminal.bs2.
DEBUG CR, "Password is correct."
You
TerminalOperatedSensorArray.bs2) in the BASIC Stamp Editor.
Save TerminalOperatedSensorArray.bs2 as PasswordedSensorTerminal.bs2
Copy the
the
PasswordedSensorTerminal.bs2 just before the
Copy and paste the variable declarations from ReusablePasswordChecker.bs2
into PasswordedSensorTerminal.bs2. These variable declarations are added to
the ones in PasswordedSensorTerminal.bs2, so don’t worry about copying and
pasting the commented
Copy the
ReusablePasswordChecker.bs2, and paste it between the
and the
Copy the entire
paste it after the end of the last subroutine in PasswordedSensorTerminal.bs2.
Test PasswordedSensorTerminal.bs2, and see if it works, debug as needed.
can
Main Routine
dashed
Initialization
Password DATA
open
Subroutine
line)
both
Variables
in PasswordedSensorTerminal.bs2.
programs
directive (including the commented heading with
section (including the commented heading) from
from
section from ReusablePasswordChecker.bs2 and
heading.
ReusablePasswordChecker.bs2
' Program can move on when
' password is correct.
' Return when pass is correct.
(ReusablePasswordChecker.bs2
I/O Definitions
Variables
section.
section
into
and

Related parts for 28123