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.

CCS/TMS570LS1224: Operation TMS570 read and write on-chip flash function found inconsistency in reading and writing?

Part Number: TMS570LS1224

Tool/software: Code Composer Studio

As shown in the figure below, I write 1 (1024 total) to the address 0x20000, but all of them are 0 read by the flashAPI function. What is the problem?

#define FLASH_BUFFER_SIZE 1024
static uint8_t data[FLASH_BUFFER_SIZE] = {0U};
static uint8_t redata[FLASH_BUFFER_SIZE] = {0U};

uint32_t addr = 0x20000;

for(i = 0U; i < FLASH_BUFFER_SIZE; i++)
{
     data[i] = 1;
}