641
SP.FREAD
1
2
3
4
4
6
7
8
7.18
Ot
her inst
ructions
7.18.1
3
SP.FREAD
(3) Be sure to use word units to designate the number of request read data ( +2), file position ( +4 and
+5), and
reading result (No. of read data) ( ).
The following shows how the data is read in binary data reading operation.
(4) When reading binary data
(a) If the extension of the target file is omitted, ".BIN" is used as an extension.
(b) When the designated file does not exist, an error occurs.
(c) If the position specified is greater than the existing file size:
• The High Performance model QCPU of which the first 5 digits of the serial number are "01111" or lower results in
an error.
• The High Performance model QCPU/Process CPU/Redundant CPU/Universal model QCPU/LCPU of which the
first 5 digits of the serial number are '01112' or higher will perform reading at point 0 and will be completed
normally.
(5) When reading data after CSV format conversion
(a) The elements in CSV format file (cells for EXCEL) are read by each row. The numerical value and character strings
are converted into binary data and stored in the device.
(b) If the extension is omitted, ".CSV" is used as an extension.
(c) When the designated file does not exist, an error occurs.
(d) The data designated by the number of request read data ( +2) are read from the beginning of the file.
When the last data of the file is reached before the specified number of data are read:
• The High Performance model QCPU of which the first 5 digits of the serial number are "01111" or lower results in
an error.
• The High Performance model QCPU/Process CPU/Redundant CPU/Universal model QCPU/LCPU whose the
first 5 digits of the serial number are '01112' or higher reads the data up to the point where the reading is
possible.
D0
D0
D0
D1
L
ocat
i
on
to
start
read
i
ng
i
n
the
f
il
e
Contro
l
data
H
0000
-
K
3
D0
+
0
D0
+
1
D0
+
2
D0
+
3
D0
+4
D0
+
5
D0
+
6
D0
+
7
K
1
K
0
K
0
-
E
xecut
i
on
/
comp
l
et
i
on
type
(
N
ot
used)
N
o
.
of
request
read
data
(
N
ot
used)
N
o
.
of
co
l
umns
des
i
gnat
i
on
Data
type
spec
i
f
i
cat
i
on
H
00
Fil
e
data
(
i
n
byte
un
i
ts)
D1
+
0
H
11
H
22
H
33
H44
H
55
H
66
H
77
H
88
H
99
H
AA
Data
de
vi
ce
D1
+
1
D1
+
2
D1
+
3
K
3
H
33 22
H
55
44
H
77
Read
data
T
ota
l
66
D0