AvrIO  1.4.5
Bibliothèque C modulaire pour ATMEL AVR
mmc.h
1 
23 #ifndef _AVRIO_MMC_H_
24 #define _AVRIO_MMC_H_
25 
26 #include <avrio/defs.h>
27 
28 __BEGIN_C_DECLS
29 /* ========================================================================== */
50 /* constants ================================================================ */
56 #define MMC_SECTOR_SIZE 512
57 
62 typedef enum {
63 
64  MMC_SUCCESS = 1,
65  MMC_ERROR = 0
66 } eMmcError;
67 
68 /* internal public functions ================================================ */
78 int iMmcOpen (void);
79 void vMmcInit (void);
80 void vMmcClose (void);
81 bool xMmcIsOpen (void);
82 bool xMmcIsDetected (void);
83 bool xMmcIsReadOnly (void);
84 
94 int iMmcWriteSector (uint32_t ulSector, uint8_t * pucBuffer, uint32_t ulSectorCount);
95 
105 int iMmcReadSector (uint32_t ulSector, uint8_t * pucBuffer, uint32_t ulSectorCount);
106 
111 /* ========================================================================== */
112 __END_C_DECLS
113 #endif /* _AVRIO_MMC_H_ not defined */
int iMmcOpen(void)
Initialise le module cartes MMC/SD.
eMmcError
Erreurs renvoyées par les fonctions du module MMC.
Definition: mmc.h:62
int iMmcWriteSector(uint32_t ulSector, uint8_t *pucBuffer, uint32_t ulSectorCount)
Ecriture de secteurs MMC/SD de 512 octets.
int iMmcReadSector(uint32_t ulSector, uint8_t *pucBuffer, uint32_t ulSectorCount)
Lecture de secteurs MMC/SD de 512 octets.