28122 Parallax Inc, 28122 Datasheet - Page 301
28122
Manufacturer Part Number
28122
Description
KIT WHAT'S A MICRO:PARTS ONLY
Manufacturer
Parallax Inc
Datasheet
1.28123.pdf
(340 pages)
Specifications of 28122
Accessory Type
Parts Kit
Product
Microcontroller Accessories
Core Processor
PIC16C57c
Flash
128 Bytes
Operating Supply Voltage
9 V
Board Size
31 mm x 16 mm
For Use With/related Products
Board of Education Full Kit
Lead Free Status / RoHS Status
Lead free / RoHS Compliant
- Current page: 301 of 340
- Download datasheet (6Mb)
LOOP UNTIL index = 5
DEBUG CR, "Password is correct;", CR,
END
Your Turn – Modifying Passwords
Modifying Password Checker for Use in a Larger Program
The goal is to make it easy to fit the PasswordChecker.bs2 program into the example
program from Activity #3. Two things will help. First, the password checking program
should be modified so that it does most of its work in a subroutine. The different parts of
the program should also be labeled with commented headings to help make it clear how
to combine the two programs.
Example Program: ReusablePasswordChecker.bs2
ReusablePasswordChecker.bs2 works the same as PasswordChecker.bs2, but it now uses
a subroutine to do the work, and it has been reorganized into labeled sections.
DEBUGIN STR userEntry \5
FOR index = 0 TO 4
NEXT
IF index <> 5 THEN
ENDIF
READ Password + index, temp
IF temp <> userEntry(index) THEN EXIT
DEBUG CR,"Password not correct.", CR
√
√
√
√
Modify the
password.
By changing five different values in the program, you can also modify it so
that it accepts a four character password instead of a five character password.
Verify that the program still works the same as PasswordChecker.bs2.
Examine how the
"program can continue..."
Password DATA
DO…LOOP UNTIL
directive so that it uses a different five character
code block was placed into a subroutine.
' Get user input password.
' Check array against DATA
' Get next password char
' Compare to user input,
' exit if not equal.
' If exit, then index not equal
' to 5 and pass is not correct.
' Only get out of loop when
' index = 5.
' Program can move on when
' password is correct.
Related parts for 28122
Image
Part Number
Description
Manufacturer
Datasheet
Request
R
Part Number:
Description:
Microcontroller Modules & Accessories DISCONTINUED BY PARALLAX
Manufacturer:
Parallax Inc
Part Number:
Description:
BOOK UNDERSTANDING SIGNALS
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
COMPETITION RING FOR SUMOBOT
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
TEXT INFRARED REMOTE FOR BOE-BOT
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
BOARD EXPERIMENT+LCD NX-1000
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
CONTROLLER 16SERVO MOTOR CONTROL
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
BASIC STAMP LOGIC ANALYZER
Manufacturer:
Parallax Inc
Datasheet:
Part Number:
Description:
IC MCU 2K FLASH 50MHZ SO-18
Manufacturer:
Parallax Inc
Datasheet: