Omron CJ - REFERENCE MANUAL 10-2009 Reference Manual page 85

Table of Contents

Advertisement

Instruction
Symbol/Operand
Mnemonic
Code
DOUBLE
CPSL(115)
SIGNED BINARY
COMPARE
CPSL
115
S
1
: Comparison
data 1
S
2
: Comparison
data 2
MULTIPLE COM-
PARE
MCMP(019)
MCMP
@MCMP
019
S
1
: 1st word of
set 1
S
2
: 1st word of
set 2
R: Result word
TABLE COM-
TCMP(085)
PARE
TCMP
@TCMP
085
S: Source data
T: 1st word of
table
R: Result word
UNSIGNED
BCMP(068)
BLOCK COM-
PARE
BCMP
@BCMP
068
S: Source data
T: 1st word of
table
R: Result word
EXPANDED
BCMP2(502)
BLOCK COM-
PARE
BCMP2
@BCMP2
502
(CS1-H, CJ1-H, or
CS1D CPU Unit
S: Source data
Ver. 2.0 or later
T: 1st word of
and CJ2 CPU
block
Units only)
R: Result word
CJ1M CPU Unit
(Pre-Ver. 2.0 or
Unit Ver. 2.0 or
later)
CS/CJ/NSJ Series Instructions Reference Manual (W474)
Compares two double signed binary values (constants and/or the
contents of specified words) and outputs the result to the Arithmetic
Flags in the Auxiliary Area.
S
1
S
2
S1+1
Compares 16 consecutive words with another 16 consecutive words
and turns ON the corresponding bit in the result word where the
contents of the words are not equal.
S
1
Comparison
S
2
R
Compares the source data to the contents of 16 words and turns
ON the corresponding bit in the result word when the contents are
S
equal.
Comparison
T
R
Compares the source data to 16 ranges (defined by 16 lower limits
and 16 upper limits) and turns ON the corresponding bit in the result
word when the source data is within the range.
S
T
R
T
T+2
Source data
S
T+28
T+30
Compares the source data to up to 256 ranges (defined by upper and
lower limits) and turns ON the corresponding bit in the result word when
the source data is within a range.
S
T
T
R
T+1
T+3
Source data
S
T+2N+1
Range N A
Note: A can be less than
or equal to B or
greater the B.
Function
Signed binary
comparison
S2+1
Arithmetic Flags
(>, >=, =, <=, <, <>)
R
R
Ranges
Lower limit
Upper limit
to
T+1
to
T+3
to
T+29
to
T+31
1: In range
0: Not in range
N
n=255 max.
D
Bit
T+2
0
Range 0 A
Range 0 B
T+4
1
Range 1 A
Range 1 B
D+15 max.
T+2N+2
Range N B
2. Summary of Instructions
Location
Execution
condition
Output
Required
Output
Required
0: Words
are equal.
1: Words
aren't
equal.
Output
Required
1: Data are
equal.
0: Data aren't
equal.
Output
Required
1: In range
0: Not in range
R
0
1
14
15
Output
Required
Page
260
263
2
265
267
269
47

Advertisement

Table of Contents
loading

Table of Contents