[SOLVED] Unable to write to ECC flash on tms570lc4357 device

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [SOLVED] Unable to write to ECC flash on tms570lc4357 device

    Hello,

    I'm trying to write ECC data to flash using JLinkExe, but I get a "Unspecified error -1". The binary file with a size of 2KB should fit into ECC flash (address range from 0xF0400000 to 0xF05FFFF, according to SPNS195C).
    The ECC flash binary is attached.

    Thanks and best regards,

    Guillaume
    Files
    • boot_ecc.bin

      (2.05 kB, downloaded 457 times, last: )
  • Hello Guillaume,

    Could you provide us with a Log file?
    How to enable:
    wiki.segger.com/Enable_J-Link_log_file

    Best regards,
    Fabian
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Hi Guillaume,
    Sorry for the delay in response.

    Yes, J-Link does not support ECC downloads. This area is not supposed to be downloaded to.
    The J-Link uses the TI API to activate ECC calculation.
    The ECC area is then managed by the CPU itself.

    Does this answer your question?

    Best regards,
    Fabian
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Hello Fabian,

    Thanks for your answer.

    Yes, J-Link does not support ECC downloads. This area is not supposed to be downloaded to.
    Why is the ECC flash area not supposed to be downloaded to?
    I'm aware that ti now provides Uniflash to automatically write the ECC flash area during the flashing process.
    However, in the past, they were providing the nowECC tool (ti.com/tool/NOWECC).
    This tool simply generates ECC flash binary, which must be flashed separately from the application's flash area.
    Thus, I guess there is no restriction on modifying flash content of this area.

    The J-Link uses the TI API to activate ECC calculation.
    Do you mean a standalone Uniflash distribution (processors.wiki.ti.com/index.php/UniFlash_v4_Quick_Guide)?
    By "activate", you mean generating the ECC flash content, right?

    The ECC area is then managed by the CPU itself.
    I don't understand this point, could you be a little bit more specific?

    Thank you and Best regards,

    Guillaume
  • The situation is as follows:
    The J-Link flash loader uses the TI lib to program the internal flash of the TMS570xxx series devices.
    This is because TI does not publish any information about their flash controller etc. and recommends to use the TI lib for implementing flash programming.
    The flash of the TMS570 series devices is ECC protected.
    As almost no customer wants to manually calculate the ECC for the flash image to be programmed and program that ECC as a separate file, the TI lib offers a "auto-calc ECC" mode.
    This mode is also used by J-Link. When programming an image to the internal flash, the ECC is automatically computed and programmed to the ECC area by the TI lib.

    So far so good. If for any reason you must program the ECC area on your own, you need to write your own flash loader and replace the J-Link one.
    This can be done the same way as adding support for new devices (can also be used to modify support for existing ones):
    wiki.segger.com/Open_Flashload…ending_an_Existing_Device
    However, this comes without any support from SEGGER, so you would be on your own with creating such a flash loader.
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.