VS Arduino
>> >> Unable to pause or stop GDB with BlackMagicProbe on STM32F103RET6
https://www.visualmicro.com/forums/YaBB.pl?num=1581419960

Message started by Natsuki-chan on Feb 11th, 2020 at 11:19am

Title: Unable to pause or stop GDB with BlackMagicProbe on STM32F103RET6
Post by Natsuki-chan on Feb 11th, 2020 at 11:19am
After a long time of stopping gdb via taskmanager I am creating this issue.

The thing is that when I want to pause or stop the debugger Visual Studio just freezes.
I have to go to Task Manager and end the gdb task. This is getting quite anoying after a long time.

Debugging itself works like a charm and does not feel different from debugging Java or C#.
The pausing is used to add new breakpoints during debugging that should work(It works in GDB via the process itself)

Title: Re: Unable to pause or stop GDB with BlackMagicProbe on STM32F103RET6
Post by Simon Hopkinson on Feb 11th, 2020 at 1:36pm
Thanks for the report and we will look into this further.

Would it be possible to attach the logs from a build (with verbose + properties on as shown at top of page) just so we have all of the information.

You can just add the breakpoints while it is running as far as I know without the pause action, however it still shouldn't hang.

Title: Re: Unable to pause or stop GDB with BlackMagicProbe on STM32F103RET6
Post by Natsuki-chan on Feb 11th, 2020 at 1:59pm
Yes it is possible to add breakpoints but they are disabled. You either need to pause or restart the build to enable them.

Included is the log file as wanted and the selected options for debugging+board options
https://www.visualmicro.com/forums/YaBB.pl?action=downloadfile;file=buildlog_005.txt ( 1162 KB | 5 Downloads )
stm32_enabled_options.png ( 32 KB | 4 Downloads )

Title: Re: Unable to pause or stop GDB with BlackMagicProbe on STM32F103RET6
Post by Simon Hopkinson on Mar 11th, 2020 at 4:21pm
Thanks for the information, and I am still unsure exactly where the issue lies at present, but a few potential options:-

Potential Fix #1
1) If you add a Local Board.txt to the project (Right Click Project > Add > Local Board.txt), and add the below entry to it, then save and try attaching the debugger again and see if the issue is the same?
[code]# Amend Interpretation Mode of GDB for BMP
tools.bmp_upload.debug.args=--interpreter=mi -nh -b 115200 -ex "target extended-remote \\.\{serial.port}" -ex "monitor swdp_scan" -ex "attach 1"[/code]

Potential Fix #2 (for exiting initially)
(If the above doesn't help)
a) Open a new VS Command Window (View > Other Windows > Command Window)
b) Enter the command Debug.MIDebugLog /On /OutputWindow and press Enter
c) Start the debugger as normal again, and ensure the VS command window is still visible
d) Enter the command monitor exit and press Enter
e) Press Stop as normal on the Debug Toolbar - hopefully the GDB instance will vanish this time?
f) There will be a VERY detailed log available in the Output > Debug Window which may reveal more information about the issues

Let us know if you have any issue with the above elements, and if it improves the situation at all.



VS Arduino » Powered by YaBB 2.6.12!
YaBB Forum Software © 2000-2024. All Rights Reserved.