Part Number: TMS570LC4357
I am working on a project where we store configuration data in flash. When attempting to write data into bank 7 sector 0 (address 0xf0200000) I follow the recommended procedure in the documentation for erasing and writing (SPNU501H–December 2012–Revised April 2015 section 6). The write verify fails and when I look on the debugger the data in the flash (displaying memory address 0xf0200000 in the memory browser) does not match the data I attempted to write.
The erase/write/verify is handled via a state machine which I have slowed down so that it only actions one part of the flow every 500 ms
After the erase has been requested via a call to
Fapi_issueAsyncCommandWithAddress( Fapi_EraseSector, address )
the data is still present when viewed on the debugger. (occasionally the erase succeeds and the data goes to all 'F's and sometimes it partially succeeds with 32 byes being erased). The
THe write then fails to update the flash because it has not been erased. When the erase does succeed then I can see the data being writed as each write happens.
I am only writing 38 bytes so I would not expect it is a size issue.