ST意法半导体
直播中

李秦

8年用户 150经验值
私信 关注
[问答]

如何通过SWIM和命令行重置MCU

如何通过SWIM和命令行重置MCU

以上来自于谷歌翻译


以下为原文



How to reset MCU through SWIM and command line

回帖(2)

康永清

2019-4-2 14:35:22
您可以在编程后使用gdb7.exe重新启动mcu。
 
 我使用以下命令行:
 gdb7.exe --quiet --command = restart_mcu.ini
 
 restart_mcu.ini的内容
 < ----------- schnipp ------------->
 #
 #define模拟器复位端口和MCU
 #
 定义emulator-reset-port-mcu
 target gdi -dll swim  stm_swim.dll -stlink3 -port $ arg0 -mcuname $ arg1
 mcuname -set $ arg1
 结束
 
 #
 #reset命令并退出
 #
 emulator-reset-port-mcu u***:// u*** stm8s105c6
 放弃
 < ----------- schnapp ------------->
 
 您必须将mcu类型(此处为stm8s105c6)替换为您正在使用的类型。
 
 问候,
 斯特凡

以上来自于谷歌翻译


以下为原文




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 swimstm_swim.dll -stlink3 -port $arg0 -mcuname $arg1
mcuname -set $arg1
end

#
# reset command and quit
#
emulator-reset-port-mcu u***://u*** stm8s105c6
quit
<-----------schnapp------------->

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

Regards,
Stefan
举报

李秦

2019-4-2 14:50:34
斯特凡,
 
 
 谢谢您的回复。你提供的解决方案运行良好,这正是我想要的。再次感谢
 
 问候,
 
 Sia Enayati

以上来自于谷歌翻译


以下为原文





Stefan,


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

Regards,

Sia Enayati
举报

更多回帖

发帖
×
20
完善资料,
赚取积分