Functional Description
MOTOROLA
Multimedia Card/Secure Digital Host Controller Module (MMC/SD)
20-7
20.5.1.1 DMA Burst Request
In the MMC/SD module, there is a 32
×
16-bit FIFO to decrease the latency during the data transfer on the
MMC/SD bus. The FIFO is configured differently for 1-bit and 4-bit access modes. The FIFO is operated
as four 8
×
16-bit FIFOs for 1-bit access and as one 32
×
16-bit FIFO for 4-bit access.
Code Example 20-1. DMA Configuration Example
// DMAC init for SDHC channel setup
*(P_U32)DMA_DCR
= 0x0001;
// Enable the DMA (DEN)
*(P_U32)DMA_IMR
= 0x07FF;
// Disable all I/O Channel IRQ
if (direction == 1){
//write
*(P_U32)DMA_SAR1
= Memory_Addr;
// Source Address
*(P_U32)DMA_DAR1
= 0x00214038;
// Destination Address
}
else{
//read
*(P_U32)DMA_DAR1
= Memory_Addr;
// Destination Address
*(P_U32)DMA_SAR1
= 0x00214038;
// Source Address
}
*(P_U32)DMA_CNTR1
= Size;
// Set No of Byte transfer
*(P_U32)DMA_CCR1
= dir;
// Ch1: FIFO as the target, Linear Mem source,
// Mem inc, 16-bit target, 32-bit source,
// Request Enable, DMA Disable
*(P_U32)DMA_RSSR1
= 0x000D;
// Ch1: DMA request select; SDHC is bit[13]
if(SD_4bit_enable)
*(P_U32)DMA_BLR1
= 0x0000;
// Ch1: No. of FIFO to be read, burst length x32
else
*(P_U32)DMA_BLR1
= 0x0010;
// Ch1: No. of FIFO to be read, burst length x8
// Start DMA and Poll end of DMA transfer done
*(P_U32)DMA_ISR
= 0x0002;
// Clear DMA ISR for MMC
*(P_U32)DMA_CCR1
= dir_en;
// Ch1: FIFO as the target, Linear Mem source,
// Mem inc, 16-bit target, 32-bit source,
// Request Enable, DMA Enable
while ( ((*(P_U32)DMA_ISR) & 0x2) ==0 );//wait for the data transfer complete
*(P_U32)DMA_ISR
= 0x0002;
// Clear DMA ISR for MMC
*(P_U32)DMA_CCR1
= dir;
// Ch1: FIFO as the target, Linear Mem source,
// Mem inc, 16-bit target, 32-bit source,
// Request Enable, DMA Disable
// End of DMA usage
Summary of Contents for DragonBall MC9328MX1
Page 68: ...1 12 MC9328MX1 Reference Manual MOTOROLA Introduction ...
Page 86: ...2 18 MC9328MX1 Reference Manual MOTOROLA Signal Descriptions and Pin Assignments ...
Page 116: ...3 30 MC9328MX1 Reference Manual MOTOROLA Memory Map ...
Page 126: ...4 10 MC9328MX1 Reference Manual MOTOROLA ARM920T Processor ...
Page 160: ...8 8 MC9328MX1 Reference Manual MOTOROLA System Control ...
Page 272: ...13 32 MC9328MX1 Reference Manual MOTOROLA DMA Controller ...
Page 281: ...Programming Model MOTOROLA Watchdog Timer Module 14 9 ...
Page 282: ...14 10 MC9328MX1 Reference Manual MOTOROLA Watchdog Timer Module ...
Page 300: ...15 18 MC9328MX1 Reference Manual MOTOROLA Analog Signal Processor ASP ...
Page 438: ...18 16 MC9328MX1 Reference Manual MOTOROLA Serial Peripheral Interface Modules SPI 1 and SPI 2 ...
Page 478: ...19 40 MC9328MX1 Reference Manual MOTOROLA LCD Controller ...
Page 574: ...21 32 MC9328MX1 Reference Manual MOTOROLA Memory Stick Host Controller MSHC Module ...
Page 598: ...23 16 MC9328MX1 Reference Manual MOTOROLA Real Time Clock RTC ...
Page 670: ...24 72 MC9328MX1 Reference Manual MOTOROLA SDRAM Memory Controller ...
Page 726: ...25 56 MC9328MX1 Reference Manual MOTOROLA SmartCard Interface Module SIM ...
Page 736: ...26 10 MC9328MX1 Reference Manual MOTOROLA General Purpose Timers ...
Page 854: ...29 18 MC9328MX1 Reference Manual MOTOROLA I2C Module ...
Page 900: ...30 46 MC9328MX1 Reference Manual MOTOROLA Synchronous Serial Interface SSI ...
Page 942: ...32 26 MC9328MX1 Reference Manual MOTOROLA GPIO Module and I O Multiplexer IOMUX ...