102
4-12-2 CMP and CMPL
CMP(020) and CMPL(021) are the same in the CV-series and CVM1-series as
in the C-series in that they all output the comparison results to comparison flags.
There are differences, however, in the way that are depicted in ladder diagrams.
(020)
CMP D00000 D00000
Comparison
flag
In the version-2 CVM1 CPUs, CMP(028) and CMPL(029) operate the same as
comparison instructions in C-series PC in that they output results to comparison
flags, but they are programmed as right-hand instructions. The signed binary
comparison instructions CPS(026) and CPSL(027) also output results to the
comparison flags, but are programmed as right-hand instructions in the same
was as for comparison instructions in the C-series PCs, as shown in the follow-
ing program section.
(028)
CMP D00000 D00000
Comparison flag
(026)
CPS D00002 D00003
Comparison flag
In the version-2 CVM1 CPUs, CMP(028), CMPL(029), CPS(026), and
CPSL(027) are not intermediate instructions, and no other instructions can be
programmed on the same instruction line between them and the right-hand bus
bar.
Input methods and instruction sets vary according to which support software is
used.
CV Support Software
Entering “CMP” or “CMPL” by means of string input specifies CMP(020) or
CMPL(021).
SYSMAC Support Software
Entering “CMP” or “CMPL” by means of string input specifies CMP(028) or
CMPL(029). In order to input CMP(020) or CMPL(021), it is necessary to input
the function code.
Converting Programs
When a C-series ladder program is converted from C to CV using the SYSMAC
Support Software, CMP and CMPL instructions in the program are converted to
CMP(028) and CMPL(029), respectively.
Precautions when
Programming
Using Version-2 CVM1 CPUs Section 4-12