[SOLVED] SWD / Reset issue on STM32

  • [SOLVED] SWD / Reset issue on STM32

    Hi!
    since a while we are experiencing some issue with J-Link/J-Flash arm
    the last known version that was usable is the 4.74b
    I currently installed the 5.12e and also have tested on 4.83a that have the same symptoms

    although arm SWD interface don't mention to require the reset pin, it seems that on 4.83a this is mandatory and on 5.12e even with the reset pin cabled the probe don't always connect (95% fail) the only version that seems to connect most of the time is the 4.74b

    the MCU is most of the time in stop mode

    on 4.74b without reset pin cabled, and normal operation, the connection success rate is about 100%, but if a bug leads the MCU to endless reboot itself the reset pin is the only way to reflash the device (using IAR or segger jflash)
    on 4.83a without the reset pin cabled, even in normal operation, the connection success rate is about 10% to 20%, with the reset pin the connection success rate is normal
    on 5.12e with the reset pin cabled, the connection rate is less that 5%, as a workaround on IAR I cut the MCU power by hand and put it back when the segger sofware try to connect


    the reset strategy is always "normal" but using other strategy don't change a thing


    for all the case, the probe does identify the SWD-DP is found...
    on J-Flash software when we do some analyse on "Auto Flash" (F7) we have noticed that the chip is in free run mode between the various steps (connecting - erasing -downloading - verifying) which is problematic when the device has a bug that create endless reboot.... since there is no way back to flash the device....

    seems that the highest the release version is the lowest the SWD support is working, but even going back to jtag mode don't solve the issue....

    thanks and regards
    JLM
  • Hi,

    thanks for your inquiry.

    We are currently not aware of any issue regarding J-Link +SWD and STM32 family devices.
    Which device do you use?

    Does this issue occur with J-Link Commander (jlink.exe) ?


    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,

    although arm SWD interface don't mention to require the reset pin, it seems that on 4.83a this is mandatory and on 5.12e even with the reset pin cabled the probe don't always connect (95% fail) the only version that seems to connect most of the time is the 4.74b


    You must differentiate here:
    The SWD interface itself specifies the nRESET pin. If connecting it is necessary or not depends on the actual device, so it is not part of the SWD spec.
    As there are cases where only the SW-DP but NO(!!!) debug logic of the CPU itself is accessible or in some cases even the SW-DP is not responsive anymore, the nRESET pin might be the only possibility to reset the device and regain control about it.

    Would it be possible to give us remote access to your hardware via J-Link Remote Server in tunneling mode?:
    segger.com/jlink-remoteserver.html#tunneling_mode

    We could then give it a quick try and check if we see anything special.
    If not, we can also offer to have a look at it if you can provide your hardware temporarily. However, we might need to charge for this, if the outcome is that the problem comes from your HW, not from J-Link.


    Best regards
    Alex
    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.