
4.LADDER LANGUAGE B-63983EN/02
- 258 -
4.6.1 COMPB (Comparison Between Binary Data: SUB 32)
This instruction compares 1, 2, and 4-byte binary data with one
another. Results of comparison are set in the operation output register
(R9000). Sufficient number of bytes are necessary in the memory to
hold the input data and comparison data.
Format
Fig. 4.6.1 shows the ladder format and Table 4.6.1 shows the
mnemonic format.
COMPB
SUB 32
0 0
¡¡¡¡ *
¡¡¡¡ *
Format specification
Input data (address)
ddress of data to be compared
CT
Fig. 4.6.1 Format of COMPB instruction
Table 4.6.1 Mnemonic of COMPB instruction
Mnemonic format Status of operation result
Step
number
Instruction
Address
No.
Bit No. Remarks ST3 ST2 ST1 ST0
1RD ¡¡¡¡ .¡ ACT ACT
2 SUB 32 COMPB instruction
3(PRM) 00 Format specification
4(PRM) ¡¡¡¡ Input data (address)
5(PRM) ¡¡¡¡ Address of data to be compared
Control condition
(a) Command (ACT)
ACT = 0: Do not execute COMPB.
ACT = 1: Execute COMPB.