I'm trying to use the Flash utilities, based on the spna106 pdf file. The erase/write/read to the Flash bank 7 works OK, as far as I can tell :
oReturnCheck = Fapi_checkFsmForReady();
oReturnCheck = Fapi_setActiveFlashBank(Fapi_FlashBank7);
oReturnCheck = Fapi_issueAsyncCommandWithAddress(Fapi_EraseBank, (uint32 *) 0xF0200000);
while (Fapi_checkFsmForReady() != Fapi_Status_FsmReady){}
oReturnCheck = Fapi_issueProgrammingCommand((uint32 *) 0xF0200000, au8DataBuffer, 0x3, 0, 0, Fapi_DataOnly);
while (Fapi_checkFsmForReady() != Fapi_Status_FsmReady){}
oReturnCheck = Fapi_getFsmStatus();
But when I try to do the same for Bank 1
oReturnCheck = Fapi_checkFsmForReady();
oReturnCheck = Fapi_setActiveFlashBank(Fapi_FlashBank1);
oReturnCheck = Fapi_issueAsyncCommandWithAddress(Fapi_EraseBank, (uint32 *) 0x00180000); //erase all bank 1
while (Fapi_checkFsmForReady() != Fapi_Status_FsmReady){}
oReturnCheck = Fapi_issueProgrammingCommand((uint32 *) 0x00180000, au8DataBuffer, 0x3, 0, 0, Fapi_DataOnly);
while (Fapi_checkFsmForReady() != Fapi_Status_FsmReady){}
oReturnCheck = Fapi_getFsmStatus();
It fails to program any data, although no apparent errors from the Fapi routines.
I assume this is something to do with access privledges. When reading from 0x00180000 it triggers a dabort trap.
Code composer seems to give 0xBAD0 data in this memory zone, even though it is supposed to be erased.
Any ideas which steps I need to do, or check ? Thanks Phil