I'm using a RT1176 in a custom board with SDRAM and a IS25WP128-JBLE QSPI external flash.
We are doing a HMI, and the flash size is getting small for including images in flash, so we changed the flash to IS25WP256D-JLLE.
When the code is less than 50% of the flash size, all is working fine, but when we start using the "new sectors" we get a hard fault in data_init.
I changed the board flash size in board.h and a line in board.c
#if defined(XIP_EXTERNAL_FLASH) && (XIP_EXTERNAL_FLASH == 1)
/* Region 8 setting: Memory with Normal type, not shareable, outer/inner write back. */
MPU->RBAR = ARM_MPU_RBAR(8, 0x30000000U);
// MPU->RASR = ARM_MPU_RASR(0, ARM_MPU_AP_RO, 0, 0, 1, 1, 0, ARM_MPU_REGION_SIZE_16MB);
MPU->RASR = ARM_MPU_RASR(0, ARM_MPU_AP_RO, 0, 0, 1, 1, 0, ARM_MPU_REGION_SIZE_32MB);
#endif
/*! @brief The board flash size */
#define BOARD_FLASH_SIZE (0x2000000U)
Also changed the size in MCU settings:
Maybe the cfx driver is not valid?
I need to do more steps?
Thank you very much
Solved! Go to Solution.
It's working now.
I had to change the lookupTable at evkmimxrt1170_flexspi_nor_config.c, using the commands given in the new memory datasheet.
Thank you!
Hello EdwinHz,
I tried the example code, and changing the flash size it seems to work in the upper part of the FLASH:
I changed lookupTable in evkmimxrt1170_flexspi_nor_config.c with the customLUT provided, but it's not working yet.
Maybe it's important to remark that my program is working fine until the mid region of the flash. When the % used of the memory surpases the 50%, it fails.
I was thinking about the instructions for managing 4-byte address, but it's not included in customLUT, and the example seems to work without that:
Hi @daniJVV,
Please follow the recommendations mentioned by my colleague in the following community post: Re: iMX RT1062 with IS25WP365D-JLLE issue - NXP Community
He mentions some remarks that are worth taking into account. Also, try the example code that he mentions and let me know what are the results as well.
BR,
Edwin.
It's working now.
I had to change the lookupTable at evkmimxrt1170_flexspi_nor_config.c, using the commands given in the new memory datasheet.
Thank you!