CLion + St-Link + bluepill

问题描述 投票:0回答:1

所以基本上我试图在 CLion 中启动 BluePill (stm32f103c8t6) 的程序,我选择 ST-Link 作为 OpenOCD 的 cfg。首先它要求选择时钟速度,然后询问传输(hla_swd 或 jtag),然后它就像

enter image description here

C:\Users\asd567\Downloads\OpenOCD-20211118-0.11.0\bin\openocd.exe -s C:\Users\asd567\Downloads\OpenOCD-20211118-0.11.0\share\openocd\scripts -f C:\Users
Open On-Chip Debugger 0.11.0 (2021-11-18) [https://github.com/sysprogs/openocd] 
Licensed under GNU GPL v2
libusb1 09e75e98b4d9ea7909e8837b7a3f00dda4589dc3
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info clock speed 4000 kHz
Error: BUG: current_target out of bounds
clion bluepill st-link
1个回答
0
投票

解决了。 我更改了运行/调试配置 -> OCD“程序名称” -> 板配置文件中的配置

https://gist.github.com/hemalchevli/2d483df78d1f484229410f1c6a439254

或者制作一个 bluepill.cfg 并粘贴此代码

#source [find interface/stlink-v2-1.cfg]
source [find interface/stlink-v2.cfg]

transport select hla_swd

source [find target/stm32f1x.cfg]

#reset_config srst_only

reset_config none separate

#Enable Trace output in open OCD
#Not tested yet
#tpiu config external uart off 72000000 2000000
© www.soinside.com 2019 - 2024. All rights reserved.