[STM32L4] 执行任何代码时,就会出现这种情况。

[复制链接]
 楼主| HomeKit 发表于 2025-8-3 22:49 | 显示全部楼层 |阅读模式
执行任何代码时,就会出现这种情况。


STMicroelectronics ST-LINK GDB server. Version 5.8.0
Copyright (c) 2020, STMicroelectronics. All rights reserved.

Starting server with the following options:
        Persistent Mode            : Disabled
        Logging Level              : 1
        Listen Port Number         : 61234
        Status Refresh Delay       : 15s
        Verbose Mode               : Disabled
        SWD Debug                  : Enabled

Waiting for debugger connection...
Debugger connected
      -------------------------------------------------------------------
                       STM32CubeProgrammer v2.7.0-RC1                  
      -------------------------------------------------------------------

ST-LINK SN  : 066DFF575251717867163205
ST-LINK FW  : V2J37M26
Board       : NUCLEO-L4R5ZI
Voltage     : 3.26V
SWD freq    : 4000 KHz
Connect mode: Under Reset
Reset mode  : Hardware reset
Device ID   : 0x470
Revision ID : Rev Y
Device name : STM32L4Rxxx/STM32L4Sxxx
Flash size  : 63 KBytes (default)
Device type : MCU
Device CPU  : Cortex-M4



Memory Programming ...
Opening and parsing file: ST-LINK_GDB_server_a21776.srec
  File          : ST-LINK_GDB_server_a21776.srec
  Size          : 8748 Bytes
  Address       : 0x08000000


Erasing memory corresponding to segment 0:
Erasing external memory sectors [0 2]
File segment @0x08000000 is not 255-bytes aligned. It will be aligned to @0x07FFFFF8
Download in Progress:


Error: failed to download Segment[0]
Error: failed to download the File
Encountered Error when opening E:\ST\STM32CubeIDE_1.6.0\STM32CubeIDE\plugins\com.st.stm32cube.ide.mcu.externaltools.cubeprogrammer.win32_1.6.0.202101291314\tools\bin\STM32_Programmer_CLI.exe
Error in STM32CubeProgrammer
Debugger connection lost.
Shutting down...

flycamelaaa 发表于 2025-8-4 15:28 | 显示全部楼层
ST-LINK 固件版本不兼容?
probedog 发表于 2025-8-4 15:30 | 显示全部楼层
STM32CubeProgrammer 或 ST-LINK GDB Server 配置错误
powerantone 发表于 2025-8-4 16:28 | 显示全部楼层
目标芯片供电是否稳定?
stormwind123 发表于 2025-8-4 19:29 | 显示全部楼层
可能是SWD 通信问题。
classroom 发表于 2025-8-4 19:30 | 显示全部楼层
降低 SWD 频率。
duo点 发表于 2025-8-4 21:30 | 显示全部楼层
检查 ST-LINK 连接线 是否松动。
七毛钱 发表于 2025-8-4 21:32 | 显示全部楼层
检查目标芯片是否锁死。
onlycook 发表于 2025-8-4 22:31 | 显示全部楼层
重新安装 STM32Cube。
您需要登录后才可以回帖 登录 | 注册

本版积分规则

42

主题

42

帖子

0

粉丝
快速回复 在线客服 返回列表 返回顶部