FSFile_Wr()
CPU_SIZE_T FSFile_Wr (FS_FILE *p_file, void *p_src, CPU_SIZE_T size, FS_ERR *p_err);
File | Called from | Code enabled by |
---|---|---|
| Application;
|
|
Write to a file.
See fs_fwrite()
for more information.
Arguments
p_file
Pointer to a file.
p_src
Pointer to source buffer.
size
Number of octets to write.
p_err
Pointer to variable that will the receive return error code from the function:
FS_ERR_NONE
File write successfully.
FS_ERR_NULL_PTR
Argument p_file
/p_src
passed a NULL pointer.
FS_ERR_INVALID_TYPE
Argument p_file
's type is invalid or unknown.
FS_ERR_FILE_NOT_OPEN
File not open.
FS_ERR_FILE_INVALID_OP
Invalid operation on file.
FS_ERR_DEV
Device access error.
Returned Value
The number of bytes written, if file write successful.
0, otherwise.
Notes/Warnings
None.