Zcp/Zcpl - Omron CJ - INSTRUCTIONS Reference Manual

Table of Contents

Advertisement

3. Instructions

ZCP/ZCPL

Instruction
AREA RANGE COMPARE
DOUBLE AREA RANGE
COMPARE
Symbol
Applicable Program Areas
Function block
Area
definitions
Usage
OK
Operands
Operand
ZCP: Comparison data (one word of data)
CD
ZCPL: Comparison data (two words of data)
ZCP: Low limit
LL
ZCPL: Low limit leftmost word number
ZCP: High limit
UL
ZCPL: First word of upper limit
Operand Specifications
Area
CIO
WR
ZCP: CD, LL, UL
OK
OK
ZCPL: CD, LL, UL
Flags
Name
Error Flag
Greater Than Flag
Greater Than or Equal Flag
Equal Flag
276
Mnemonic
Variations
ZCP
---
ZCPL
---
ZCP
ZCP(088)
CD
CD: Comparison data
LL
LL: Lower limit of range
UL: Upper limit of range
UL
Block program areas
Step program areas
OK
OK
Description
Word addresses
HR
AR
T
C
DM
EM
OK
OK
OK
OK
OK
Label
P_ER
ON if LL > UL.
P_GT
• ON if CD > UL.
• OFF in all other cases.
P_GE
• CJ2H (unit version 1.0 to 1.2), CS1-H, CJ1-H,
CJ1M, or CS1D CPU Unit: Held
• CJ2H (unit version 1.3 or later) or CJ2M CPU
Unit:
• ON if CD
LL
• OFF in all other cases.
P_EQ
• ON if LL
CD
• OFF in all other cases.
Function
code
Compares a 16-bit unsigned binary value (CD)
with the range defined by lower limit LL and upper
088
limit UL. The results are output to the Arithmetic
Flags.
Compares a 32-bit unsigned binary value (CD+1,
CD) with the range defined by lower limit (LL+1,
116
LL) and upper limit (UL+1, UL). The results are
output to the Arithmetic Flags.
ZCPL(116)
Subroutines
OK
Data type
CMP
UINT
UINT
UINT
Indirect
DM/EM
Con-
addresses
stants
@DM
*DM
DR
@EM
*EM
OK
OK
OK
OK
OK
---
Operation
ZCP
ON if LL+1, LL > UL+1, UL.
• ON if CD > UL+1, UL.
• OFF in all other cases.
• CJ2H (unit version 1.0 to 1.2), CS1-H, CJ1-H,
• CJ2H (unit version 1.3 or later) or CJ2M CPU
UL.
• ON if LL+1, LL
• OFF in all other cases.
CS/CJ/NSJ Series Instructions Reference Manual (W474)
Function
ZCPL
CD
CD: First word of comparison data
LL
LL: First word of lower limit
UL: First word of upper limit
UL
SFC action or
Interrupt tasks
transition programs
OK
OK
Size
CMPL
CMP
UDINT
1
UDINT
1
UDINT
1
Registers
Flags
Pulse
Indirect
IR
TK
CF
using IR
---
OK
---
---
OK
ZCPL
CJ1M, or CS1D CPU Unit: Held
Unit:
• ON if CD+1, CD
LL+1, LL
• OFF in all other cases.
CD+1, CD
UL+1, UL.
CMPL
2
2
2
TR
bits
bits
---
---

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

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

Questions and answers

Table of Contents

Save PDF