Hi Team,
I have a DA1469x ProKit and building code with SDK_10.0.4.66 and this has a standard MX25U3235F flash device. I am performing an evaluation to check the device will meet the requirements for a customer application.
My application is configured to execute as XIP from QSPI and the initial test using sample application freertos_retarget builds and runs fine when using the 4MB partition table.
Now when I am adding the rest of my application I have linked in some proprietary code libraries and constant code tables which increases the code mapped to the ROM region to larger than the default 512KB. The ROM linker region grows to around 800KB. I have left the cache for QSPI configured as default at 64KB.
I have created a modified 4M based partition table which defines the firmware partition to be larger as per below and I have adjusted the linker scripts:
#define NVMS_PRODUCT_HEADER_PART_START 0x000000 #define NVMS_PRODUCT_HEADER_PART_SIZE 0x002000 #define NVMS_FIRMWARE_PART_START 0x002000 /* Alignment to 512KB is dictated by the default FLASH_REGION_SIZE. */ #define NVMS_FIRMWARE_PART_SIZE 0x0DE000 /* Increased from default 0x07E000 to use empty space */
I flashed the device using theprogram_qspi_jtagscript which appears to flash all the sectors correctly however I am unable to read back any constant data or execute code from addresses above 0x80000 (remapped) or 0x36080000 direct. Is it even possible to have aNVMS_FIRMWARE_PART_SIZEgreater than 512KB?
Either theprogram_qspi_jtagscript is failing to flash the upper regions correctly or the QSPI memory (re)mapping is somehow still misconfigured.
Please can you offer any guidance.
Thanks
~Garry
Hi Garry Clarkson,
Please check the Table 976 of DA1469x datasheet. By default, the FLASH region size is set at 0.5 Mbytes, but this value can be changed by programming the CACHE_FLASH_REG[FLASH_REGION_SIZE] in the OTP header. The CACHE_FLASH_REG[FLASH_REGION_BASE] and CACHE_FLASH_REG[FLASH_REGION_OFFSET] will be set by the bootloader, so you don’t need to program them. ONLY CACHE_FLASH_REG[FLASH_REGION_SIZE] must be programmed.
In addition, if you would like to have SUOTA functionality, the SUOTA partition table must be modified respectively.
Thanks, PM_Dialog
Hi,
many thanks for the guidance and step by step instructions. I was setting CACHE_FLASH_REG[FLASH_REGION_SIZE] to 0x5 early in the startup code without realising this must be done via the OTP route.
I instead changed to use a 2Mbyte configuration by setting CACHE_FLASH_REG[FLASH_REGION_SIZE] to 0x4 for some headroom and adjusted the partition table. It is now working fine. Thanks for your help.
Regards,
Garry
Hi Garry,
Glad that you figured your issue out. If you found my answer useful, please mark it as “accepted”.
Thanks, PM_Dialog
Hi Gary,
In addition you should change the dg_configQSPI_CODE_SIZE_AA macro in bsp_memory_defaults.h file. Please make the following modifications in bsp_memory_defaults.h
The 136KB is the size of the CMAC which is running in M0+.
Thanks, PM_Dialog