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

Concurrently using XIP and QSPI to read back data from external flash

Dear Nordic,

I have a 4MB external flash on my board, I've successfully run the code on it by using XIP. However, I got stuck when I was trying to read back data from external flash. The following picture has the call stack trace. It's a failure of NRFX_ASSERT.

Some more details:

Using nrfx driver both in bootloader and application is not a good idea, because the driver status is stored in the different RAM area. I add a fake initialization function for QSPI to keep the peripheral status consistent. Do you have any better ideas?

Best Regards,

Eugene

Parents
  • Hi Hung,

    Even if I put QSPI driver in the internal flash, what would happen if interrupts come while we're reading/writing data to external flash?

    When the DMA is ongoing, XIP has to be turned off, if the interrupt handler is in the external flash, then the MCU crashes. So we have to make sure the code executed in the external flash should never be called in the interrupts?

    Does it make sense?

Reply
  • Hi Hung,

    Even if I put QSPI driver in the internal flash, what would happen if interrupts come while we're reading/writing data to external flash?

    When the DMA is ongoing, XIP has to be turned off, if the interrupt handler is in the external flash, then the MCU crashes. So we have to make sure the code executed in the external flash should never be called in the interrupts?

    Does it make sense?

Children
No Data
Related