Hi!
I start to learn STM32 (STM32F103GB on MCBSTM32 board, example project "blinky") and have faced with following problem: I can't insert breakpoint in C and "insert/remove breakpoint" button on Debug Toolbar always disabled. The only way to define breakpoint is double-click on grey window bar in disasm window. Program executed, breakpoint in disasm occurs... but what can I do to use breakpoits in C?
Regards, Ilya.
You can set your breakpoints before run or you can set advanced breakpoints
I don't think it's a big deal to stop and then set a breakpoint. Depends on the application.
If application is working in a more complex system, let's say with CAN communication and motor control, you can't afford to stop the program just to set a breakpoint.....
I have J-link and ULINK debuggers. Using ULINK I can set and clear breakpoints even when the software runs, but if I use J-link I can only set/clear first breakpoint, and I cannot set second breakpoint until I stop execution. I don't know what is causing this but I don't think it's a big deal to stop and then set a breakpoint.
I am useng newest version of MDK-ARM and ST-Link programmer. When program is downloaded and run, it is not possible to set or clear breakpoints. You must stop the program, set breakpoints and start program. This is not issue with hardware, because this works with IAR IDE.
Any ideas how to get this functionality in Keil IDE?
Reinstall Keil and jLink drivers... That's all.
Shouldn't you tell how you solved your problem?
Thank you for your attention! The problem solved.
Are you able to set breakpoints if you debug using Simulator? (In the Debug tab of your project options it is from left)
I added printscreens with these options (see at link for previous pictures). The result remained the same...
In your project options (Alt+F7) - Output tab: Debug Information should be checked - Linker tab: Misc. controls should contain --debug With these options set, rebuild your project and see if you can place breakpoints in your C code
The text from command window:
Set JLink Project File to "C:\my_temp\Blinky\JLinkSettings.ini" JLink info: ------------ DLL: V4.15n, compiled Jun 18 2010 19:55:09 Firmware: J-Link ARM-Pro V1.x compiled Jan 22 2010 19:00:58 Hardware: V1.10 S/N : 171100029 Feature(s) : RDI, FlashBP, FlashDL, JFlash, GDB * JLink Info: TotalIRLen = 9, IRPrint = 0x0011 * JLink Info: Found Cortex-M3 r1p1, Little endian. * JLink Info: TPIU fitted. * JLink Info: FPUnit: 6 code (BP) slots and 2 literal slots ROMTableAddr = 0xE00FF003 Target info: ------------ Device: STM32F103VB VTarget = 3.325V State of Pins: TCK: 1, TDI: 0, TDO: 0, TMS: 0, TRES: 1, TRST: 1 * JLink Info: TotalIRLen = 9, IRPrint = 0x0011 * JLink Info: Found Cortex-M3 r1p1, Little endian. * JLink Info: TPIU fitted. * JLink Info: FPUnit: 6 code (BP) slots and 2 literal slots Hardware-Breakpoints: 6 Software-Breakpoints: 2048 Watchpoints: 4 JTAG speed: 3000 kHz Load "C:\\my_temp\\Blinky\\Obj\\BlinkyOPT.AXF" Verify failed on VerifyBlock()*** error 57: illegal address (0x1FFFF800) * JLink Info: TotalIRLen = 9, IRPrint = 0x0011 * JLink Info: Found Cortex-M3 r1p1, Little endian. * JLink Info: TPIU fitted. * JLink Info: FPUnit: 6 code (BP) slots and 2 literal slots
It's so strange... I try to use ST-LINK as in-circuit debugger and it's correctly work with JTAG interface. But gives errors with SWD when I try to enter a debug session. These errors displays in windows with "OK" button only. First: "internal command error", second: "error while attempting to write 16 bytes to 0x1ffff800". And at result situation like with J-Link - program code executed, breakpoints avaliable only in disasm window. Printscreen with errors and debugger options at link: www.flickr.com/.../53850447@N05/?saved=1
I can't see your Output tab - do you have turned on debug information there?
By the way - you post small images where most of the image is wasted with the editor. Either post your photos at full screen resolution, or reduce the size of the IDE so that the relevant information fills more of the image.
Maybe I do something wrong? (workflow on printscreens at link: www.flickr.com/.../53850447@N05/?saved
Get your own thread, and this time don't expect people to hack your computer to look at your source code.
To post all required information - including error messages.
View all questions in Keil forum