2021-03-15 03:52 AM
This tool only supports 5 breakpoints!
Orginal and cloned versions of j-link have a lot more ability!
I can not believe!
Only 5 breakpoints are not useful at all in the debugging environment!
Because of my interest in st company, while I have four other debuggers, I also bought stlink v3, but it is not suitable for debugging!
Am I wrong, does it support more than 5 breakpoints?
I am very upset about this
:(
2021-03-15 04:31 AM
I think you misunderstand.
Your stm32 only supports 5 breakpoints in its built-in hardware.
The j-link uses a trick to get stm32 to have more breakpoints than are supported by hardware. Looking at the segger website, what seems to happen is that the J-link has to reprogram the FLASH where you want a breakpoint to insert some kind of "software interrupt" (SWI). On executing this SWI, program execution stops. And on continue, the SEGGER first gets the stm32 to execute whatever instruction was replaced by the SWI.
I don't know why other debuggers don't copy this. Maybe it's very complicated and hard to do. Or maybe segger have a patent on this technique. Or maybe it's because your debugger shouldn't modify FLASH as part of the debug cycle.
Hope this helps,
Danish
2021-03-15 05:13 AM
You can wear out flash fast with that scheme and a lot of debugging...
2021-03-15 05:18 AM
The point is that comparing the old version of jlink with the new stlink product is not equal at all!
The older version of jlink is much more complete and useful.
St company is very advanced and it is very sad to see such a useless product.
2021-03-15 05:21 AM
You can use software breakpoints.
You might also want to refine your debugging technique so you don't need to dead stop the MCU to understand what the code you wrote does.