beautypg.com

Philips Bluetooth QuickStart Kit User Manual

Page 55

background image

Bluetooth QuickStart Kit Version 1.0 - User’s Guide

Page 55

Copyright 2004-2005 © Embedded Artists AB

FAT_ERROR_A_FOLDER

– The path points to a folder and not a file

FAT_ERROR_FS_NOT_INITIALIZED

– The file system has not been initialized

FAT_ERROR_READ_ONLY

– The file system is read-only


B.4.8 fatReadDirEntry

tFatResult fatReadDirEntry( const tFatHandle handle,
tFatDirEntry* pFatDirEntry )

This function opens the next entry in the specified folder. The pDir parameter will be
updated. The pFatDirEntry structure will be filled with information about the new entry.
This function will skip past the "." and ".." directory entries.

Parameters:

[in] handle – A handle to the folder to look in

[in/out] pFatDirEntry – A pointer to a pre-allocated structure

Returns:

FAT_OK if a new entry was found, otherwise an error code

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

FAT_OK

- The function completed successfully.

FAT_ERROR_INV_HAND

– The handle is invalid


B.4.9 fatGetEntryIsDir

tFatResult fatGetEntryIsDir( tFatDirEntry* pFatDirEntry,
tBool* pIsDir )

Tests whether the specified entry is a file or folder.

Parameters:

[in] pFatDirEntry – The entry to test

[out] pIsDir – TRUE if the entry is a folder, FALSE if it is a file.

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.10 fatGetEntrySize

tFatResult fatGetEntrySize( tFatDirEntry* pFatDirEntry, tU32*
pSize )

Returns the size of the specified file.

Parameters:

[in] pFatDirEntry – The entry pointing to a file

[out] pSize – The size of the file

Returns:

FAT_OK if a entry was valid, otherwise an error code