SPI speed when using SDHC via SPI in Zephyr #32996
Labels
area: Disk Access
area: Drivers
bug
The issue is a bug, or the PR is fixing a bug
priority: low
Low impact/importance bug
I'm using the Nordic nRF52840-DK board to breadboard an SDHC card interface in Zephyr using SPI. I have it doing "basic" operations, but am trying to reconcile what I'm physically seeing versus what is documented and what I see in the code. I was hoping to run the SPI at 8 MHz, so I included a statement in the .overlay file: clock-frequency = <8000000>; in the SPI specification. I also put the statement: spi-max-frequency = <8000000>; in the specification of the SDcard sub-device (under the SPI specification). The Zephyr SDHC documentation page seems to imply that the spi-max-frequency parameter is the SPI running frequency applied after initialization. But it appears that hardcoded into disk_access_spi_sdhc.c are statements that assign the speed to be 400 KHz during initialization, then 4 MHz for later operations. But then looking at the waveform captured by a logic analyzer, it appears that the SCK signal is actually running at around 250 KHz. What am I missing? Thanks!
The text was updated successfully, but these errors were encountered: