cancel
Showing results for 
Search instead for 
Did you mean: 

is SDMMC1_CDIR (microSD pin2, STM32H743VIT on GPIO PB9) Needed for 1bit operation?

Zainka
Associate III

I believe this signal is not needed by the 1bit interface, that only D0, CMD and CK is required. However since I cant get my card responding I start questioning my design. I thought CDIR was only used for SD cards used in SPI mode?

Alternatively I may connect to a free IO to microSD pin 2, or thigh the CDIR pin to a certain level, (LOW for always select). But, I used CubeMX to generate code and it did not give any warning for not selecting SDMMC1_CDIR on PB9 when selecting 1bit mode so this pin is used for LTDC_B7 and stuck there, so if this is the problem, I must alter code to use the gpio I have available for command direction.

Thanks in advance

Vidar

4 REPLIES 4

No transceiver required for 3V operation in 1-bit mode

In stm32h7xx_hal_conf.f make sure you have :

#define USE_SD_TRANSCEIVER      0       /*!< don't use uSD Transceiver */

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Zainka
Associate III

Thanks Clive, ..

I did that but to no help, but then I noticed that the internal pull-ups was not turned on.

After also enabling these, the uSD card responded perfectly.

Thanks for you help

Thanks for reporting back. A lot of designs use external pull-ups, but absent those you'd want the internal ones enabled.

You can also back-off the speed setting, as for short wires don't need the most aggressive slew-rates.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..

Yes, I have set speed to MEDIUM. But for the moment I use a very low peripheral clock speed, only 10 MHz while I was chasing ghosts.

Will monitor the edges to find optimum speed and setting for my board later.

Breg

Vidar