EasyManuals Logo

Omron SYSMAC CP Series Instruction & Reference Manual

Omron SYSMAC CP Series
467 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #141 background imageLoading...
Page #141 background image
2-105
2 Instructions
CP1E CPU Unit Instructions Reference Manual(W483)
Comparison Instructions
2
ZCP/ZCPL
ZCP/ZCPL
Applicable Program Areas
Operands
Operand Specifications
Flags
Instruction Mnemonic Variations
Function
code
Function
AREA RANGE COMPARE ZCP --- 088
Compares a 16-bit unsigned binary value (CD)
with the range defined by lower limit LL and upper
limit UL. The results are output to the Arithmetic
Flags.
DOUBLE AREA RANGE
COMPARE
ZCPL --- 116
Compares a 32-bit unsigned binary value (CD+1,
CD) with the range defined by lower limit (LL+1,
LL) and upper limit (UL+1, UL). The results are
output to the Arithmetic Flags.
Symbol
ZCP ZCPL
Area Step program areas Subroutines Interrupt tasks
Usage OK OK OK
Operand Description
Data type Size
CMP CMPL CMP CMPL
CD
ZCP: Comparison data (one word of data)
ZCPL: Comparison data (two words of data)
UINT UDINT 1 2
LL
ZCP: Low limit
ZCPL: Low limit leftmost word number
UINT UDINT 1 2
UL
ZCP: High limit
ZCPL: High limit rightmost word number
UINT UDINT 1 2
Area
Word addresses Indirect DM addresses
Constants CF Pulse bits TR bits
CIO WR HR AR T C DM @DM *DM
CD, LL, UL OK OK OK OK OK OK OK OK OK OK --- --- ---
Name Label
Operation
ZCP ZCPL
Error Flag P_ER ON if LL > UL. ON if LL+1, LL > UL+1, UL.
Greater Than Flag P_GT ON if CD > UL.
OFF in all other cases.
ON if CD > UL+1, UL.
OFF in all other cases.
Greater Than or Equal Flag P_GE Left unchanged. Left unchanged.
Equal Flag P_EQ ON if LL CD UL.
OFF in all other cases.
ON if LL+1, LL CD+1, CD UL+1, UL.
OFF in all other cases.
Not Equal Flag P_NE Left unchanged. Left unchanged.
Less Than Flag P_LT ON if CD < LL.
OFF in all other cases.
ON if CD+1, CD < LL+1, LL.
OFF in all other cases.
Less Than or Equal Flag P_LE Left unchanged. Left unchanged.
Negative Flag P_N Left unchanged. Left unchanged.
ZCP(088)
CD
LL
UL
CD: Comparison Data
LL: Lower limit of range
UL: Upper limit of range
ZCPL(116)
CD
LL
UL
CD: First word of Comparison Data
LL: First word of Lower Limit
UL: First word of Upper Limit

Table of Contents

Other manuals for Omron SYSMAC CP Series

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Omron SYSMAC CP Series and is the answer not in the manual?

Omron SYSMAC CP Series Specifications

General IconGeneral
BrandOmron
ModelSYSMAC CP Series
CategoryComputer Hardware
LanguageEnglish

Related product manuals