Omron C200HX Computer Hardware User Manual


 
345
Using the Instruction If the input word for connecting the hexadecimal keyboard is specified at word A,
and the output word is specified at word B, then operation will proceed as shown
below when the program is executed.
0000
12345678
0000
D+1 D
0000
D+1
000F
D
9101112
0000
D+1
00F9
D
IW
16-key
0
to
9
to
D+2
00
to
09
to
15
OW
04
F
00
01
02
03
Once per 12 cycles
16-key selection
control signals
Status of 16 keys
Turn ON flags corre-
sponding to input
keys (The flags re-
main ON until the
next input.)
ON for a 12-cycle
period if a key is
pressed.
0
Flags ER: Indirectly addressed DM word is non-existent. (Content of DM word is
not BCD, or the DM area boundary has been exceeded.)
D and D+2 are not in the same data area.
SR 25408: ON while HKY(––) is being executed.
Example This example shows a program for inputting numbers from a hexadecimal key-
board. Assume that the hexadecimal keyboard is connected to IR 000 (input)
and IR 100 (output).
HKY(––)
000
100
DM1000
@XFER(70)
#0002
DM1000
DM0000
00015
25313 (Always ON)
The hexadecimal key information that is input to IR 000 by HKY(––) is converted
to hexadecimal and stored in words DM1000 and DM1001.
IR 00015 is used as an ENTER key, and when IR 00015 turns ON, the numbers
stored in DM 1000 and DM 1001 are transferred to DM 0000 and DM 0001.
Advanced I/O Instructions Section 5-28