FreeRTOS-Plus-FAT stores information that is common to all media types in a
structure of type FF_Disk_t. Media drivers can extended the FF_Disk_t structure
to include additional information that is specific to the media in use.
For example, the
initialisation
function used by FreeRTOS-Plus-FAT's RAM disk driver extends the FF_Disk_t
structure to include a pointer to the RAM buffer used as the disk.
The pxIOManager member of the FF_Disk_t structure is created by calling
FF_CreateIOManager().
It is advisable to clear the entire structure to zero after it has been
allocated - that way the media driver will be compatible with future
FreeRTOS-Plus-FAT versions, in which the FF_Disk_t structure may include
additional members.
struct xFFDisk
{
struct
{
uint32_t bIsInitialised : 1;
uint32_t bIsRegistered : 1;
uint32_t bIsMounted : 1;
uint32_t spare0 : 5;
uint32_t bPartitionNumber : 8;
uint32_t spare1 : 16;
} xStatus;
void *pvTag;
FF_IOManager_t *pxIOManager;
uint32_t ulNumberOfSectors;
uint32_t ulSignature;
};
typedef struct xFFDisk FF_Disk_t;
The FF_Disk_t structure
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.