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

USB Mass storage class module

Hello guys,

In our current project, we need to have the ability to copy .bmp images from our PC directly to W25N01GVZEIG TR QSPI flash memory of NAND type. To the best of my knowledge, the best starting point for us would be to use  usbd_msc (USB Mass Storage Class module) example from $SDK_ROOT/examples/peripheral/usbd_msc. Our NAND flash is 128MB in size. Am I right or there is some better point to start with?

Also, I noticed some people here on the forum reporting difficulties when using the USB Mass Storage Class module with QSPI flash memories of NAND type (e.g. here). Is that issue resolved now with SDK 15.3.0?

Finally, is errata 187 resolved with SDK 15.3.0 (I could not find nrf_drv_usbd_errata.h file)?

Thank you very much for your time and effort. It is really appreciated.

Cheers,

Bojan.

Parents
  • Hello, 

    Am I right or there is some better point to start with?

     Yes, the USB MSC example is a good starting point, but I would also recommend the QSPI example to ensure the communication with your flash device.

    Is that issue resolved now with SDK 15.3.0?

    From the datasheet of the device, I could not see any issues, as it supports QSPI. You can try the QSPI example to ensure functionality.

    Finally, is errata 187 resolved with SDK 15.3.0 (I could not find nrf_drv_usbd_errata.h file)?

    The workaround is implemented in the SDK I believe.

    Kind regards,
    Øyvind

Reply
  • Hello, 

    Am I right or there is some better point to start with?

     Yes, the USB MSC example is a good starting point, but I would also recommend the QSPI example to ensure the communication with your flash device.

    Is that issue resolved now with SDK 15.3.0?

    From the datasheet of the device, I could not see any issues, as it supports QSPI. You can try the QSPI example to ensure functionality.

    Finally, is errata 187 resolved with SDK 15.3.0 (I could not find nrf_drv_usbd_errata.h file)?

    The workaround is implemented in the SDK I believe.

    Kind regards,
    Øyvind

Children
  • Hello Øyvind,

    Thanks for replying. We tested the QSPI example as well. It is functional.

    However, nRF52840-DK board contains MX25R6435F flash memory of NOR type and 8MB in size. On our custom board, we would like to use high-capacity (128MB) W25N01GVxxIG/IT flash of NAND type. While reading through the forum I realized some people are complaining about using USB Mass Storage Class with QSPI flash memories of NAND type (e.g. here). That is why I wanted to double-check and see if there is any still existing issue for using QSPI flash memories of NAND type with USB Mass Storage Class.

    Sincerely,

    Bojan.

  • Hello Bojan, 

    I have talked to our systems team and can confirm that we do not have native support for NAND. However, the flash you are referring to may be compatible.


    Figure 25a from page 45 in the device datasheet, should match figure 16 in the QSPI chapter in regards to timing. The Fast Read Quad Output with 4-byte address indicates that it should be able to communicate with the nRF52420: "This allows using a single Read instruction to read out the entire memory array and is also compatible to Winbond’s SpiFlash NOR flash memory command sequence", but for READ4O the number of address bits and dummy cycles is different. 

    From what I am told, there are a lot of configuration options in the QSPI, and there is a possible workaround but will require some low-level programming to work.

    If you do have the flash device I would recommend to test with the QSPI example to verify that it does in fact work.

    Kind regards,
    Øyvind

  • Hello Øyvind,

    Thank you very much for your effort!

    I have here with me one custom board containing some BLE module based on nRF52840 (link) and W25N01GVZEIG TR flash. Will try to implement usbd_msc example and see what is going on.

    Will report you about the results. Thanks once again!

    Sincerely,

    Bojan.

  • Yes, please update me when you have tried!

    Kind regards,
    Øyvind

  • Hello Øyvind,

    Just tried the usbd_msc example on my custom board containing NAND flash. Unfortunately, only logical unit implemented in RAM properly mounted. External QSPI NAND flash failed to mount:

    [00:00:00.000,000] <info> app: Initializing disk 0 (QSPI)...
    [00:00:00.000,000] <error> app: Disk initialization failed.

    I imagine there are little subtle differences in interfacing NOR and NAND flash memories that are the reason for this failure.

    So, before diving deeper into the code, I would like to ask you to recommend me some QSPI flash memory that is of NOR type and at least 1Gb (128MB) in size. The most important, the one that you think will work with your  usbd_msc example. What is the key parameter of the NOR flash memory I need to pay attention to?

    Once again, thanks for the great support!

    Sincerely,

    Bojan.

Related