Omron SYSMAC CJ - REFERENCE MANUAL 08-2008 Reference Manual page 1145

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

Advertisement

File Memory Instructions
Precautions
Examples
Name
EM File Memory For-
A34306
mat Error Flag
Number of Data to
A346 to
Transfer
A347
During normal instruction processing, FREAD(700) is used only to start read-
ing file memory. The instruction execution times given toward the end of this
manual are thus the times required to start reading, not to complete it. Actual
reading (transfer) is performed by the file access processing in peripheral ser-
vicing. Therefore, once FREAD(700) has been executed, reading is continu-
ously executed even if the execution condition is OFF in following cycles.
When transfer has been completed, the File Memory Operation Flag
(A34313) will turn OFF. This flag can be used for exclusive control of file mem-
ory instructions.
The time required to complete data transfer for FREAD(700) will depend on
the amount of data being transferred, the service time allocated to file access
processing, and other conditions. As a guideline, the transfer times for a cycle
time of 10 ms for a file in the root directory with the default service time set-
tings will be 0.92 s for 1,024 words and 4.64 s for 9,999 words.
The File Memory Operation Flag (A34313) will be turned ON when
FREAD(700) is executed. An error will occur and the instruction will not be
executed if A34313 is already ON.
The File Read Error Flag (A34310) will be turned ON and the instruction will
not be executed if the specified file contains the wrong data type or the file
data is corrupted. For text or CSV files, the character code must be hexadeci-
mal data and delimiters must be every 4 digits for word data and every 8 digits
for double-word data. Data will be read up to the point where an illegal charac-
ter is detected.
A few seconds is required for the CPU Unit to detect a Memory Card after it
has been inserted. If a Memory Card is going to be accessed soon after
power is turned ON or after a Memory Card is inserted, use the Memory Card
Detected Flag (A34315) in a NO input condition as shown below to be sure
that the Memory Card has been detected.
Execution
condition
A34315
Memory Card
Detected Flag
When CIO 000000 turns ON in the following example, FREAD(700) reads 10
words of data from file \ABC\XYZ.IOM starting with the beginning of the file +
5 words and outputs these 10 words to D00400 through D00409.
Address
ON when there is a format error in the starting
bank of EM file memory.
The contents of these words indicate the sta-
tus of data file transfers.
When an FREAD(700) or FWRIT(701) instruc-
tion is executed, the number of words or fields
to be transferred is written to these words. The
value is decremented by 1 as each word or
field is transferred.
A346 contains the rightmost 16 bits and A347
contains the leftmost 16 bits of the 32-bit
binary value.
A34313
File Memory
Operation Flag
Section 3-26
Operation
FREAD
C
S1
S2
D
1105

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sysmac cs seriesSysmac one nsj seriesSysmac cj series

Table of Contents