This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Use nrfx QSPI with Zephyr filesystem

I'm using Zephyr on a nRF52840 and I'd like to use the QSPI with the Fat Filesystem.   I added the following Config statements to prj.conf:


# Filesystem
CONFIG_FILE_SYSTEM=y
CONFIG_FAT_FILESYSTEM_ELM=y
CONFIG_NRFX_QSPI=y
CONFIG_DISK_ACCESS=y
CONFIG_DISK_ACCESS_SDHC=y
CONFIG_DISK_ACCESS_SPI_SDHC=y

The nrfx QSPI driver and file system code is then included in the build, but I'm unsure how to associate the QSPI with the filesystem.    I don't see a "CONFIG_DISK_ACCESS_QSPI_SDHC" to replace the "CONFIG_DISK_ACCESS_SPI_SDHC".    Or is there a different way to do this that I'm missing?

Thanks!

Parents
  • After doing a lot of reading, I determined that it is not possible to control an SDcard using QSPI.   While they are very similar, QSPI transmits command over the D0 signal while SDcard uses a separate CMD signal (for both command and response).   I thought that perhaps there might be a way to connect D0 to CMD, but I don't see a way to retrieve the command response using the QSPI setup.

  • It does not seem like it's possible to use QSPI with an SD Card, after browsing through DevZone. I'll copy in another answer I found:

    "Using SD card in any other modes than SPI would require a licence from the SD card association, link. Even if we had such an example, we wouldn't be allowed to publish it. Hence only SPI examples are shown for SD Cards."

    Would using SPI be an option for you?

    Best regards,

    Simon

  • I was hoping for the higher throughput that SD mode would provide, but am now trying SPI mode.   I'm having an issue there as well though.    I submitted a separate ticket for that question (Case ID: 265559:  Use SPI to interface to SDcard under Zephyr).   I'm having trouble getting the SPI chip-select to work properly.   (It seemed so much easier when I could call the configuration functions directly (instead of working through device-tree) :-))

    Thanks!

Reply
  • I was hoping for the higher throughput that SD mode would provide, but am now trying SPI mode.   I'm having an issue there as well though.    I submitted a separate ticket for that question (Case ID: 265559:  Use SPI to interface to SDcard under Zephyr).   I'm having trouble getting the SPI chip-select to work properly.   (It seemed so much easier when I could call the configuration functions directly (instead of working through device-tree) :-))

    Thanks!

Children
Related