String Length: Len$(650) - Omron SYSMAC CJ - REFERENCE MANUAL 08-2008 Reference Manual

Programmable controllers
Hide thumbs Also See for SYSMAC CJ - REFERENCE MANUAL 08-2008:
Table of Contents

Advertisement

Text String Processing Instructions
Flags
Precautions
Example

3-33-8 STRING LENGTH: LEN$(650)

Purpose
Ladder Symbol
Variations
Applicable Program Areas
Operands
Name
Label
Error Flag
ER
Equals Flag
=
The maximum number of characters to be read that can be designated by S1
or S2 is 4,095 (0FFF hex). If more than that are designated, an error will be
generated and the Error Flag will turn ON.
If 0000 (hex) is output to D, the Equals Flag will turn ON.
In this example, FIND$(660) is used to find one character from within a text
string.
Text string: ABCDEF
S1: D00100
Calculates the length of a text string.
LEN$(650)
S
D
Variations
Executed Each Cycle for ON Condition
Executed Once for Upward Differentiation
Executed Once for Downward Differentiation
Immediate Refreshing Specification
Block program areas
OK
S: Text String
S + maximum 2,047 words
Operation
ON if more than 4,095 characters are designated by S1
or S2.
ON if the Communications Port Enabled Flag for the com-
munications port number specified as the Com Port num-
ber for Background Execution is OFF when background
processing is specified.
OFF in all other cases.
ON if 0000 (hex) is output to D.
OFF in all other cases.
Text string C
S2: D00200
S: Text string first word
D: First destination word
Step program areas
Subroutines
OK
OK
15
S
Text string data: 4,095 characters max. + NUL
to
Section 3-33
D: D00300
LEN$(650)
@LEN$(650)
Not supported
Not supported
Interrupt tasks
OK
0
1235

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sysmac cs seriesSysmac one nsj seriesSysmac cj series

Table of Contents