Hello,
We are working on a custom board with IMX rt1176 processor. External QSPI flash is different from the flash on the development board. The programs loaded in the flash do not work when I first code to the processor. First we can run a program in OCRam and then we can load the code into the flash. What is the reason for this? Is this a problem?
Good day to everyone.
Hi @tbayram ,
It's easy to check the issues, please follow me:
1. open the SDK flexspi_nr_polling_transfer_cm7 code .
2. check :
const uint32_t customLUT[CUSTOM_LUT_LENGTH] = {
make sure the LUT read, erase, quad, etc commander matches you used flash.
3. Run the project in the internal RAM:
Whether it can pass all the testing?
I mean, the log should like this:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
FLEXSPI example started!
Vendor ID: 0x9d
Erasing Serial NOR over FlexSPI...
Erase data - successfully.
Program data - successfully.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This will help you to check your external flash situation, and also help you enable the quad mode.
Please try it on your side.
If you still have question about it, please kindly let me know.
Best Regards,
Kerry
Hi @tbayram ,
Which QSPI fash partnumber you are using?
You mentioned: We get a flash error when we want to load a program that runs as xip during the first program loading on the cards coming from production,
You want the XIP and to do the flash operation, right? In this situation, you need to copy the flash driver to the internal RAM, otherwise, it will have issues, you can refer to the SDK flexspi_nr_polling_transfer_cm7 code.
Wish it helps you!
Best Regards,
Kerry
Hi @tbayram ,
Please run this flexspi_nr_polling_transfer_cm7 demo in the internal RAM at first, then share the result to me, you also need to check the LUT commander to match your used flash datasheet, thanks.
Linker to RAM is like this configuration in the MCUXpresso project:
Any updated information, please kindly let me know.
Best Regards,
kerry
Our result is same with yours. Is it meaning there is no problem?
Hi @tbayram ,
Yes, this test result means your external flash works OK.
Now, you can download the app image to your external flash, and boot it.
Do you still have issues about it?
You need to check the BOOT_MODE, and BOOT_CFG, make sure it is internal boot mode, and the CFG for the QSPI flash, to the BOOT_CFG related pins, just keep 0 is OK, to the BOOT_MODE[1:0]=10, this is the internal boot mode.
Best Regards,
Kerry