This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Tool/software: Code Composer Studio
Background Brief: A Custom board that RM57 save user data On-chip FLASH
Environment: HALCOGEN 4.6.0
TI ARM Compiler 16.9.1
CCS 7.1
Configuration:
Flash Library File: F021_API_CortexR4_LE_L2FMC_V3D16.lib
Problem Detail:
Erase operation:
Read operation:
Write operation:
Test code:
Test result:
1、The test code is executed the first time, and erase operation -> write operation -> read operation, are normal.
2、The test code is executed the second time,Observe the execution through the CCS memory window ,128 bytes from 0x1c0000 after an erase operation have not changed to 0xff,128-byte data from 0x1c0000 after write operation does not change,The data read by the read operation is the data written by the first pass of the code,the ESMSR2 register has a value of 0x08.The third and subsequent executions of the test code are the same as the second pass.
3、Power off and restart,re-download code through CCS,observe the data of address 0x1c0000 through the CCS memory window before executing the MAIN() function,the data is the same with the last written value before power off.
Hi,QJ Wang,
1.The flash operation related code is executed in SRAM in our program.
2.Our system clock is 300Mhz and HCLK is 150Mhz,and modified SYS_CLK_FREQ to 300,the returned value of the function Fapi_initializeFlashBank(SYS_CLK_FREQ) is Fapi_Error_InvalidHclkValue.
3.We modify our code with writting 16 bytes as testting,the result is same as before.
Thanks and Regards,
QJ Wang