![Omron CJ1G-CPU series Programming Manual Download Page 226](http://html1.mh-extra.com/html/omron/cj1g-cpu-series/cj1g-cpu-series_programming-manual_742489226.webp)
205
Manipulating Files
Section 5-2
Transferring ASCII Files
(Not supported by CS-
series CS1 CPU Units that
are pre-EV1)
ASCII files can be transferred as well as binary files, so the third and fourth
digits of the instruction’s control word operand (C) indicate the type of data file
being transferred and the number of fields between carriage returns.
CX-Programmer V1.1 or Earlier Version:
Indirectly Setting the Control Word
When V1.1 or an earlier version of CX-Programmer is being used, ASCII files
cannot be transferred with FREAD(700) and FWRIT(701) if a constant is input
for the control word to specify the data type and carriage return treatment.
Only binary data with no carriage returns can be transferred if a constant is
used.
ASCII files can be transferred with FREAD(700) and FWRIT(701), however,
by indirectly setting the control word. Write the desired control word setting to
a word and specify that word as the control word in FREAD(700) or
FWRIT(701), as shown on the left in the following diagram.
Note The time from the CPU Unit’s internal clock is used to date files created in file
memory with FWRIT(701).
Only one file memory operation may be executed at a time, so FREAD(700)
and FWRIT(701) must not be executed when any of the following file memory
operations are being performed:
1,2,3...
1.
Execution of FREAD(700) or FWRIT(701)
Bits in C
Settings
Programming Device
limitations
12 to 15
Data type
0: Binary (.IOM)
1: Non-delimited words (.TXT)
2: Non-delimited double-words (.TXT)
3: Comma-delimited words (.CSV)
4: Comma-delimited double-words (.CSV)
5: Tab-delimited words (.TXT)
6: Tab-delimited double-words (.TXT)
If CX-Programmer V1.1 or an
earlier version is being used,
only 0 Hex (.IOM files) can be
specified directly.
If CX-Programmer V1.2 or a
later version (or a Program-
ming Console) is being used,
the control word bits can be
set to between 0 and 6 Hex.
08 to 11
Carriage returns
0: No returns
8: Return every 10 fields
9: Return every 1 field
A: Return every 2 fields
B: Return every 4 fields
C: Return every 5 fields
D: Return every 16 fields
If CX-Programmer V1.1 or an
earlier version (or a Program-
ming Console) is being used,
only 0 Hex (no returns) can
be specified directly.
If CX-Programmer V1.2 or a
later version is being used,
the control word bits can be
set to 0 Hex or to between 8
and D Hex.
Execution
condition
File Memory
Operation Flag
CX-Programmer Versions V1.1 and Earlier
CX-Programmer Versions V1.2 and Later
Write #1800
to W000.
Specify W000
as C.
Execution
condition
File Memory
Operation Flag
Specify #1800 as C.
Summary of Contents for CJ1G-CPU series
Page 3: ...iv...
Page 5: ...vi...
Page 21: ...xxii Conformance to EC Directives 6...
Page 169: ...148 Task Control Instructions Section 3 32...
Page 203: ...182 Programming Device Operations for Tasks Section 4 4...
Page 253: ...232 Using File Memory Section 5 3...
Page 337: ...316 Other Functions Section 6 11...
Page 347: ......
Page 369: ......
Page 373: ......
Page 379: ......
Page 381: ...360 Revision History...