Mitsubishi Electric MELSEC iQ-R Series Programming Manual page 617

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

Advertisement

• When reading data from the position where the previous reading ends, specify the same values for
"Execution/End type", "Number of columns", and "Data type specification". If not, data cannot be added
correctly from the position where the previous reading ends.
• While reading data from the position where the previous reading ends, if the SP.FREAD instruction with
different settings or the SP.FWRITE instruction is executed, data cannot be added correctly from the
position where the previous reading ends.
Precautions
• Do not execute this instruction in interrupt programs. Doing so may cause malfunction of the module.
• When reading multiple elements at reading data after converted to CSV format, secure devices sufficient for the total size of
the elements in the read data area before executing the instruction. Since read data is stored from (d2)+1, the number of
words required to be secured as (d2) is ((total number of words for each element) + 1) words.
• When "Reading data after converted to CSV format" (String (ASCII data)) is specified, set the total size (in units of words) to
(d1)+3 (Maximum number of read data).
[Example] When reading 100 elements each of which contains 100 characters from a CSV file
(100 (characters) + 2 (NULL))  100 (elements) = 10200 bytes = 5100 words
Therefore, set 5100 to (d1)+3 to secure an area for 5101 words for (d2).
Operation error
Error code
Description
(SD0)
2820H
Data is read exceeding the size of the device.
3405H
The drive specified by (s1) is not the one for the SD memory card.
Any value that is set in the device specified by (d1) and later as control data is out of the range.
Page 600 For RnCPU (firmware version "28" or later) and RnENCPU (firmware version "28" or later)
Page 602 For RnCPU (firmware version "27" or earlier), RnENCPU (firmware version "27" or earlier), RnPCPU, and RnSFCPU
The file name character string specified by (s2) cannot be read.
• The number of characters of the string in the file name specified exceeds the range.
• An inhibited value is set.
Page 600 For RnCPU (firmware version "28" or later) and RnENCPU (firmware version "28" or later)
Page 602 For RnCPU (firmware version "27" or earlier), RnENCPU (firmware version "27" or earlier), RnPCPU, and RnSFCPU
3427H
An invalid combination of (d1)+0 (Execution/completion type ) and (d1)+7 (Data type specification) is specified.
Page 600 For RnCPU (firmware version "28" or later) and RnENCPU (firmware version "28" or later)
When the SP.FREAD instruction completes with an error, an error code is stored in the device specified by (d1)+1. (Note that
an error code is not stored if the instruction results in an operation error.)
For the error code stored in (d1)+1, refer to the following.
Page 593 Reading/Writing data in the specified file
7 APPLICATION INSTRUCTIONS
7.6 Reading/Writing Data Instructions
7
615

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents