Subversion Repositories NaviCtrl

Rev

Rev 368 | Rev 380 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 368 Rev 379
Line 36... Line 36...
36
        u8  Cache[BYTES_PER_SECTOR];    // Cache for read and write operation from or to the sd-card.
36
        u8  Cache[BYTES_PER_SECTOR];    // Cache for read and write operation from or to the sd-card.
37
        u32 SectorInCache;                              // The last sector read, which is still in the sector cache.
37
        u32 SectorInCache;                              // The last sector read, which is still in the sector cache.
38
        u8      State;                                          // State of the filepointer (used/unused/...) 
38
        u8      State;                                          // State of the filepointer (used/unused/...) 
39
} File_t;
39
} File_t;
Line -... Line 40...
-
 
40
 
-
 
41
         
-
 
42
#define ATTR_NONE               0x00    // normal file
-
 
43
#define ATTR_READONLY           0x01    // file is readonly
-
 
44
#define ATTR_HIDDEN                     0x02    // file is hidden
-
 
45
#define ATTR_SYSTEM                     0x04    // file is a system file
-
 
46
#define ATTR_VOLUMELABEL        0x08    // entry is a volume label
-
 
47
#define ATTR_LONG_FILENAME      0x0F    // this is a long filename entry
-
 
48
#define ATTR_SUBDIRECTORY       0x10    // entry is a directory name
-
 
49
#define ATTR_ARCHIVE            0x20    // file is new or modified
-
 
50
#define ATTR_ANY_FILE           0x3F    // all files
-
 
51
 
-
 
52
 
-
 
53
 
-
 
54
//________________________________________________________________________________________________________________________________________
-
 
55
//
-
 
56
//      Structure of an item used by functions findfirst and findnext
-
 
57
//________________________________________________________________________________________________________________________________________
-
 
58
 
-
 
59
typedef struct
-
 
60
{
-
 
61
        File_t  fp;                                             // filepointer used to get access to the filesystemstructure
-
 
62
        s8              searchstring[11];               // findfirst and findnext will only return elements within the specified directory matching this searchstring.
-
 
63
        s8              name[13];                               // the name of the element found within the specified directory
-
 
64
        u8              active;                                 // if the attribute active is set the name and the attributes of an element found within DirectoryEntryExist will be entered into the structure 
-
 
65
        u8              attribfilter;                  
-
 
66
        u8              attribmask;
Line 40... Line 67...
40
 
67
} __attribute__((packed)) Find_t;
41
 
68
 
42
//________________________________________________________________________________________________________________________________________
69
//________________________________________________________________________________________________________________________________________
43
// 
70
// 
Line 60... Line 87...
60
u32     fread_(void *buffer, u32 size, u32 count, File_t * const file);
87
u32     fread_(void *buffer, u32 size, u32 count, File_t * const file);
61
u32     fwrite_(void *buffer, u32 size, u32 count, File_t * const file);
88
u32     fwrite_(void *buffer, u32 size, u32 count, File_t * const file);
62
s16             fputs_(s8 * const string, File_t * const file);
89
s16             fputs_(s8 * const string, File_t * const file);
63
s8 *    fgets_(s8 * const string, s16 length, File_t * const file);
90
s8 *    fgets_(s8 * const string, s16 length, File_t * const file);
64
u8              feof_(File_t * const file);
91
u8              feof_(File_t * const file);
-
 
92
u8              findfirst_(const s8* name, u8 attribmask, Find_t *);
-
 
93
u8              findnext_(Find_t *);
-
 
94
u8              chdir_(s8 *folder);
-
 
95
s8              *GetPath(void);
-
 
96
 
Line 65... Line 97...
65
 
97