在OMAP-L138 C6000 DSP+ARM Processor Technical Reference Manual手册中的“27.3.2 MMC/SD Mode Single-Block Write Operation Using CPU”提到“13. Set the DMATRIG bit in MMCCMD to trigger the first data transfer.”,
但是在参考代码OMAP-L138 _FlashAndBootUtils_2_40中的SDMMCWriter内的写操作函数SDMMC_MEM_writeBytes中没有看到这个操作?
而且文档对于DMATRIG bit 的说明仅限于Table 27-18. MMC Command Register (MMCCMD) Field Descriptions中的:
0 Data transfer has not been triggered.
1 Data transfer is triggered.
Tony Tang:
你说的是这一段代码吧:
// Prime the FIFO with data status = SDMMC_writeNWords(hSDMMCInfo, (Uint32*)src, hSDMMCInfo->dataBytesPerOp); byteCnt -= hSDMMCInfo->dataBytesPerOp; src += hSDMMCInfo->dataBytesPerOp;
// Write Data, every time MMCDXR Reg full if (SDMMC_MEM_CAPACITY_TYPE_HIGH == hSDMMCMemInfo->capacity) { // Issue the write command to the device if(numBlks == 1) { status = SDMMC_sendCmd(hSDMMCInfo, 0x2800 | SDMMC_WRITE_BLOCK, addr >> hSDMMCInfo->dataBytesPerBlkPower2, 0); } else { status = SDMMC_sendCmd(hSDMMCInfo, 0x2880 | SDMMC_WRITE_MULTIPLE_BLOCK, addr >> hSDMMCInfo->dataBytesPerBlkPower2, 0); } } else { if(numBlks == 1) { status = SDMMC_sendCmd(hSDMMCInfo, 0x2800 | SDMMC_WRITE_BLOCK, addr, 0); } else { status = SDMMC_sendCmd(hSDMMCInfo, 0x2880 | SDMMC_WRITE_MULTIPLE_BLOCK, addr, 0); } }