2024-05-02 11:10 AM
Hello,
I am working on trying to get the SDMMC1 on the stm32h745 to function properly. Currently I have this for my current initialization of the SDMMC and it does not return any errors.
hsd1.Instance = SDMMC1;
hsd1.Init.ClockEdge = SDMMC_CLOCK_EDGE_RISING;
hsd1.Init.ClockPowerSave = SDMMC_CLOCK_POWER_SAVE_DISABLE;
hsd1.Init.BusWide = SDMMC_BUS_WIDE_1B;
hsd1.Init.HardwareFlowControl = SDMMC_HARDWARE_FLOW_CONTROL_DISABLE;
hsd1.Init.ClockDiv = 0;
if (HAL_SD_Init(&hsd1) != HAL_OK) {
Error_Handler();
}
if (HAL_SD_ConfigWideBusOperation(&hsd1, SDMMC_BUS_WIDE_4B) != HAL_OK) {
Error_Handler();
}
After this is done, I try to use the HAL_SD_ReadBlocks_IT(); and also this does not return any errors. The issue I am having is the return data buffer has no data in it when this function finishes. Currently I am not sure what the issue might be, the clocks and appear as they are sending data but I am getting nothing in my return data. Any thoughts or ideas on what might resolve this problem?
Thanks
2024-05-09 01:38 PM
I have tried using medium to very high and not found a difference in the speed I increase the clock. The series resistors are 220 ohms and the pull up resistors are 47.5k.
2024-05-09 01:53 PM - edited 2024-05-09 01:55 PM
220 is too much - try 51 or 33 . And medium or hi speed . And 1 bit mode.
2024-05-09 02:34 PM
Actually the series resistor is 22ohm, sorry i misread when looking.