[SOLVED] J-Flash "Failed to prepare for programming" Error

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

  • [SOLVED] J-Flash "Failed to prepare for programming" Error

    I've read through similar issues on the forum but can't seem to find any resolution.

    Hardware: J-Link debug probe version 6.0, AT91SAM7S64, Custom Board
    Software: J-Flash v4.76a, J-Flash v6.12f

    I can connect to the target device, erase, program, and verify using v4.76a. When we updated another work PC, v6.12f was installed on the system and now I am getting a RAM check failed @ addr 0x00202000. The full log is attached below.

    There shouldn't be any hardware issues with either my J-Link or my target board, since they work with no issue on the previous software version. Is my J-Link not compatible with the new software version, or is there something else I am missing?
    Files
    • jflashlog.txt

      (1.56 kB, downloaded 699 times, last: )
  • Hi,


    sorry for the delay in response.
    Does it work when selecting AT91SAM7S32 as a target device or when limiting the ram usage to 8KB?


    Best regards,
    Niklas
    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,


    J-Link uses the Target RAM in order to speed up the programming time.
    According the log file, the error happens when checking the RAM at 0x00202000.
    The AT91SAM7S64 has 16 KB RAM (atmel.com/devices/AT91SAM7S64) at 0x00200000 - 0x00204000.
    The AT91SAM7S32 has 8 KB RAM at 0x00200000 - 0x00202000.

    Are you sure that the target device is a AT91SAM7S64 and not a AT91SAM7S32?
    Is it possible that the target is in a state where only 8 KB of RAM are accessable?
    Are there "unofficial" or the like versions of the AT91SAM7S64 which only have 8KB of RAM?

    Best regards,
    Niklas
    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.
  • After looking over the boards, they're using AT91SAM7S32 chips.

    To further add to my confusion. The board is currently programmed on an old PC running Windows XP, and we are in the process of moving to a new PC running Windows 10. This is were all my trouble began. When testing on the new PC I was having the connection issue that was fixed by changing the project setting from the AT91SAM7S64 MCU to the AT91SAM7S32. Now It won't run on the old system, which is still being used while the new system is developed, unless it is set back to AT91SAM7S64. I'm not sure what is happening with the software that was written for these controls. (Previous engineer designed/coded the project)

    Why does one setting work on one machine but not the other and vice versa?
  • Hi,

    does the "old" system have the same softwareversion installed like the "new" system where you had to change the target device?

    Best regards,

    Nino
    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,

    The old system is running J-Flash v3.80c and the new system is running J-Flash v6.12f.


    Can you check if the issue gets resolved when you install the newest J-Flash version from our website onto the Windows XP machine, as we are not able to give support for older softwareversions.
    Especially if they are that old. Same goes for the new machine that is being setup.

    Best regards,
    Nino
    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.
  • Unfortunately the older system is being used on our production floor and they won't update the software since it is currently working. Updating the MCU on the newer system, with newer software, fixed the original issue, so I'll just have to create a new project file with updated settings for testing on the new system and continue using the old file until we switch over. Hopefully there won't be any further issues with this. Thank you for your help.
  • Hi,


    in order to sum it up: AT91SAM7S64 instead of AT91SAM7S32 was selected as target device in J-Flash.
    This worked with the "ancient" version V3.80c (released 2008), but not with current versions of J-Flash, as current versions try to use RAM which is available on the AT91SAM7S64, but not on the AT91SAM7S32.

    Changing the selected device from AT91SAM7S64 to AT91SAM7S32 resolved the "issue" with the current version of J-Flash.


    Best regards,
    Niklas
    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.