| Periph ID AIC | Symbol | Description |
|---|---|---|
| 9 | (AT91C_ID_MCI) | Multimedia Card Interface 0 |
| Signal | Symbol | PIO controller | Description |
|---|---|---|---|
| MCDA0 | (AT91C_PA6_MCDA0 ) | PIOA Periph: A Bit: 6 | Multimedia Card A Data 0 |
| MCDA1 | (AT91C_PA9_MCDA1 ) | PIOA Periph: A Bit: 9 | Multimedia Card A Data 1 |
| MCCK | (AT91C_PA8_MCCK ) | PIOA Periph: A Bit: 8 | Multimedia Card Clock |
| MCDB0 | (AT91C_PA0_MCDB0 ) | PIOA Periph: B Bit: 0 | Multimedia Card B Data 0 |
| MCDA2 | (AT91C_PA10_MCDA2 ) | PIOA Periph: A Bit: 10 | Multimedia Card A Data 2 |
| MCDA3 | (AT91C_PA11_MCDA3 ) | PIOA Periph: A Bit: 11 | Multimedia Card A Data 3 |
| MCDB1 | (AT91C_PA5_MCDB1 ) | PIOA Periph: B Bit: 5 | Multimedia Card B Data 1 |
| MCCDA | (AT91C_PA7_MCCDA ) | PIOA Periph: A Bit: 7 | Multimedia Card A Command |
| MCDB2 | (AT91C_PA4_MCDB2 ) | PIOA Periph: B Bit: 4 | Multimedia Card B Data 2 |
| MCCDB | (AT91C_PA1_MCCDB ) | PIOA Periph: B Bit: 1 | Multimedia Card B Command |
| MCDB3 | (AT91C_PA3_MCDB3 ) | PIOA Periph: B Bit: 3 | Multimedia Card B Data 3 |
| Function | Description |
|---|---|
| AT91F_MCI_CfgPMC | Enable Peripheral clock in PMC for MCI |
| AT91F_MCI_CfgPIO | Configure PIO controllers to drive MCI signals |
| Offset | Field | Description |
|---|---|---|
| 0x0 | MCI_CR | MCI Control Register |
| 0x4 | MCI_MR | MCI Mode Register |
| 0x8 | MCI_DTOR | MCI Data Timeout Register |
| 0xC | MCI_SDCR | MCI SD Card Register |
| 0x10 | MCI_ARGR | MCI Argument Register |
| 0x14 | MCI_CMDR | MCI Command Register |
| 0x18 | MCI_BLKR | MCI Block Register |
| 0x20 | MCI_RSPR[4] (MCI_RSPR) | MCI Response Register |
| 0x30 | MCI_RDR | MCI Receive Data Register |
| 0x34 | MCI_TDR | MCI Transmit Data Register |
| 0x40 | MCI_SR | MCI Status Register |
| 0x44 | MCI_IER | MCI Interrupt Enable Register |
| 0x48 | MCI_IDR | MCI Interrupt Disable Register |
| 0x4C | MCI_IMR | MCI Interrupt Mask Register |
| 0xFC | MCI_VR | MCI Version Register |
| 0x100 | MCI_RPR (PDC_RPR) | Receive Pointer Register |
| 0x104 | MCI_RCR (PDC_RCR) | Receive Counter Register |
| 0x108 | MCI_TPR (PDC_TPR) | Transmit Pointer Register |
| 0x10C | MCI_TCR (PDC_TCR) | Transmit Counter Register |
| 0x110 | MCI_RNPR (PDC_RNPR) | Receive Next Pointer Register |
| 0x114 | MCI_RNCR (PDC_RNCR) | Receive Next Counter Register |
| 0x118 | MCI_TNPR (PDC_TNPR) | Transmit Next Pointer Register |
| 0x11C | MCI_TNCR (PDC_TNCR) | Transmit Next Counter Register |
| 0x120 | MCI_PTCR (PDC_PTCR) | PDC Transfer Control Register |
| 0x124 | MCI_PTSR (PDC_PTSR) | PDC Transfer Status Register |
| Function | Description |
|---|---|
| AT91F_MCI_GetStatus | Return MCI Interrupt Status |
| AT91F_MCI_GetDataTimeOutReg | Return the Data TimeOut Register of the MCI controller value |
| AT91F_MCI_Configure | Configure the MCI |
| AT91F_MCI_CfgModeReg | Configure the Mode Register of the MCI controller |
| AT91F_MCI_Enable | Enable the MCI Interface |
| AT91F_MCI_GetInterruptMaskStatus | Return MCI Interrupt Mask Status |
| AT91F_MCI_CfgDataTimeOutReg | Configure the Data TimeOut Register of the MCI controller |
| AT91F_MCI_GetARGReg | Return the Command ARGUMENT Register of the MCI controller value |
| AT91F_MCI_GetRSP0Reg | Return the RESPONSE Register 0 of the MCI controller value |
| AT91F_MCI_GetModeReg | Return the Mode Register of the MCI controller value |
| AT91F_MCI_IsStatusSet | Test if MCI Status is Set |
| AT91F_MCI_SW_Reset | Reset the MCI Interface |
| AT91F_MCI_GetRSP1Reg | Return the RESPONSE Register 1 of the MCI controller value |
| AT91F_MCI_Disable | Disable the MCI Interface |
| AT91F_MCI_CfgARGReg | Configure the Command ARGUMENT Register of the MCI controller |
| AT91F_MCI_CfgSDCardReg | Configure the SDCard Register of the MCI controller |
| AT91F_MCI_GetRSP2Reg | Return the RESPONSE Register 2 of the MCI controller value |
| AT91F_MCI_CfgFrequency | Configure the frequency MCCK of the MCI controller |
| AT91F_MCI_IsInterruptMasked | Test if MCI Interrupt is Masked |
| AT91F_MCI_EnableIt | Enable MCI IT |
| AT91F_MCI_GetRSP3Reg | Return the RESPONSE Register 3 of the MCI controller value |
| AT91F_MCI_CfgCMDReg | Configure the COMMAND Register of the MCI controller |
| AT91F_MCI_GetSDCardReg | Return the SDCard Register of the MCI controller value |
| AT91F_MCI_DisableIt | Disable MCI IT |
| Offset | Name | Description |
|---|---|---|
| 0 | MCI_MCIEN AT91C_MCI_MCIEN | Multimedia Interface Enable 0: No effect. 1: Enables the MultiMedia Interface if MCIDIS is 0. |
| 1 | MCI_MCIDIS AT91C_MCI_MCIDIS | Multimedia Interface Disable 0: No effect. 1: Disables the MultiMedia Interface. |
| 2 | MCI_PWSEN AT91C_MCI_PWSEN | Power Save Mode Enable 0: No effect. 1: Enables the Power-saving mode if PWSDIS is 0. |
| 3 | MCI_PWSDIS AT91C_MCI_PWSDIS | Power Save Mode Disable 0: No effect. 1: Disables the Power-saving mode. |
| 7 | MCI_SWRST AT91C_MCI_SWRST | MCI Software reset 0 = No effect. 1 = Resets the MCI. A software triggered hardware reset of the MCI interface is performed. |
| Offset | Name | Description |
|---|---|---|
| 7..0 | MCI_CLKDIV AT91C_MCI_CLKDIV | Clock Divider MultiMedia Card Interface clock is Master Clock (MCK) divided by (2*(CLKDIV+1)). |
| 10..8 | MCI_PWSDIV AT91C_MCI_PWSDIV | Power Saving Divider MultiMedia Card Interface clock is divided by 2 power PWSDIV when entering Power-saving mode. If PWSDIV is 0x00 then MultiMedia Card Interface clock is stopped when entering Power-saving mode. |
| 11 | MCI_RDPROOF AT91C_MCI_RDPROOF | Read Proof Enable 0: Disables Read Proof 1: Enables Read Proof |
| 12 | MCI_WRPROOF AT91C_MCI_WRPROOF | Write Proof Enable 0: Disables Write Proof 1: Enables Write Proof |
| 13 | MCI_PDCFBYTE AT91C_MCI_PDCFBYTE | PDC Force Byte Transfer 0: Disables PDC Force Byte Transfer 1: Enables PDC Force Byte Transfer |
| 14 | MCI_PDCPADV AT91C_MCI_PDCPADV | PDC Padding Value 0: 0x00 value is used when padding data in PDC write transfer (non-multiple block size PDC write) 1: 0xFF value is used when padding data in PDC write transfer (non-multiple block size PDC write) |
| 15 | MCI_PDCMODE AT91C_MCI_PDCMODE | PDC Oriented Mode 0: Disables PDC transfer 1: Enables PDC transfer |
| 31..16 | MCI_BLKLEN AT91C_MCI_BLKLEN | Data Block Length This field determines the size of the data block. Bits 16 and 17 must be set to 0 if PDCFBYTE is disabled. |
| Offset | Name | Description | |||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 3..0 | MCI_DTOCYC AT91C_MCI_DTOCYC | Data Timeout Cycle Number | |||||||||||||||||||||||||||
| 6..4 | MCI_DTOMUL AT91C_MCI_DTOMUL | Data Timeout Multiplier These fields determine the maximum number of clock cycles that the MCI waits between 2 data block transfers. It equals (DTOCYC x Multiplier).
|
| Offset | Name | Description |
|---|---|---|
| 1..0 | MCI_SCDSEL AT91C_MCI_SCDSEL | SD Card Selector 0: Slot A selected 1: Slot B selected 2: Slot C selected 3: Slot D selected |
| 7 | MCI_SCDBUS AT91C_MCI_SCDBUS | SDCard/SDIO Bus Width 0: 1-bit data bus 1: 4-bit data bus |
| Offset | Name | Description | ||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 5..0 | MCI_CMDNB AT91C_MCI_CMDNB | Command Number | ||||||||||||||||||
| 7..6 | MCI_RSPTYP AT91C_MCI_RSPTYP | Response Type
| ||||||||||||||||||
| 10..8 | MCI_SPCMD AT91C_MCI_SPCMD | Special CMD
| ||||||||||||||||||
| 11 | MCI_OPDCMD AT91C_MCI_OPDCMD | Open Drain Command 0: Push/pull command 1: Open drain command | ||||||||||||||||||
| 12 | MCI_MAXLAT AT91C_MCI_MAXLAT | Maximum Latency for Command to respond 0: 5 cycles maximum latency 1: 64 cycles maximum latency | ||||||||||||||||||
| 17..16 | MCI_TRCMD AT91C_MCI_TRCMD | Transfer CMD
| ||||||||||||||||||
| 18 | MCI_TRDIR AT91C_MCI_TRDIR | Transfer Direction 0: Write 1: Read | ||||||||||||||||||
| 21..19 | MCI_TRTYP AT91C_MCI_TRTYP | Transfer Type
| ||||||||||||||||||
| 25..24 | MCI_IOSPCMD AT91C_MCI_IOSPCMD | SDIO Special Command
|
| Offset | Name | Description |
|---|---|---|
| 15..0 | MCI_BCNT AT91C_MCI_BCNT | MMC/SDIO Block Count / SDIO Byte Count This field determines the number of data byte(s) or block(s) to transfer. This depends on TRTYP field. |
| 31..16 | MCI_BLKLEN AT91C_MCI_BLKLEN | Data Block Length This field determines the size of the data block. Bits 16 and 17 must be set to 0 if PDCFBYTE is disabled. |
| Offset | Name | Description |
|---|---|---|
| 0 | MCI_CMDRDY AT91C_MCI_CMDRDY | Command Ready flag |
| 1 | MCI_RXRDY AT91C_MCI_RXRDY | RX Ready flag |
| 2 | MCI_TXRDY AT91C_MCI_TXRDY | TX Ready flag |
| 3 | MCI_BLKE AT91C_MCI_BLKE | Data Block Transfer Ended flag |
| 4 | MCI_DTIP AT91C_MCI_DTIP | Data Transfer in Progress flag |
| 5 | MCI_NOTBUSY AT91C_MCI_NOTBUSY | Data Line Not Busy flag |
| 6 | MCI_ENDRX AT91C_MCI_ENDRX | End of RX Buffer flag |
| 7 | MCI_ENDTX AT91C_MCI_ENDTX | End of TX Buffer flag |
| 8 | MCI_SDIOIRQA AT91C_MCI_SDIOIRQA | SDIO Interrupt for Slot A |
| 9 | MCI_SDIOIRQB AT91C_MCI_SDIOIRQB | SDIO Interrupt for Slot B |
| 10 | MCI_SDIOIRQC AT91C_MCI_SDIOIRQC | SDIO Interrupt for Slot C |
| 11 | MCI_SDIOIRQD AT91C_MCI_SDIOIRQD | SDIO Interrupt for Slot D |
| 14 | MCI_RXBUFF AT91C_MCI_RXBUFF | RX Buffer Full flag |
| 15 | MCI_TXBUFE AT91C_MCI_TXBUFE | TX Buffer Empty flag |
| 16 | MCI_RINDE AT91C_MCI_RINDE | Response Index Error flag |
| 17 | MCI_RDIRE AT91C_MCI_RDIRE | Response Direction Error flag |
| 18 | MCI_RCRCE AT91C_MCI_RCRCE | Response CRC Error flag |
| 19 | MCI_RENDE AT91C_MCI_RENDE | Response End Bit Error flag |
| 20 | MCI_RTOE AT91C_MCI_RTOE | Response Time-out Error flag |
| 21 | MCI_DCRCE AT91C_MCI_DCRCE | data CRC Error flag |
| 22 | MCI_DTOE AT91C_MCI_DTOE | Data timeout Error flag |
| 30 | MCI_OVRE AT91C_MCI_OVRE | Overrun flag |
| 31 | MCI_UNRE AT91C_MCI_UNRE | Underrun flag |
| Offset | Name | Description |
|---|---|---|
| 0 | MCI_CMDRDY AT91C_MCI_CMDRDY | Command Ready flag |
| 1 | MCI_RXRDY AT91C_MCI_RXRDY | RX Ready flag |
| 2 | MCI_TXRDY AT91C_MCI_TXRDY | TX Ready flag |
| 3 | MCI_BLKE AT91C_MCI_BLKE | Data Block Transfer Ended flag |
| 4 | MCI_DTIP AT91C_MCI_DTIP | Data Transfer in Progress flag |
| 5 | MCI_NOTBUSY AT91C_MCI_NOTBUSY | Data Line Not Busy flag |
| 6 | MCI_ENDRX AT91C_MCI_ENDRX | End of RX Buffer flag |
| 7 | MCI_ENDTX AT91C_MCI_ENDTX | End of TX Buffer flag |
| 8 | MCI_SDIOIRQA AT91C_MCI_SDIOIRQA | SDIO Interrupt for Slot A |
| 9 | MCI_SDIOIRQB AT91C_MCI_SDIOIRQB | SDIO Interrupt for Slot B |
| 10 | MCI_SDIOIRQC AT91C_MCI_SDIOIRQC | SDIO Interrupt for Slot C |
| 11 | MCI_SDIOIRQD AT91C_MCI_SDIOIRQD | SDIO Interrupt for Slot D |
| 14 | MCI_RXBUFF AT91C_MCI_RXBUFF | RX Buffer Full flag |
| 15 | MCI_TXBUFE AT91C_MCI_TXBUFE | TX Buffer Empty flag |
| 16 | MCI_RINDE AT91C_MCI_RINDE | Response Index Error flag |
| 17 | MCI_RDIRE AT91C_MCI_RDIRE | Response Direction Error flag |
| 18 | MCI_RCRCE AT91C_MCI_RCRCE | Response CRC Error flag |
| 19 | MCI_RENDE AT91C_MCI_RENDE | Response End Bit Error flag |
| 20 | MCI_RTOE AT91C_MCI_RTOE | Response Time-out Error flag |
| 21 | MCI_DCRCE AT91C_MCI_DCRCE | data CRC Error flag |
| 22 | MCI_DTOE AT91C_MCI_DTOE | Data timeout Error flag |
| 30 | MCI_OVRE AT91C_MCI_OVRE | Overrun flag |
| 31 | MCI_UNRE AT91C_MCI_UNRE | Underrun flag |
| Offset | Name | Description |
|---|---|---|
| 0 | MCI_CMDRDY AT91C_MCI_CMDRDY | Command Ready flag |
| 1 | MCI_RXRDY AT91C_MCI_RXRDY | RX Ready flag |
| 2 | MCI_TXRDY AT91C_MCI_TXRDY | TX Ready flag |
| 3 | MCI_BLKE AT91C_MCI_BLKE | Data Block Transfer Ended flag |
| 4 | MCI_DTIP AT91C_MCI_DTIP | Data Transfer in Progress flag |
| 5 | MCI_NOTBUSY AT91C_MCI_NOTBUSY | Data Line Not Busy flag |
| 6 | MCI_ENDRX AT91C_MCI_ENDRX | End of RX Buffer flag |
| 7 | MCI_ENDTX AT91C_MCI_ENDTX | End of TX Buffer flag |
| 8 | MCI_SDIOIRQA AT91C_MCI_SDIOIRQA | SDIO Interrupt for Slot A |
| 9 | MCI_SDIOIRQB AT91C_MCI_SDIOIRQB | SDIO Interrupt for Slot B |
| 10 | MCI_SDIOIRQC AT91C_MCI_SDIOIRQC | SDIO Interrupt for Slot C |
| 11 | MCI_SDIOIRQD AT91C_MCI_SDIOIRQD | SDIO Interrupt for Slot D |
| 14 | MCI_RXBUFF AT91C_MCI_RXBUFF | RX Buffer Full flag |
| 15 | MCI_TXBUFE AT91C_MCI_TXBUFE | TX Buffer Empty flag |
| 16 | MCI_RINDE AT91C_MCI_RINDE | Response Index Error flag |
| 17 | MCI_RDIRE AT91C_MCI_RDIRE | Response Direction Error flag |
| 18 | MCI_RCRCE AT91C_MCI_RCRCE | Response CRC Error flag |
| 19 | MCI_RENDE AT91C_MCI_RENDE | Response End Bit Error flag |
| 20 | MCI_RTOE AT91C_MCI_RTOE | Response Time-out Error flag |
| 21 | MCI_DCRCE AT91C_MCI_DCRCE | data CRC Error flag |
| 22 | MCI_DTOE AT91C_MCI_DTOE | Data timeout Error flag |
| 30 | MCI_OVRE AT91C_MCI_OVRE | Overrun flag |
| 31 | MCI_UNRE AT91C_MCI_UNRE | Underrun flag |
| Offset | Name | Description |
|---|---|---|
| 0 | MCI_CMDRDY AT91C_MCI_CMDRDY | Command Ready flag |
| 1 | MCI_RXRDY AT91C_MCI_RXRDY | RX Ready flag |
| 2 | MCI_TXRDY AT91C_MCI_TXRDY | TX Ready flag |
| 3 | MCI_BLKE AT91C_MCI_BLKE | Data Block Transfer Ended flag |
| 4 | MCI_DTIP AT91C_MCI_DTIP | Data Transfer in Progress flag |
| 5 | MCI_NOTBUSY AT91C_MCI_NOTBUSY | Data Line Not Busy flag |
| 6 | MCI_ENDRX AT91C_MCI_ENDRX | End of RX Buffer flag |
| 7 | MCI_ENDTX AT91C_MCI_ENDTX | End of TX Buffer flag |
| 8 | MCI_SDIOIRQA AT91C_MCI_SDIOIRQA | SDIO Interrupt for Slot A |
| 9 | MCI_SDIOIRQB AT91C_MCI_SDIOIRQB | SDIO Interrupt for Slot B |
| 10 | MCI_SDIOIRQC AT91C_MCI_SDIOIRQC | SDIO Interrupt for Slot C |
| 11 | MCI_SDIOIRQD AT91C_MCI_SDIOIRQD | SDIO Interrupt for Slot D |
| 14 | MCI_RXBUFF AT91C_MCI_RXBUFF | RX Buffer Full flag |
| 15 | MCI_TXBUFE AT91C_MCI_TXBUFE | TX Buffer Empty flag |
| 16 | MCI_RINDE AT91C_MCI_RINDE | Response Index Error flag |
| 17 | MCI_RDIRE AT91C_MCI_RDIRE | Response Direction Error flag |
| 18 | MCI_RCRCE AT91C_MCI_RCRCE | Response CRC Error flag |
| 19 | MCI_RENDE AT91C_MCI_RENDE | Response End Bit Error flag |
| 20 | MCI_RTOE AT91C_MCI_RTOE | Response Time-out Error flag |
| 21 | MCI_DCRCE AT91C_MCI_DCRCE | data CRC Error flag |
| 22 | MCI_DTOE AT91C_MCI_DTOE | Data timeout Error flag |
| 30 | MCI_OVRE AT91C_MCI_OVRE | Overrun flag |
| 31 | MCI_UNRE AT91C_MCI_UNRE | Underrun flag |