The f_close function closes an open file.
FRESULT f_close ( FIL* FileObject /* Pointer to the file object structure */ );
The f_close function closes an open file object. If any data has been written to the file, the cached information of the file is written back to the disk. After the function succeeded, the file object is no longer valid and it can be discarded. If the file object has been opened in read-only mode, it may be discarded without closing process by this function.
Always available.