We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hi all,
Really hope you guys can help – I’m running late with this project and may have no choice but to change compilers if this isn’t resolved soon.
I am using MDK-Lite with a Segger JLink for a STM32L031 target. The code can be successfully complied/downloaded/executed on the target without issues, however I cannot set breakpoints at all. When not in debugging mode, I can set breakpoints but they turn into greyed-out ‘!’ symbols when I start the debugger. I have debug information checked in the output tab.
IDE-Version: µVision V5.24.2.0
Tool Version Numbers: Toolchain: MDK-Lite Version: 5.24.1 Toolchain Path: C:\Keil_v5\ARM\ARMCC\Bin C Compiler: Armcc.exe V5.06 update 5 (build 528) Assembler: Armasm.exe V5.06 update 5 (build 528) Linker/Locator: ArmLink.exe V5.06 update 5 (build 528) Library Manager: ArmAr.exe V5.06 update 5 (build 528) Hex Converter: FromElf.exe V5.06 update 5 (build 528) CPU DLL: SARMCM3.DLL V5.24.1 Dialog DLL: DARMCM1.DLL V1.18.0.0 Target DLL: Segger\JL2CM3.dll V2.99.26.0 Dialog DLL: TARMCM1.DLL V1.13.0.0
Put the optimization level to -O0 in Options for target -> C/C++ tab
It should help you.
I tried both suggestions but nothing has changed - still no breakpoints
Just to clarify, I can set breakpoints in the disassembly window but not in the source window. When I stop the debugger I can then set breakpoints in the source.
There MUST be a setting or a symbol file that is not being loaded correctly.... I find it hard to believe that this is not a known issue with this compiler - setting of breakpoints is such a fundamental thing!
in the build output window it displays: Hardware-Breakpoints: 4 Software-Breakpoints: 8192 Watchpoints: 2
What do you mean by, "stop the debugger" ?
I think it is expected/intended behaviour that breakpoints cannot be set while the target is running ?