Hello, we have application for TMS570LS3137 and now I try port it to TMS570LC4357.
But there is problem. ECC check for Flash memory is permanently enabled. (TRM chapter 7.4.1 SECDED Initialization). Does exist some way to disable it? I thing that is enabled by core signal PARECCENRAMm[0] (see to Cortex-R5 TRM) But from CP15 register ACTLR (Auxiliary Control Register, I read 0x20 from this register).
And compare TMS570LS3137 to TMS570LC4357 don't have register like FEDACCTRL1.
This means that any access to erased flash will throw FIQ caused by ESM event 3 group 2. But there is no way to detect which access cause this fail. I know only program address from FIQ_LR register. But it is problem for data access to flash.
Why it is problem? For 2 situations:
- bootloader aplication check. We have CRC check of application in bootloader. It will block start application after incomplete flash. But this check need read the flash and during this can found erased space. Access to this erased space will throw exception.
- data flash on bank 7. This flash have workaround for erased space (register EE_FEDACCTRL1). But it is not enouht. It's easily possible that data not fit to ECC when power failed during write. And we need proper recovery from this situation.
From first point of view, I has an idea to create special flash function in ASM. And ignore FIR caused by ECC when happen on place of LDR instruction. But there is problem. I can't recognize if it is caused by data read or reading of LDR instruction itself.
At this moment I hope, that I miss some information in MCU documentation and exist some certifiable (EN50128) way to do it in our SW.
Any help please?
Have a nice day,
Jiri