Comparison Instructions - Omron CJ - INSTRUCTIONS REFERENCE MANUAL 07-2009 Reference Manual

Programmable controllers
Hide thumbs Also See for CJ - INSTRUCTIONS REFERENCE MANUAL 07-2009:
Table of Contents

Advertisement

Comparison Instructions

=, <>, <, <=, >, >=
Instruction
Input Comparison Instructions
Note Input comparison instructions are available to compare signed or unsigned data of one-word or double length data.
Refer to 3-15-24 Single-precision Floating-point Comparison Instructions for details on single-precision floating-point
input comparison instructions and 3-16-21 Double-precision Floating-point Input Comparison Instructions for details on
double-precision floating-point input comparison instructions.
LD connection
Mnemonic
Symbol
S
S
Applicable Program Areas
Function block
Area
definitions
Usage
OK
Operands
Operand
Description
S1
Comparison data 1
S2
Comparison data 2
Operand Specifications
Area
CIO
WR
S1
One-word
OK
OK
Data
S2
S1
Double-
OK
OK
length Data
S2
Flags
Name
Error Flag
Greater Than Flag
Greater Than or Equal Flag
CS/CJ/NSJ Series Instructions Reference Manual (W474)
Mnemonic
Variations
=, <>, <, <=, >,
---
>=
AND connection
S1: Comparison data 1
S2: Comparison data 2
1
2
Block program areas
Step program areas
OK
OK
Unsigned
double length
UINT
UINT
Word addresses
HR
AR
T
C
DM
OK
OK
OK
OK
OK
OK
OK
OK
OK
OK
Label
ER
OFF or unchanged (See note.)
>
• ON if S
> S
with one-word data.
1
2
• ON if S
+1, S
1
1
• OFF in all other cases.
> =
• ON if S
S
with one-word data.
1
2
• ON if S
+1, S
1
1
• OFF in all other cases.
Function
code
Input comparison instructions compare two values
(constants and/or the contents of specified words)
300 to 328
and create an ON execution condition when the
comparison condition is true.
=, <>, <, <=, >, >=
S1: Comparison data 1
Mnemonic
S2: Comparison data 2
S
1
S
2
Subroutines
OK
Data type
Unsigned
Signed
double length
UDINT
INT
UDINT
INT
Indirect
DM/EM
Con-
addresses
stants
@DM
*DM
EM
DR
@EM
*EM
OK
OK
OK
OK
OK
OK
OK
OK
OK
---
Operation
> S
+1, S
with double-length data.
2
2
S
+1, S
with double-length data.
2
2
3. Instructions
Function
OR connection
S1: Comparison data
Mnemonic
S2: Comparison data 2
S
1
S
2
SFC action or
Interrupt tasks
transition programs
OK
OK
Size
Signed
One-word
Double length
DINT
1
DINT
1
Registers
Pulse
TK
CF
Indirect
IR
using IR
---
OK
---
---
OK
OK
---
---
3
2
2
TR
bits
bits
---
---
---
---
249

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the CJ - INSTRUCTIONS REFERENCE MANUAL 07-2009 and is the answer not in the manual?

Questions and answers

Table of Contents