Hello,
I havre acreated a botcm check and b1tcm check, according to spna106a.pdf.
When correcting 1 bit errors, everything goes smoothly, but when I execute a 2 bit error check something that shouldn't happen happens. I know it is supposed to generate a data abort interruption and it does so effitiently,
However when I check ESMSR3 register for group 3 error for b0tcm and b1tcm, there are none.
My data abort handler:
.text
.arm
.ref dataAbort
.def _asm_dataEntry
.asmfunc
_asm_dataEntry
stmed sp!, {r0 - r12, lr}
bl dataAbort
ldmfd sp!, {r0 - r12, lr}
cps #0x13
subs pc, lr, #0x4
.endasmfunc
My dataAbort function:
void dataAbort() {
if(ESMReg->ESMSR3 & 0x8U) { /*Uncorrectable error was detected in B0TCM*/
if ((TCRAM1Reg->RAMCTRL & 0x100U)) {
TCRAM1Reg->RAMERRSTATUS = 0x20U;
ESMReg->ESMSR3 = 0x8U;
ESMReg->ESMEKR = 0x5U;
} else {
while(1);
}
} else if (ESMReg->ESMSR3 & 0x20U){ /*Uncorrectable error was detected in B1TCM*/
if (!(TCRAM2Reg->RAMCTRL &0x1U)) {
TCRAM2Reg->RAMERRSTATUS = 0x20U;
ESMReg->ESMSR3 = 0x20U;
ESMReg->ESMEKR = 0x5U;
} else {
while(1);
}
} else {
while(1);
}
}