header_file.h
unsigned char f_getcwd( char *pcBuffer, int iBufferLength );
Obtain the name of the current working directory.
Parameters:
pcBuffer
|
The buffer into which the name of the current working
directory will be stored (as a standard C null terminated
string).
|
iBufferLength
|
The size (in bytes) of the buffer pointed to by the
pcBuffer parameter.
|
Returns:
F_NO_ERROR
|
The name of the current working directory was copied into
pcBuffer.
|
Any other value
|
The name of the current directory was not copied into
pcBuffer. The return value holds the error code.
|
See also
f_mkdir(), f_rmdir(), f_chdir().
Example usage:
void vExampleFunction( void )
{
char pcBuffer[ 100 ];
unsigned char ucReturnValue;
ucReturnValue = f_getcwd( pcBuffer, sizeof( pcBuffer ) );
if( ucReturnValue != F_NO_ERROR )
{
}
else
{
}
}
Example use of the f_getcwd() API function
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.