1036
Text String Processing Instructions Section 3-31
Note (1) The data from S1 to S1 + the maximum 2,047 words and from S2 to S2
+ the maximum 2,047 words be in the same area.
(2) The data from S1 to S1 + the maximum 2,047 words and from S2 to S2
+ the maximum 2,047 words cannot overlap.
Operand Specifications
Description String comparison instructions compare the text strings designated by S1 and
S2. If the result of the comparison is true, an ON execution condition is cre-
ated in the ladder diagram. The maximum number of characters for either S1
or S2 is 4,095 (0FFF hex).
String comparison instructions are expressed using the 18 different mnemon-
ics listed below. (LD, AND, and OR do not appear in the ladder diagram.)
LD=$, AND=$, OR=$
LD<>$, AND<>$, OR<>$
LD<$, AND<$, OR<$
LD<=$, AND<=$, OR<=$
LD>$, AND>$, OR>$
LD>=$, AND>=$, OR>=$
The following table provides details on these instructions.
Area S1 S2
CIO Area CIO 0 to CIO 6143
Work Area W0 to W511
Holding Bit Area H0 to H511
Auxiliary Bit Area A0 to A447
A448 to A959
Timer Area T0000 to T4095
Counter Area C0000 to C4095
DM Area D0 to D32767
Indirect DM addresses
in binary
@ D0 to @ D32767
Indirect DM addresses
in BCD
*D0 to *D32767
Constants ---
Data Registers ---
Index Registers ---
Indirect addressing
using Index Registers
,IR0 to ,IR15
–2048 to +2047 ,IR0 to –2048 to +2047 ,IR15
DR0 to DR15, IR0 to IR15
,IR0+(++) to ,IR15+(++)
,–(– –)IR0 to, –(– –)IR15
Mnemonic (including
function code)
Name Function
LD=$(670) LOAD STRING EQUALS True when S1 text string
equals S2 text string.
AND=$(670) AND STRING EQUALS
OR=$(670) OR STRING EQUALS
LD<>$(671) LOAD STRING NOT EQUAL True when S1 text string
does not equal S2 text string.
AND<>$(671) AND STRING NOT EQUAL
OR<>$(671) OR STRING NOT EQUAL
LD<$(672) LOAD STRING LESS THAN True when S1 text string is
less than S2 text string.
AND<$(672) AND STRING LESS THAN
OR<$(672) OR STRING LESS THAN