Download Print this page

HP 82153A Owner's Manual page 12

Wand

Advertisement

Example: A game of checkers using the wand could employ the following short program to convert wand inputs into displayed
coordinates of positions on the board.
SQR
LBL
0
FIX
29
CF
WNDSCN
01
RCL
10
÷
INT
ROW
ALPHA
SPACE ALPHA
X
ARCL
01
RCL
10
MOD
ALPHA APPEND
, SPACE
COL
SPACE
ALPHA
X
ALPHA
AVIEW
4
FIX
29
SF
RTN
Load and execute the program using the following bar code. Then scan the bar code in a square of the checkerboard illustration on the
next page and view the corresponding square identification in the HP-41C's display. (The bar code row in each square consists of the
binary equivalent of a two-digit decimal number that identifies the square by row and column.) The above program could be modified
to make the data from the squares available for other operations as well.
ROW 1 (1 – 4)
Display
W: RDY 02
ROW 2 (5 – 11)
Display
W: RDY 03
ROW 3 (12 – 15)
Display
W: RDY 04
ROW 4 (16 – 20)
Display
W: WORKING
, then
HP 82153A - Wand Owner Manual - page 14
Converts the single byte of binary bar code data for the square that was scanned into decimal data
and stores the converted data in R
Identifies the square's row number and places it in the ALPHA register with a
Identifies the square's column number and appends it with a
ALPHA register.
Displays the decimal coordinates of the selected square.
PROGRAM REGISTERS NEEDED: 7
0.0000
. (Assumes a
4
FIX
01
display that was cleared before the program was scanned.)
label.
ROW
label, to the row data in the
COL

Advertisement

loading