This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMDS62LEVM: (RTOS eMMC) how to form a CMD(6) content to modify CSD/ECSD fields?

Part Number: TMDS62LEVM
Other Parts Discussed in Thread: CSD

Tool/software:

Hi,

From JEDEC doc. CMD6 can be used to modify the value of CSD/ECSD bytes of eMMC.

By looking into mmcsd_v1.c, to me it seems each field are forming differently.

trans.cmd = MMCSD_MMC_CMD(6);
trans.arg = (MMCSD_ECSD_ACCESS_MODE << 24U) | (MMCSD_ECSD_HS_TIMING_INDEX << 16U) | ((((obj->emmcData->driveStrength) << 4U) | 1U) << 8U);
trans.cmd = MMCSD_MMC_CMD(6);
trans.arg = 0x03000000 | (MMCSD_ECSD_BUS_WIDTH_INDEX << 16) | (((0 << MMCSD_ECSD_BUS_WIDTH_ES_SHIFT) | ecsdBusWidth) << 8);
trans.cmd = MMCSD_MMC_CMD(6);
trans.arg = 0x03000000 | (MMCSD_ECSD_HS_TIMING_INDEX << 16U) | ((((obj->emmcData->driveStrength) << 4U) | hsTimingVal) << 8U);

Is there a more generic way/function to modify the value a field? The eMMC I am trying to interact with is the on-EVM one.

Thank you,

Dazong

  • Hello,

    Is there a more generic way/function to modify the value a field? The eMMC I am trying to interact with is the on-EVM one.

    There is none. According to your requirements, you would have to derive the CMD6 argument value and use the MMCSD_transfer function to initiate the transaction.

    Regards,

    Prashant