Expand description
§SD/MMC/eMMC Driver Library
This library provides a no_std driver for SD, MMC, and eMMC storage devices on ARM64 platforms, specifically optimized for Rockchip RK3568/RK3588 platforms.
§Features
- no_std compatible: Works without the standard library
- eMMC 4.x/5.x support: Full support for eMMC standards including HS200/HS400 modes
- SD/SDIO support: Support for SD 1.0/2.0 and SDIO devices
- PIO and DMA modes: Choose between programmed I/O or DMA for data transfers
- Rockchip optimization: Specifically optimized for Rockchip platforms with DWCMSHC controller
- Type-safe register access: Safe hardware register operations
§Platform Support
Currently optimized for:
- Rockchip RK3568
- Rockchip RK3588
- Other platforms using DWCMSHC SDHCI controller
§Usage Example
use sdmmc::emmc::EMmcHost;
// Create EMMC controller instance at hardware base address
let mut emmc = EMmcHost::new(0xfe2e0000);
// Initialize the controller and card
match emmc.init() {
Ok(_) => {
println!("EMMC initialized successfully");
}
Err(e) => {
println!("EMMC initialization failed: {:?}", e);
}
}§Features
pio(default): Use PIO (Programmed I/O) for data transfersdma: Use DMA (Direct Memory Access) for data transfers
§Modules
Modules§
Macros§
- set_
impl - Register a Kernel implementation for delay functions
Constants§
Traits§
- Kernel
- Kernel trait for platform-specific delay implementation
Functions§
- dump_
memory_ ⚠region - Dump memory region for debugging purposes