STM32H747 with external NAND Flash and ECC hardware in MCU
Hi together
We use a STM32H747 MCU with an external NAND SLC Flash on the FMC bus.
In the reference manual in chapter "23.8.6 Computation of the error correction code (ECC) in NAND Flash memory" and some pages later in the description of the ECC register "ECC result registers (FMC_ECCR)" it is mentioned that a 1 bit error can be detected and corrected. We are aware of that, that is hamming.
But we don't know how the ECC is constructed. You cool ST guys cast that in silicon, but you didn't document it. You write at e.g. 256 byte size it is ECC[21:0] so 22 bits.
Now our questions:
- How is the data position and bit error position calculated?
- How is the division into even and odd parity?
According to the Ref. manual we don't know what you have cast into silicon and the description in the manual is not helpful.
Would you please provide us with a code example and describe the result of the STM32 hardware better?
There is code on the web, but we can't put software in devices that are sold by 100'000 pieces and we don't know how it works.
Thank you. :)