Keil Logo

File I/O Routines

File I/O routines provide methods for reading and writing to files in a Flash file system. File I/O routines are thread safe.

Routine Description
fclose Closes the file stream.
feof Reports whether the end of stream has been reached.
ferror Reports whether there is an error in the file stream.
fflush Flushes the file stream.
fgetc Reads a character from the file stream.
fgets Reads a string from the file stream.
fopen
Opens the file stream.
fprintf Writes a formatted string to the file stream.
fputc Writes a character to the file stream.
fputs Writes a string to the file stream.
fread Reads a number of bytes from the file stream.
fscanf Reads a formatted string from the file stream.
fseek Moves the file stream's in-file pointer to a new location.
ftell Gets the current location of the stream's in-file pointer.
fwrite Writes a number of bytes to the file stream.
rewind Moves the file stream's in-file pointer to the beginning of the file.
ungetc Stores a character into an input file stream.
  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.