Skip to content

Instantly share code, notes, and snippets.

@kienvo
Last active November 4, 2021 07:34
Show Gist options
  • Save kienvo/11d1b6ecee76cd2b0643b40604ae1daf to your computer and use it in GitHub Desktop.
Save kienvo/11d1b6ecee76cd2b0643b40604ae1daf to your computer and use it in GitHub Desktop.
vscode remote debugging
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "GDB debug",
"type": "cppdbg",
"request": "launch",
// Edit this
"program": "${workspaceFolder}/path/to/execute file",
"args": ["-r 2", "/dev/spidev0.0"],
"stopAtEntry": true,
// cwd must be in root folder of Makefile
"cwd": "${workspaceFolder}",
"environment": [],
"externalConsole": false,
"MIMode": "gdb",
// For arm
"targetArchitecture": "arm64",
// Setup server
"preLaunchTask": "gdbserverOn",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
],
// debug client
"miDebuggerPath": "/usr/bin/gdb-multiarch",
// remote host
"miDebuggerServerAddress": "192.168.1.138:4444"
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment