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

Using FAT Filesystem on the Macronix memory on the nRF9160-DK

Is there sample code to use a FAT Filesystem on the Macronix memory on the nRF9160-DK?
The full_modem_update sample uses the Flash but not as a filesystem.

It would be great to have a sample or even for mounting it.
Do I need a device tree overlay?
What is required in the mount data structures for the flash and the

Also, if our requirements for persistent storage change, it would be great to use the SD.
In addition to populating the SD socket, what is required?
It appears from the DevZone others have made it work but none of the posts offers a complete solution.

Parents
  • The sample won't build if your Zephyr version is too old. You can try building on master, I was able to build it successfully there. If you want to build it for the nRF9160 with the mx25 SPI flash, you need to follow these instructions;

    To properly build the sample for the nrf9160dk_nrf9160 with external mx25 spi flash you need to do:

    west build -b [email protected] --build-dir test2 zephyr/samples/subsys/fs/fat_fs_basic/ -- -DCONF_FILE=prj_external_spi.conf -DDTC_OVERLAY_FILE=boards/nrf9160dk_nrf9160.overlay

     

    The [email protected] means that the dk is at version 0.14.0, if you do not provide the version, you will get error because default version of dk does not have the mx25 chip.

     

    The CONF_FILE means the configuration file from sample directory to take, this one is for SPI connected memory (mx25) because such bus is used withing dk to connect the mx.

    The DTC_OVERLAY_FILE is used to reconfigure the board, so that during compilation the software could find the external storage.

     

    The additional CONF_FILES are for internal memory (prj.conf) and external over qspi, because nrf52840dk board uses QSPI.

Reply
  • The sample won't build if your Zephyr version is too old. You can try building on master, I was able to build it successfully there. If you want to build it for the nRF9160 with the mx25 SPI flash, you need to follow these instructions;

    To properly build the sample for the nrf9160dk_nrf9160 with external mx25 spi flash you need to do:

    west build -b [email protected] --build-dir test2 zephyr/samples/subsys/fs/fat_fs_basic/ -- -DCONF_FILE=prj_external_spi.conf -DDTC_OVERLAY_FILE=boards/nrf9160dk_nrf9160.overlay

     

    The [email protected] means that the dk is at version 0.14.0, if you do not provide the version, you will get error because default version of dk does not have the mx25 chip.

     

    The CONF_FILE means the configuration file from sample directory to take, this one is for SPI connected memory (mx25) because such bus is used withing dk to connect the mx.

    The DTC_OVERLAY_FILE is used to reconfigure the board, so that during compilation the software could find the external storage.

     

    The additional CONF_FILES are for internal memory (prj.conf) and external over qspi, because nrf52840dk board uses QSPI.

Children
No Data
Related