OpenOCD
Open On-Chip Debugger (OpenOCD) 旨在为嵌入式目标设备提供调试、系统内编程和边界扫描测试。它是在调试适配器的帮助下实现的,调试适配器是一个小型硬件模块,可以帮助为被调试的目标提供正确的电信号。这些都是必需的,因为调试主机(在OpenOCD上运行)通常不支持这样的信号,或连接到目标所需的连接器。
GDB and OpenOCD
Connecting to GDB
-
A socket (TCP/IP) connection is typically started as follows:
target extended-remote localhost:3333or
target remote localhost:3333 -
A pipe connection is typically started as follows:
target extended-remote | openocd -c "gdb_port pipe; log_output openocd.log"
常见问题
1. 由于仿真环境运行频率较低,导致 Jtag Server 运行频率过低,从而导致 GDB 连接过程中出现 “timeout” in “qSupported” 错误。
解决方法:
-
尝试提高Jtag server 端频率,到 20Khz。
-
修改 GDB 连接超时时间,GDB cmd下执行如下命令:
show remotetimeoutset remotetimeout 60target remote localhost:3333
OpenOCD是一个开源的On-Chip调试工具,用于调试和编程嵌入式目标设备。它通过调试适配器与目标设备交互。本文介绍了如何通过TCP/IP或管道连接GDB,并提供了针对‘timeout’错误的解决方案,如调整JTAG服务器频率和修改GDB超时时间。
137

被折叠的 条评论
为什么被折叠?



