f_getcwd

The f_getcwd function retrieves the current directory.

FRESULT f_getcwd (
  TCHAR* buff, /* [OUT] Buffer to return path name */
  UINT len     /* [IN] The length of the buffer */
);

Parameters

buff
Pointer to the buffer to receive the current directory string.
len
Size of the buffer in unit of TCHAR.

Return Values

FR_OK, FR_DISK_ERR, FR_INT_ERR, FR_NOT_READY, FR_NOT_ENABLED, FR_NO_FILESYSTEM, FR_TIMEOUT, FR_NOT_ENOUGH_CORE

Description

The f_getcwd() function retrieves full path name of the current directory of the current drive. When _VOLUMES is larger than 1, a logical drive number is added to top of the path name.

QuickInfo

Available when _FS_RPATH == 2.

See Also

f_chdrive, f_chdir

Return