FX Series Programmable Controlers Applied Instructions 5
5-135
5.10.1 ECMP (FNC 110)
Operation:
The data of S
1 is compared to the data of S2.The
result is indicated by 3 bit devices specified with
the head address entered as D. The bit devices
indicate:
S
2 is less than < S1 - bit device D is ON
S
2 is equal to = S1 -bitdeviceD+1 is ON
S
2 is greater than > S1 - bit device D+2 is ON
Mnemonic Function
Operands
Program steps
S
1 S2 D
ECMP
FNC 110
(Floating
Point
Compare)
Compares two
floating point
values - results of
<, = and > are
given
K, H - integer value automati-
cally converted to floating point
D - must be in floating point
format (32bits).
Y, M, S
Note:
3 consecutive
devices are
used.
DECMP,
DECMPP:
13 steps
FX
1S
FX
1N
FX
2N
FX
2NC
PULSE-P
16 BIT OPERATION
32 BIT OPERATION
DECMP
M8000
M16
M17
M18
D12 D20
M16
[ S1 ] [ S2 ]
[ D ]
D20 < D12
D20 = D12
D20 > D12
Points to note:
The status of the destination devices will be kept even if the ECMP instruction is deactivated.
Full algebraic comparisons are used: i.e. -1.79 × 10
27
is smaller than 9.43 × 10
-15