EasyManua.ls Logo

Mitsubishi Electric MELSEC-Q/L - Page 549

Mitsubishi Electric MELSEC-Q/L
1084 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...
7 APPLICATION INSTRUCTIONS
7.11 Character String Processing Instructions
547
7
If no comment has been registered for the device specified by (S) despite the fact that the comment range setting is made,
all of the characters for the comment are processed as "20H" (space).
The device number plus 1 where the final character of (D) is stored differs depending on the ON/OFF status of SM701
(number of characters to output select signal).
When a comment is read, SM720 turns ON for one scan after the instruction is completed. SM721 is turned ON during the
execution of the instruction. While SM721 is ON, the COMRD(P) instruction cannot be executed. If the attempt is made, no
processing is performed.
For device comments used with the COMRD(P) instruction, use comment files stored in the standard RAM,
standard ROM, memory card, or SD memory card. Comment files stored in the program memory cannot be
used.
Set the comment file used for the COMRD(P) instruction in "PLC file setting" in the PLC parameter dialog
box. If the comment file to be used is not set in the PLC file setting, device comments cannot be output with
the COMRD(P) instruction. When a comment file is set in the "PLC File" tab of the PLC Parameter dialog
box, but the file does not exist at power-on or reset, "FILESET ERROR" (error code: 2400) will occur.
The COMRD(P) instruction cannot be executed during the interrupt program. No operation if executed.
Operation error
In any of the following cases, an operation error occurs, the error flag (SM0) turns ON, and an error code is stored into SD0.
Program example
The following program stores the comments set at D100 into the area starting from W0 as ASCII when X1C is turned ON.
When SM701 is OFF: Does not change
When SM701 is ON: Stores "0"
Error
code
Error details Q00J/
Q00/
Q01
QnH QnPH QnPRH QnU LCPU
4100 The comment is not registered to the device number specified by (S). 
4101 The device number specified by (D) is not a word device. 
The range of the device specified by (D) exceeds the range of the
corresponding device.

[Ladder Mode] [List Mode]
[Operation]
Step Instruction Device
W1
b15 b0
W2
Comment at D100
W3
W4
W5
W6
W7
W15
W16
W0
LINE A TARGET
49H (I)
4E
H (N)
20
H (space)
20
H (space)
45
H (E)
41
H (A)
41
H (A)
54
H (T)
54
H (T)
47
H (G)
52
H (R)
45
H (E)
20
H (space)
20
H (space)
20
H (space)
20
H (space) 20H (space)
b8
b7
4CH (L)
00
H

Table of Contents

Related product manuals