source: thomson/code/C/HxCHost/pff/diskio.h@ 645c148

main
Last change on this file since 645c148 was 645c148, checked in by Adrien Destugues <pulkomandy@…>, 12 years ago

Add WIP HxC host software for Thomson computers.
Not working yet because of timing problems...

git-svn-id: svn://localhost/thomson@3 85ae3b6b-dc8f-4344-a89d-598714f2e4e5

  • Property mode set to 100644
File size: 1.1 KB
Line 
1/*-----------------------------------------------------------------------
2/ PFF - Low level disk interface modlue include file (C)ChaN, 2009
3/-----------------------------------------------------------------------*/
4
5#ifndef _DISKIO
6
7#include "integer.h"
8
9
10/* Status of Disk Functions */
11typedef BYTE DSTATUS;
12
13
14/* Results of Disk Functions */
15typedef enum {
16 RES_OK = 0, /* 0: Function succeeded */
17 RES_ERROR, /* 1: Disk error */
18 RES_NOTRDY, /* 2: Not ready */
19 RES_PARERR /* 3: Invalid parameter */
20} DRESULT;
21
22
23/*---------------------------------------*/
24/* Prototypes for disk control functions */
25
26DSTATUS disk_initialize (void);
27DRESULT disk_readp (BYTE*, DWORD, WORD, WORD);
28DRESULT disk_writep (const BYTE*, DWORD);
29
30#define STA_NOINIT 0x01 /* Drive not initialized */
31#define STA_NODISK 0x02 /* No medium in the drive */
32
33/* Card type flags (CardType) */
34#define CT_MMC 0x01 /* MMC ver 3 */
35#define CT_SD1 0x02 /* SD ver 1 */
36#define CT_SD2 0x04 /* SD ver 2 */
37#define CT_SDC (CT_SD1|CT_SD2) /* SD */
38#define CT_BLOCK 0x08 /* Block addressing */
39
40#define _DISKIO
41#endif
Note: See TracBrowser for help on using the repository browser.