Newer
Older
{
// 使用 IntelliSense 了解相关属性。
// 悬停以查看现有属性的描述。
// 欲了解更多信息,请访问: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"preLaunchTask": "dbg",
"name": "Debug APP firmware by gdb @ Linux", // 配置名称(包含环境名),将会在启动配置的下拉菜单中显示
"type": "cppdbg", // 配置类型,这里只能为 cppdbg
"request": "launch", // 请求配置类型,可以为 launch(启动)或 attach(附加)
"program": "${config:RT-Thread Smart.Program}", // 将要进行调试的程序的路径
"args": [], // 程序调试时传递给程序的命令行参数,一般设为空即可
"stopAtEntry": true, // 设为 true 时程序将暂停在程序入口处,我一般设置为 true
"cwd": "${workspaceFolder}", // 调试程序时的工作目录
"environment": [], // 环境变量
"serverLaunchTimeout": 2000, // 超时时间设置
"targetArchitecture": "ARM", // 生成目标架构,一般为x86或x64,可以为x86, arm, arm64, mips, x64, amd64, x86_64
"externalConsole": true, // 调试时是否显示控制台窗口,一般设置为 true 显示控制台
"MIMode": "gdb", // 指定连接的调试器,可以为gdb或lldb。但目前 lldb 在 windows 下没有预编译好的版本。
"miDebuggerServerAddress": "${config:RT-Thread Smart.Server IP}:${config:RT-Thread Smart.Server Port}", // 被调试的开发板 IP 地址和端口号
"setupCommands": [
{
"description": "为 gdb 启用整齐打印",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
],
// Linux 下的 gdb 调试器路径(工具链包含 gdb)
"miDebuggerPath": "${workspaceFolder}/../../tools/gnu_gcc/gdb/gcc-arm-none-eabi-10.3-2021.10-x86_64-linux/bin/arm-none-eabi-gdb"