This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM263P4-Q1: How to enable the ECCM module

Part Number: AM263P4-Q1

Configuration
● AM263Px MCU+ SDK: 11.00.00.19
● CCS: 20.3.0.00014

Using the configuration above, I generated an ECC-converted MCELF file by following the "How to enable ECCM module" instructions found at the URL below:

https://software-dl.ti.com/mcu-plus-sdk/esd/AM263PX/11_00_00_19/exports/docs/api_guide_am263px/OPTIFLASH_ECCM.html

● In `conf.json`, I specified `"start": "0x60100000"` and `"size": "0x400000"`. However, when analyzing the generated `mcelf_xip` using `tiarmreadelf --headers`, I observed that the usage size increased by approximately 1.125 times even in the region beyond `0x60500000` (calculated as `0x60100000 + 0x400000`). Is it the intended behavior that *all* XIP segments within the `.mcelf_xip` file undergo ECC conversion, regardless of the "start" and "size" address range specified in `conf.json`?

● I intend to detect ECC errors when the SBL loads the program from external flash memory; therefore, I would like to include non-XIP regions in the ECC conversion process as well. Please explain how to apply ECC conversion to the entire program area, including non-XIP regions. Note, however, that the external flash also stores data other than the program itself, and I wish to exclude that data from ECC conversion. 

Related question: https://e2e.ti.com/support/microcontrollers/arm-based-microcontrollers-group/arm-based-microcontrollers/f/arm-based-microcontrollers-forum/1680162/am263p4-q1-method-for-checking-for-faults-on-the-communication-path-to-external-flash-memory-using-the-fss-ecc-function-during-program-loading

Requested response date: 2026/10/02

  • Hi, 

    Understood the usecase, let me check this and get back to you

    Thanks & Regards,

    Aswin

  • Hi,

    intend to detect ECC errors when the SBL loads the program from external flash memory; therefore, I would like to include non-XIP regions in the ECC conversion process as well. Please explain how to apply ECC conversion to the entire program area, including non-XIP regions. Note, however, that the external flash also stores data other than the program itself, and I wish to exclude that data from ECC conversion. 

    Currently as a part of the build process we are enabling ECC on XIP regions only as they are executing from flash. The non XIP region will be copied to RAM, so RAM ecc would also serve the purpose here. That being said, if the non xip image is appended with the ECC bytes and flashed, then when the flash read happens during the image loading process, the ECC will be checked by ECCM hw. 

    The script currently does not do that. It only enables ecc for xip regions.

    If ECC needs to be enabled the option would be to Enable Flash ECCM on the address region where the application image is stored. Modify the application image build script/python file to append ecc bytes to the image.

    The data which needs to excluded from ECCM, it can be accessed by the last flash memory window FSS region3.

    ● In `conf.json`, I specified `"start": "0x60100000"` and `"size": "0x400000"`. However, when analyzing the generated `mcelf_xip` using `tiarmreadelf --headers`, I observed that the usage size increased by approximately 1.125 times even in the region beyond `0x60500000` (calculated as `0x60100000 + 0x400000`). Is it the intended behavior that *all* XIP segments within the `.mcelf_xip` file undergo ECC conversion, regardless of the "start" and "size" address range specified in `conf.json`?

    Yes this is the intended behavior . 

  • > If ECC needs to be enabled the option would be to Enable Flash ECCM on the address region where the application image is stored. Modify the application image build script/python file to append ecc bytes to the image.


    Could you please provide the build script/python file that adds ECC bytes to the MCELF (application image) for the non-XIP region in the AM263Px MCU+ SDK: 11.00.00.19 environment?

    It is acceptable for the specification to apply ECC bytes across the entire non-XIP region.

  • Hi, 

    I am checking on this, currently the support is not there to enable ecc on non xip region. Allow me some time to get back to you

  • Hi Makoto, 

    I am discussing the same topic with Imada-San here,

     AM263P4-Q1: Method for checking for faults on the communication path to external flash memory using the FSS ECC function during program loading. 

    So I am temporarily pausing this thread. We can discuss the topic in the above mentioned e2e.