+++ /dev/null
-/*-----------------------------------------------------------------------/\r
-/ Low level disk interface modlue include file (C)ChaN, 2014 /\r
-/-----------------------------------------------------------------------*/\r
-\r
-#ifndef _DISKIO_DEFINED\r
-#define _DISKIO_DEFINED\r
-\r
-#ifdef __cplusplus\r
-extern "C" {\r
-#endif\r
-\r
-#define _USE_WRITE 1 /* 1: Enable disk_write function */\r
-#define _USE_IOCTL 1 /* 1: Enable disk_ioctl fucntion */\r
-\r
-#include "integer.h"\r
-\r
-\r
-/* Status of Disk Functions */\r
-typedef BYTE DSTATUS;\r
-\r
-/* Results of Disk Functions */\r
-typedef enum {\r
- RES_OK = 0, /* 0: Successful */\r
- RES_ERROR, /* 1: R/W Error */\r
- RES_WRPRT, /* 2: Write Protected */\r
- RES_NOTRDY, /* 3: Not Ready */\r
- RES_PARERR /* 4: Invalid Parameter */\r
-} DRESULT;\r
-\r
-\r
-/*---------------------------------------*/\r
-/* Prototypes for disk control functions */\r
-\r
-\r
-DSTATUS disk_initialize (BYTE pdrv);\r
-DSTATUS disk_status (BYTE pdrv);\r
-DRESULT disk_read (BYTE pdrv, BYTE* buff, DWORD sector, UINT count);\r
-DRESULT disk_write (BYTE pdrv, const BYTE* buff, DWORD sector, UINT count);\r
-DRESULT disk_ioctl (BYTE pdrv, BYTE cmd, void* buff);\r
-\r
-\r
-/* Disk Status Bits (DSTATUS) */\r
-\r
-#define STA_NOINIT 0x01 /* Drive not initialized */\r
-#define STA_NODISK 0x02 /* No medium in the drive */\r
-#define STA_PROTECT 0x04 /* Write protected */\r
-\r
-\r
-/* Command code for disk_ioctrl fucntion */\r
-\r
-/* Generic command (Used by FatFs) */\r
-#define CTRL_SYNC 0 /* Complete pending write process (needed at _FS_READONLY == 0) */\r
-#define GET_SECTOR_COUNT 1 /* Get media size (needed at _USE_MKFS == 1) */\r
-#define GET_SECTOR_SIZE 2 /* Get sector size (needed at _MAX_SS != _MIN_SS) */\r
-#define GET_BLOCK_SIZE 3 /* Get erase block size (needed at _USE_MKFS == 1) */\r
-#define CTRL_TRIM 4 /* Inform device that the data on the block of sectors is no longer used (needed at _USE_TRIM == 1) */\r
-\r
-/* Generic command (Not used by FatFs) */\r
-#define CTRL_POWER 5 /* Get/Set power status */\r
-#define CTRL_LOCK 6 /* Lock/Unlock media removal */\r
-#define CTRL_EJECT 7 /* Eject media */\r
-#define CTRL_FORMAT 8 /* Create physical format on the media */\r
-\r
-/* MMC/SDC specific ioctl command */\r
-#define MMC_GET_TYPE 10 /* Get card type */\r
-#define MMC_GET_CSD 11 /* Get CSD */\r
-#define MMC_GET_CID 12 /* Get CID */\r
-#define MMC_GET_OCR 13 /* Get OCR */\r
-#define MMC_GET_SDSTAT 14 /* Get SD status */\r
-\r
-/* ATA/CF specific ioctl command */\r
-#define ATA_GET_REV 20 /* Get F/W revision */\r
-#define ATA_GET_MODEL 21 /* Get model name */\r
-#define ATA_GET_SN 22 /* Get serial number */\r
-\r
-#ifdef __cplusplus\r
-}\r
-#endif\r
-\r
-#endif\r