beautypg.com

Philips Bluetooth QuickStart Kit User Manual

Page 56

background image

Bluetooth QuickStart Kit Version 1.0 - User’s Guide

Page 56

Copyright 2004-2005 © Embedded Artists AB

Possible error situations (what can be identified in an error code):

FAT_OK

- The function completed successfully.

FAT_ERROR_A_FOLDER

– The entry did not point to a file.

B.4.11 fatGetEntryName

tFatResult fatGetEntryName( tFatDirEntry* pFatDirEntry, tU8**
ppFilename )

Returns the name of the specified entry. The name will be encoded in Unicode (two
bytes per character).

Note: The returned ppFilename must NOT be modified or freed.

Parameters:

[in] pFatDirEntry – The entry to extract the name from

[out] ppFilename – Will contain the filename

Returns:

FAT_OK if a entry was valid, otherwise an error code

Possible error situations (what can be identified in an error code):

FAT_OK

- The function completed successfully.

B.4.12 fatCreateDir

tFatResult fatCreateDir( const tU8* pPath )

This function creates a new directory with the specified absolute path. This operation can
fail for a number of reasons. E.g. if a file or folder with that name already exists.

Parameters:

[in] pPath – An absolute path to the new directory.

Returns:

FAT_OK the directory was created, otherwise an error code

Possible error situations (what can be identified in an error code):

FAT_OK

- The function completed successfully.

FAT_ERROR_EXISTS - There is already a folder matching the pPath
FAT_ERROR_A_FILE - There is a file matching the pPath
FAT_ERROR_FS_NOT_INITIALIZED – The file system has not been initialized.
FAT_ERROR_READ_ONLY - The file system is read-only

B.4.13 fatDeleteDir

tFatResult fatDeleteDir( const tU8* pPath )

This function deletes the specified directory if and only if it is empty.

Parameters:

[in] pPath – An absolute path to the directory to remove.

Returns:

FAT_OK the directory was removed, otherwise an error code