EasyManuals Logo

Mitsubishi MELSEC iQ-F FX5 series User Manual

Mitsubishi MELSEC iQ-F FX5 series
888 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
Page #823 background imageLoading...
Page #823 background image
22 CHARACTER STRING FUNCTIONS
22.5 Inserting Character String
821
22
22.5 Inserting Character String
INSERT(_E)
These functions insert a character string into another character string and output the result.
Setting data
â– Descriptions, types, and data types
Processing details
â– Operation processing
• These functions insert the character string input to (s2) at the (n)th character from the start of the character string input to
(s1) (head position of the insertion) and output from (d).
• After the character string specified by (s2) is inserted to the one specified by (s1), 00H indicating an end of the character
string specified by (s2) is ignored.
• When the inserted character string exceeds 255 bytes, these functions output a character string within 255 bytes.
Ex.
When the value input to (n) is 4
• A value input to (s1) and (s2) is the STRING type data value and within the range from 0 to 255 byte(s).
• A value input to (n) is the INT type data value and within the range from 1 to 255. (However, the value must be within the
number of characters of the character string to be input to (s1).)
Ladder diagram Structured text
[Without EN/ENO] [With EN/ENO] [Without EN/ENO]
d:=INSERT(s1,s2,n);
[With EN/ENO]
d:=INSERT_E(EN,ENO,s1,s2,n);
Argument Description Type Data type
EN Execution condition (TRUE: Execution, FALSE: Stop) Input variable BOOL
s1, s2 Input Input variable STRING(255)
n Specification of head character position of a character string to be
inserted
Input variable INT
ENO Output status (TRUE: Normal, FALSE: Abnormal) Output variable BOOL
d Output Output variable STRING(255)
s1 d
s2
n
EN ENO
ds1
s2
n
"ABCDE"
42H (B) 41H (A)
31H (1) 43H (C)
33H (3) 32H (2)
35H (5) 34H (4)
44H (D) 36H (6)
00H 45H (E)
2nd word
3rd word
4th word
5th word
6th word
1st word
32H (2) 31H (1)
34H (4) 33H (3)
36H (6)
00H
35H (5)
High-order byte Low-order byte
"123456"
2nd word
3rd word
4th word
1st word
42H (B) 41H (A)
44H (D) 43H (C)
00H 45H (E)
High-order byte Low-order byte
2nd word
3rd word
1st word
High-order byte Low-order byte
"ABC123456DE"
Value input to (s2)
Value input to (s1) Output value
(d)
Head character
position of a character
string to be inserted
n:
4th character

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Mitsubishi MELSEC iQ-F FX5 series and is the answer not in the manual?

Mitsubishi MELSEC iQ-F FX5 series Specifications

General IconGeneral
BrandMitsubishi
ModelMELSEC iQ-F FX5 series
CategoryController
LanguageEnglish

Related product manuals