cancel
Showing results for 
Search instead for 
Did you mean: 

sdmmc not working with 4-bit mode but working only with 1-bit mode

Denish23
Associate

MCU = STM32L433RCTx

STM32 CubeIDE version - 6.8.0

I'm working on sd card operation using sdmmc 4-bit mode but it is not working. but when I select 1-bit sdmmc mode so it is working as well.

I want to know how can I resolve this issue. my sd card connector is MSD-4-A and there are all line connected with 47k pullup resister leaving CLK pin.

SDMMC Init -

hsd1.Instance = SDMMC1;
hsd1.Init.ClockEdge = SDMMC_CLOCK_EDGE_RISING;
hsd1.Init.ClockBypass = SDMMC_CLOCK_BYPASS_DISABLE;
hsd1.Init.ClockPowerSave = SDMMC_CLOCK_POWER_SAVE_DISABLE;
hsd1.Init.BusWide = SDMMC_BUS_WIDE_4B;
hsd1.Init.HardwareFlowControl = SDMMC_HARDWARE_FLOW_CONTROL_DISABLE;
hsd1.Init.ClockDiv = 4;

there are lots of post available related this issue but can not clear proper solution. In some post there are talking bug in firmware in latest version. if yes so how can I resolve it.

Thanks in advance.

1 ACCEPTED SOLUTION

Accepted Solutions
SofLit
ST Employee

Hello,

See these threads:

https://community.st.com/t5/stm32cubemx-mcus/sdcard-does-not-work-fr-not-ready-when-migrating-from-fw-f4-v1/m-p/115500#M3877

https://community.st.com/t5/stm32cubemx-mcus/problems-with-stm32f405-sd-card-4wirescubemx/m-p/139892

https://community.st.com/t5/stm32cubeide-mcus/stm32cubeide-sdmmc-mode-unable-to-set-sd-4-bit-mode-bug-report/td-p/286133

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.
PS:
1 - This is NOT an online support (https://ols.st.com) but a collaborative space.
2 - Please be polite in your reply. Otherwise, it will be reported as inappropriate and you will be permanently blacklisted from my help.

View solution in original post

1 REPLY 1
SofLit
ST Employee

Hello,

See these threads:

https://community.st.com/t5/stm32cubemx-mcus/sdcard-does-not-work-fr-not-ready-when-migrating-from-fw-f4-v1/m-p/115500#M3877

https://community.st.com/t5/stm32cubemx-mcus/problems-with-stm32f405-sd-card-4wirescubemx/m-p/139892

https://community.st.com/t5/stm32cubeide-mcus/stm32cubeide-sdmmc-mode-unable-to-set-sd-4-bit-mode-bug-report/td-p/286133

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.
PS:
1 - This is NOT an online support (https://ols.st.com) but a collaborative space.
2 - Please be polite in your reply. Otherwise, it will be reported as inappropriate and you will be permanently blacklisted from my help.