DIR

The DIR structure is used for the work area to read a directory by f_oepndir, f_readdir function. There is no member that can be changed by application program.

typedef struct {
    FATFS*  fs;         /* Pointer to the owner file system object */
    WORD    id;         /* Owner file system mount ID */
    WORD    index;      /* Index of directory entry to start to search next */
    DWORD   sclust;     /* Table start cluster (0:Root dir) */
    DWORD   clust;      /* Current cluster */
    DWORD   sect;       /* Current sector */
    BYTE*   dir;        /* Pointer to the current SFN entry in the win[] */
    BYTE*   fn;         /* Pointer to the SFN (in/out) {file[8],ext[3],status[1]} */
#if _USE_LFN
    WCHAR*  lfn;        /* Pointer to the LFN working buffer */
    WORD    lfn_idx;    /* Index of last matched LFN entry (0xFFFF:No LFN) */
#endif
} DIR;

Return