Data Structures | |
struct | _FATINMEMORY |
struct | _FILE |
struct | _FILENODE |
struct | _FILENODEINFS |
struct | _FLASHFS |
Defines | |
#define | TYPE_DIRECTORY 1 |
#define | TYPE_FILE 2 |
#define | TYPE_NULL 0 |
#define | MAX_FILE_NAME 50 |
#define | NUMBER_OF_FILES 50 |
#define | EOF 0 |
Typedefs | |
typedef _FILE | FILE |
Functions | |
int | InitFlashFs (void) |
FILE * | fileOpen (char *name, char type) |
int | fileWrite (FILE *file, void *data, u_int size) |
int | fileClose (FILE *file) |
int | fileRead (FILE *file, void *data, u_int size) |
u_long | fileSize (FILE *file) |
int | fileSeek (FILE *file, u_long pos) |
int | remove (char *name) |
char * | ls (char *dir, char *ret, char *param) |
int | format (void) |
|
End of file mark. |
|
Value: (ROOT_PAGE \ + ((sizeof(FILENODEINFS)*NUMBER_OF_FILES+sizeof(FLASHFS))/PAGE_SIZE + 1) \ + MAX_PAGE_NUMBER/(PAGE_SIZE*8) + 1 \ + 1) |
|
Number of character in filename. |
|
Max number of stored files in filessystem. |
|
Filesystem file type. |
|
Filesystem file type. |
|
Filesystem file type. |
|
File descriptor used by read and write function. Created when file is open. |
|
Closes opened file. When file was opened for write this method finish write operations and update information in flash.
|
|
Opens file. File must be open before read/write operations. When file dosn't exist this method create it.
|
|
Reads data from file.
|
|
Moves file read or write pointer to specified position.
|
|
Reads file size.
|
|
Writes data to file.
|
|
Formats filesystem. This method clear all files and all pages in flashfs.
|
|
Inits flash filesystem. Caled it first.
|
|
Print content of filesystem in specified directory.
|
|
Removes file from filesystem.
|