Overview
Type:
|
Function
|
Available as of:
|
SystemInterface_1.32.6.0
|
Versions:
|
Current version
|
Task
Write the number of bytes in a file.
Description
The function writes the number (i_diCount) of bytes from a variable (i_pbyVarAdr) into the file identified by i_diFileId.
NOTE: The processing time of this function is a few hundred milliseconds. This is why the times for the cycle check of the task in which this function is performed should be increased one-time. For example FC_CycleCheckTimeSet(500, 2).
Interface
Input
|
Data type
|
Description
|
i_diFileId
|
DINT
|
Name of the file to be written
|
i_pbyVarAdr
|
POINTER TO BYTE
|
Variable where the write data is stored
|
i_diCount
|
DINT
|
Number of bytes to be written
|
Return Value
Data type
|
Description
|
DINT
|
0: OK
-3: Incorrect FileId (< 1000000 or >1000009)
-5: File is not open
|