App - 137
Appendix 5 Method of replacing High Performance model QCPU with Universal model QCPU
APPENDICES
(5) Replacement example of the KEY instruction
A replacement example of program using the KEY instruction is shown below.
(a) Example of device assignment
If the device numbers in the example above are used for other applications,
assign unused device numbers instead.
(b) Program before replacement
TableApp.70 Example of device assignment
Before replacement After replacement
Application Device Application Device
Numeric input execution
instruction
M0
Numeric input execution
instruction
M0
Input complete flag M1 Input complete flag M1
Input data area D200 to D203 Input data area D200 to D203
ASCII code input signal X100 to X107 ASCII code input signal X100 to X107
Strobe signal X108 Strobe signal X108
Input data area address (BIN32) D210 to D211
(Input data area + 0) address
(BIN32)
D212 to D213
(Input data area + 1) address
(BIN32)
D214 to D215
(Input data area + 2) address
(BIN32)
D216 to D217
For shifting input data D218
For converting input data D219 to D220
Figure App.15 Sample program