Cmp; Ny-Series Instructions Reference Manual (W560 - Omron NY532-5400 Reference Manual

Ny-series
Hide thumbs Also See for NY532-5400:
Table of Contents

Advertisement

Cmp

The Cmp instruction compares two values.
Instruction
Cmp
Compare
Variables
Name
Meaning
In1 and In2
Comparison
data
Out
Return value
OutEQ
Equal flag
OutGT
Greater than
flag
OutGE
Greater than or
equal flag
OutNE
Not equal flag
OutLT
Less than flag
OutLE
Less than or
equal flag
* If you omit the input parameter, the default value is not applied. A building error will occur.
Bit strings
In1 and In2
Out
OK
OutEQ
OK
OutGT
OK
OutGE
OK
OutNE
OK
OutLT
OK
OutLE
OK

NY-series Instructions Reference Manual (W560)

Name
FB/FUN
FUN
I/O
Description
Input
Values to compare
Always TRUE
Equal flag
Greater than flag
Greater than or equal flag
Output
Not equal flag
Less than flag
Less than or equal flag
OK OK OK OK OK OK OK OK OK OK
Graphic expression
(@)Cmp
EN
ENO
In1
Out
In2
OutEQ
OutGT
OutGE
OutNE
OutLT
OutLE
Valid range
Depends on data type.
TRUE only
Depends on data type.
Integers
2 Instruction Descriptions
ST expression
Out:=Cmp(In1, In2, OutEQ,
OutGT, OutGE, OutNE,
OutLT, OutLE);
You can omit Out.
Unit
Default
---
*
---
---
Times, durations,
dates, and text strings
2
2-107

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents