EasyManua.ls Logo

Mitsubishi Electric MELSEC FX3U - 26.5 FNC204 - RIGHT; Extracting Character String Data from the Right

Mitsubishi Electric MELSEC FX3U
1000 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
655
FX3G/FX3U/FX3UC Series Programmable Controllers
Programming Manual - Basic & Applied Instruction Edition
26 Character String Control – FNC200 to FNC209
26.4 FNC203 – LEN / Character String Length Detection
21
FNC160-FNC169
Real Time Clock
Control
22
FNC170-FNC179
External Device
23
FNC180
Alternate
Instructions
24
FNC181-FNC189
Others
25
FNC190-FNC199
Block Data
Operation
26
FNC200-FNC209
Character String
Control
27
FNC210-FNC219
Data
Operation 3
28
FNC220-FNC249
Data
Comparison
29
FNC250-FNC269
Data Table
Operation
30
FNC270-FNC274
Ex-Device
Inverter Comms
26.4 FNC203 – LEN / Character String Length Detection
Outline
This instruction detects the number of characters (bytes) of a specified character string.
For handling of character strings, refer to Section 5.3.
1. Instruction format
2. Set data
3. Applicable devices
Explanation of function and operation
1. 16-bit operation (LEN and LENP)
The length of a character string stored in and later is detected, and stored to . Data starting from
until the first device storing "00H" is handled as a character string in units of byte.
For example, when “ABCDEFGHI” is stored in and later as shown below, K9 is stored to .
Operand Type Description Data Type
Head device number storing a character string whose length is to be detected Character string
Device number storing the detected character string length (number of bytes) 16-bit binary
Oper-
and
Type
Bit Devices Word Devices Others
System User Digit Specification System User
Special
Unit
Index
Con-
stant
Real
Number
Charac-
ter String
Pointer
XYMTCSD
.b KnX KnY KnM KnS T C D R
U\G
VZModifyKH E "
"P
33333333 3 3
3 3 3 3333 3 3
P
FNC 203
LEN
Mnemonic Operation Condition
16-bit Instruction
5 steps
LEN
LENP
Mnemonic Operation Condition
Continuous
Operation
Pulse (Single)
Operation
32-bit Instruction
S
D
S
D
S
D
S
FNC203
LEN
b15----------b8
+1
+2
2nd character 1st character
4th character 3rd character
00H
b15---------------b0
Character string
length
D
S
S
S
+nS
6th character 5th character
“n”th character
It indicates the end of character string.
Command
input
D
S
b7-------------b0
S
D
b15----------b8
+1
+2
42H(B) 41H(A)
44H(D) 43H(C)
48H(H)
b15---------------b0
9
D
S
S
S
+4S
46H(F) 45H(E)
47H(G)
“ABCDEFGHI”
00H 49H(I)
+3S
b7-------------b0

Table of Contents

Related product manuals