Other Parts Discussed in Thread: HALCOGEN
I am trying to move an ISR, and later more code, to execute out of RAM, but I am getting data-aborts. I see that this has been covered in other E2E conversations,
and I believe I have read them all, but I am still missing something.
I am using HalCogen to generate all of the non-user-code, and the code runs without exceptions in Flash. I made only these changes to place a single ISR in RAM:
In HalCoGen, set the RAM in the MPU as PRIV_RW_USER_RW_EXEC.
In the cmd file, added these lines:
RAMFUNC (RWX): origin=0x08070000 length=0x00010000
.binit align(32) : {} > FLASH0 | FLASH1
.TI.ramfunc align(32) : {} load=FLASH0, run=RAMFUNC, table(BINIT)
Before my ISR, I have:
#pragma CODE_SECTION (func, ".TI.ramfunc")
Note I do not have --ramfuncs=on (as it moves ALL functions to RAM), and I do not have a separate memcopy (to copy the function to RAM), which is not required like the C2000?
I see the RAM-allocation in the map-file, and I can single-step through the ISR (within RAM) using the debugger, but clicking run will cause data-aborts, that seem to occur at different lines of code within the ISR.
Also note the ARM Assembly Language Tools v20.2.0.LTS states there is a Wiki for "Placing functions in RAM", but the URL points back to the general compilers and assembly language tools page, so the pdf essentially points back to itself for help.
Any idea on what I have missed here?
Thanks,
Jim