Skip to main content
Visitor II
April 21, 2010
Question

How to reset MCU through SWIM and command line

  • April 21, 2010
  • 2 replies
  • 999 views
Posted on April 22, 2010 at 01:34

How to reset MCU through SWIM and command line

    This topic has been closed for replies.

    2 replies

    senayatiAuthor
    Visitor II
    May 17, 2011
    Posted on May 17, 2011 at 15:08

    Stefan,

    Thank you for your reply. The solution you offered worked fine and it is just what I wanted. Thanks again

    Regards,

    Sia Enayati

    Visitor II
    May 17, 2011
    Posted on May 17, 2011 at 15:08

    You can use gdb7.exe to restart mcu after programming.

    I use the following command line:

    gdb7.exe --quiet --command=restart_mcu.ini

    Content of restart_mcu.ini

    <-----------schnipp------------->

    #

    # define emulator reset port and MCU

    #

    define emulator-reset-port-mcu

    target gdi -dll swim\stm_swim.dll -stlink3 -port $arg0 -mcuname $arg1

    mcuname -set $arg1

    end

    #

    # reset command and quit

    #

    emulator-reset-port-mcu usb://usb stm8s105c6

    quit

    <-----------schnapp------------->

    You have to replace the mcu type (here stm8s105c6) to the one you are using.

    Regards,

    Stefan