Справочник Пользователя для Mitsubishi Electronics MELSEC -Q/L
214
6 BASIC INSTRUCTIONS
6.1 Comparison Operation Instructions
6.1 Comparison Operation Instructions
Floating point comparisons (double precision)
EDCMP(P)
Processing details
• One of (D), (D)+1, and (D)+3 turns on depending on the results (small, match, large) after comparing the comparison value
(S1) to (S1)+3 and comparison source value (S2) to (S2)+3.
• When the contact turns OFF, "(D) to (D)+2" hold the conditions which are immediately before the contact turns ON
OFF.
Precautions
• The three points starting from the device specified by (D) are used. Therefore, do not overlap any device used by others.
Operation error
• In any of the following cases, an operation error occurs, the error flag (SM0) turns ON, and an error code is stored into SD0.
• QnUDVCPU, LCPU: The serial number (first five digits) is "16112" or later.
(S1): Start number of device where data is stored (real number)
(S2): Data to be compared or start number of the device where the data to be compared is stored (real number)
(D): Start bit device number to which the comparison result is output (Bit)
(S2): Data to be compared or start number of the device where the data to be compared is stored (real number)
(D): Start bit device number to which the comparison result is output (Bit)
Setting
data
data
Internal device
R, ZR
J\
U\G
Zn
Constant
E
E
Others
Bit
Word
Bit
Word
(S1)
(S2)
(D)
Error
code
code
Error details
Q00J/
Q00/
Q01
Q00/
Q01
QnH
QnPH
QnPRH QnU
LCPU
4101
The range of three points from the device specified by (D) exceeds the range
of the corresponding device.
of the corresponding device.
4140
The operation target data is a subnormal number or NaN (not a number).
Basic
High
performance
Process
Redundant
Universal
Ver.
LCPU
Ver.
S2
S1
EDCMPP
EDCMP
EDCMPP
EDCMP
S2
S1
D
D
Command
Command
Contact
EDCMP
S1
S2
D
D
D
D +2
+1
S1
S2
S1
[
[
[
[
]
]
S2
S1
S1
+3
+3
]
]
+3
+3
>
=
to
to
to
to
Turns on when
Turns on when
S2
S1
S2
[
[
]
S1 +3
]
+3
<
to
to
Turns on when
S2
S2