|Hint: Use the tree menu to navigate groups of related pages|
[FreeRTOS+FAT Standard API Reference]
char *ff_fgets( char *pcBuffer, size_t xCount, FF_FILE *pxStream );
Reads a string from a file by reading bytes from pxStream into pcBuffer until either (xCount – 1) bytes have been read, or a newline (‘n’) character has been read into to pcBuffer.
Carriage return characters (‘r’) are not treated in any special way, and are copied into pcBuffer.
The string copied into pcBuffer is NULL terminated before ff_fgets() returns.
A pointer to the buffer into which characters read from
the file will be placed. The buffer must be at least
big enough to hold xCount bytes.
Bytes will be read from the file until either a newline
character has been received, or (xCount – 1) bytes have
A pointer to the file from which the data is being read.
This is the same pointer that was returned from the call
to ff_fopen() used to originally open the file.
On success a pointer to pcBuffer is returned. If there is a read error then NULL is returned and the task’s errno is set to indicate the reason. A task can obtain its errno value using the ff_errno() API function.