Mitsubishi Electric MELSEC iQ-R Series Programming Manual page 634

Hide thumbs Also See for MELSEC iQ-R Series:
Table of Contents

Advertisement

Processing details
• These instructions perform a comparison operation between the character string data in the device specified by (s1) and
the character string data in the device specified by (s2). (Devices are used as normally open contacts).
• In comparison operation, the ASCII code of character string is compared character by character from the beginning of the
character string.
• The character strings in the devices specified by (s1) and (s2) mean those in the device numbers from the specified one to
the one containing 00H.
• The comparison result turns out matching if all character strings match.
b15
∙∙∙
b8
b7
(s1)
42H (B)
41H (A)
(s1)+1
44H (D)
43H (C)
(s1)+2
00H
45H (E)
"ABCDE"
 Instruction symbol (ladder, FBD/LD)
$=, EQ
$<>, NE
$>, GT
$<=, LE
$<, LT
$>=, GE
• When different character strings are compared, the character string with a larger character code is greater.
b15
∙∙∙
b8
b7
(s1)
42H (B)
41H (A)
(s1)+1
44H (D)
43H (C)
(s1)+2
00H
46H (F)
"ABCDF"
 Instruction symbol (ladder, FBD/LD)
$=, EQ
$<>, NE
$>, GT
$<=, LE
$<, LT
$>=, GE
• When different character strings are compared, the relative size of a character string is determined by the relative size of the first different character codes.
b15
∙∙∙
b8
b7
32H (2)
31H (1)
(s1)
34H (4)
33H (3)
(s1)+1
00H
35H (5)
(s1)+2
"12345"
 Instruction symbol (ladder, FBD/LD)
$=, EQ
$<>, NE
$>, GT
$<=, LE
$<, LT
$>=, GE
7 APPLICATION INSTRUCTIONS
632
7.8 String Processing Instructions
∙∙∙
b0
(s2)
(s2)+1
=
(s2)+2
∙∙∙
b0
(s2)
(s2)+1
>
(s2)+2
∙∙∙
b0
(s2)
(s2)+1
<
(s2)+2
b15
∙∙∙
b8
b7
∙∙∙
b0
42H (B)
41H (A)
44H (D)
43H (C)
00H
45H (E)
"ABCDE"
Result
Continuity state (ENO is on.)
Non-continuity state (ENO is off.)
Non-continuity state (ENO is off.)
Continuity state (ENO is on.)
Non-continuity state (ENO is off.)
Continuity state (ENO is on.)
b15
∙∙∙
b8
b7
∙∙∙
b0
42H (B)
41H (A)
44H (D)
43H (C)
00H
45H (E)
"ABCDE"
Result
Non-continuity state (ENO is off.)
Continuity state (ENO is on.)
Continuity state (ENO is on.)
Non-continuity state (ENO is off.)
Non-continuity state (ENO is off.)
Continuity state (ENO is on.)
b15
∙∙∙
b8
b7
∙∙∙
b0
32H (2)
31H (1)
33H (3)
34H (4)
00H
35H (5)
"12435"
Result
Non-continuity state (ENO is off.)
Continuity state (ENO is on.)
Non-continuity state (ENO is off.)
Continuity state (ENO is on.)
Continuity state (ENO is on.)
Non-continuity state (ENO is off.)

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents