7 Applied Instructions
7.2 Move and Compare
144
FXCPU Structured Programming Manual
(Basic & Applied Instruction)
2. 32-bit operation(DCMP, DCMPP)
The comparison value specified by   and the comparison source specified by   are compared with
each other.  According to the result (smaller, equal or larger), any of the three points of the devices specified
by   turns on.
• The source data specified by   and   are handled as BIN (binary) values.
• Comparison is executed algebraically.  Example: -125400 < 22466
Cautions
1) Some restrictions to applicable devices
S1:The FX
3U and FX3UC PLCs only are applicable. Not indexed (V,Z).
S2:The FX
3U, FX3UC and FX3G PLCs only are applicable.
S3:The FX
3U and FX3UC PLCs only are applicable.
2) When handling array data or 32-bit data in a structured program, a 16-bit device cannot be specified 
directly as in the case of a simple project.  Use a label to handle array data or 32-bit data.
A 32-bit counter can be specified directly as it is a 32-bit long device.
Use a global label to specify a device.
3) The FX
0, FX0S or FX0N PLC does not support the pulse operation type instructions.
To execute pulse operation, make the instruction execution condition pulse type.
4) From the device specified as  , three devices are occupied.
Be sure not to use those devices in another control.
*1 This defines comparison value data or the device that stores the comparison value data.
*2 This defines the comparison source data or the device that stores the comparison source data.
*3 This defines the head bit device that stores the comparison result. (Defines M100)
Command input
Command
input
48
49
50
51
Latched
Latched
Latched
DCMP
EN
s1
s2
ENO
d
Label1
*1
Label2
*2
Label3
*3
(M100)
 100
 101
 102
Even if the command input turns OFF and DCMP instruction is not executed, 
    to     +2 latch the status just before the command input turns OFF from ON.
d
d
s2 s2
       +1,
d
        +1
d
        +2
s1 s1
        +1,
d
Turns on in the case of
[   +1,    ] > [   +1,   ]
s2s1 s1 s2
Turns on in the case of
[   +1,    ] = [   +1,   ]
s2s1 s1 s2
Turns on in the case of
[   +1,    ] < [   +1,   ]
s2s1 s1 s2