HydraFW binary MMC mode guide - hydrabus/hydrafw GitHub Wiki
HydraFW binary MMC mode guide
This guide is updated towards firmware release HydraFW v0.11 and later
This mode is specific to MMC/eMMC (and it does not support SDCard).
- For SDCard support, see SDIO
This mode allows to control MMC
- MMC pins: CLK=PC12, CMD=PD2, D0=PC8, D1=PC9, D2=PC10, D3=PC11
For more details see https://github.com/hydrabus/hydrafw/wiki/HydraFW-MMC-guide
Commands
Once the MMC mode has been selected, the following commands are available :
0b00000000Return to main mode. Returns BBIO10b00000001Mode identification. ReturnsMMC10b00000010Read CID0b00000011Read CSD0b00000100Read block0b00000101Write block0b00000110Read EXT_CSD0b1000000xConfigure MMC interface
Command details
Read CID (0b00000010)
This command will reply with 16 bytes containing the card CID.
Read CSD (0b00000011)
This command will reply with 16 bytes containing the card CSD.
Read block (0b00000100)
This command will read the next 4 bytes as the block number (little-endian). The command will reply 0x01 followed by the resulting block data (512 bytes). It will reply 0x00 in case of error.
Write block (0b00000101)
This command will read the next 4 bytes as the block number (little-endian), then 512 bytes of data. The command will reply 0x01 if successful, 0x00 otherwise.
Read EXT_CSD (0b00000110)
The command will reply 0x01 followed by 512 bytes of EXT_CSD register value if successful, 0x00 otherwise.
Configure MMC interface (0b1000000x)
The x value is used to set the MMC bus width :
0is 1-bit mode1is 4-bit mode