Other Parts Discussed in Thread: HALCOGEN
Hi,
I'm working with a custom TMS570LS3137 board.
I enabled the Flash ECC and I'm trying to test it. To do so, I used the --ecc:data_error option of the linker. I also made the linker generate the ecc bits.
In CCS, I programed the flash with the 'Auto-ECC generation' disabled.
My first test concerns one single-bit error. The first time, it seemed to worked:
Error is visible in Memory window, the error is corrected when reaching that element and FCOR_ERR_ADD & FCOR_ERR_POS are correct.
Could you confirm that this is how it should work?
I repeated the test and this time, not the same behavior. Error is corrected before reaching that line. Some times FCOR_ERR_ADD is correctly set, some times not.
I first thought Memory browser would compute it itself (on the computer) but it's not the case.
I also thought that looking at the Memory browser is also reading it from flash, than explaining why it is corrected sooner than expected.
I tried closing Disassembly and Memory windows, but it's still not correcting the error at the right moment.
I tried changing error location several times, still the same behavior. I also tried disabling Pipeline, unsuccessfully.
I enabled profiling and set threshold, not working as well.
I also noted that after reset, the corrected error re-appears.
I'm wondering the following points:
- is there a cache explaining what I see?
- is there a 'table' retaining previous errors, so that they would be corrected sooner?
- is the FCOR_ERR_ADD register reset when performing a System Reset with the debugger?
- do I have to enable profiling in flash wrapper?
- is the flash corrected/written when the ECC detects an error? Seems weird but reading the TRM, this is what I understand.
Furthermore, I wanted to enabled the related interrupt (through ESM), in case I should reset the error flag. I'm not able to do so.
I called the following (Halcogen default):
I also enabled the ESM low level interrupt.
The interrupt is never entered.
Could you help me understand what I'm missing?
In advance, thanks
Laurent