Attempted to debug the External RTC Sample. I think I set up and figured out the launch_json parameters successfully as I don’t get any error messages like the miDebuggerPath is invalid, etc., but maybe I didn’t get this all right.
Not sure what it is doing and why I can’t seem to debug the code with breakpoints? It seems to be running but not as expected. Below is my launch.json, and output from the TERMINAL and DEBUG CONSOLE. Please note I’m going to move on from this issue as it is not critical for me right now.
Here are my launch.json parameters which I had to change to get the debugger to work (but I don’t know if I did this correctly):
“name”: “(gdb) Launch”,
“type”: “cppdbg”,
“request”: “launch”,
“launchCompleteCommand”: “None”,
“program”: “${workspaceRoot}\build\zephyr\zephyr.elf”,
“args”: [],
“stopAtEntry”: false,
“cwd”: “${workspaceFolder}”,
“environment”: [],
“externalConsole”: false,
“MIMode”: “gdb”,
“miDebuggerPath”: “arm-none-eabi-gdb.exe”,
“setupCommands”: [
{
“description”: “Enable pretty-printing for gdb”,
“text”: “-enable-pretty-printing”,
“ignoreFailures”: true
}
]
OUTPUT shows nothing.
TERMINAL shows this:
Windows PowerShell
Copyright © Microsoft Corporation. All rights reserved.
Try the new cross-platform PowerShell https://aka.ms/pscore6
PS C:\nfed\nrf9160-feather\samples\external_rtc> & ‘c:\Users\Steve.vscode\extensions\ms-vscode.cpptools-1.1.1\debugAdapters\bin\WindowsDebugLauncher.exe’ ‘–stdin=Microsoft-MIEngine-In-ut1jrkrq.ksj’ ‘–stdout=Microsoft-MIEngine-Out-e0blmkda.hun’ ‘–stderr=Microsoft-MIEngine-Error-wi14adqq.pts’ ‘–pid=Microsoft-MIEngine-Pid-hcmznnye.qza’ ‘–dbgExe=C:\Program Files (x86)\GNU Tools Arm Embedded\9 2019-q4-major\bin\arm-none-eabi-gdb.exe’ ‘–interpreter=mi’
DEBUG CONSOLE shows this:
=thread-group-added,id=“i1”
GNU gdb (GNU Tools for Arm Embedded Processors 9-2019-q4-major) 8.3.0.20190709-git
Copyright © 2019 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type “show copying” and “show warranty” for details.
This GDB was configured as “–host=i686-w64-mingw32 –target=arm-none-eabi”.
Type “show configuration” for configuration details.
For bug reporting instructions, please see:
http://www.gnu.org/software/gdb/bugs/.
Find the GDB manual and other documentation resources online at:
http://www.gnu.org/software/gdb/documentation/.
For help, type “help”.
Type “apropos word” to search for commands related to “word”.
Warning: Debuggee TargetArchitecture not detected, assuming x86_64.
=cmd-param-changed,param=“pagination”,value=“off”