2019-06-18 06:43 AM
Hi guys,
I use an STM32L072CZY6TR_LoraWAn and the IDE Keil Uvision 5 and i want to use the "Debug (printf) viewer" to visualize data. I'm a new user of Keil and i search someone who can explain to me what is the code that i need to implement to realize that.
The code should realize the same function that Printf() on Visual studio for example. I try a lot of think that i see on the internet but i don't obtain good results.
Thanks for helping me.
Tim
Solved! Go to Solution.
2019-06-19 04:42 PM
Hello
This is correct. I am currently writing an appnote that details all the useful debug features uVision has for ST Cortex-M0, M0+.
To get printf you will select DAP instead of ITM.
Attached is a section of the appnote detailing how to set this up.
It is easy.
Thanks
Bob Boys
bob.boys@arm.com
2019-06-18 06:57 AM
SWV/SWO methods don't work on CM0(+) devices, you'd have to use a different method.
Look for @Bob Boys app notes on the Event Recorder methods
On the Murata part I've also used PA0 UART4_TX for debug
2019-06-19 04:42 PM
Hello
This is correct. I am currently writing an appnote that details all the useful debug features uVision has for ST Cortex-M0, M0+.
To get printf you will select DAP instead of ITM.
Attached is a section of the appnote detailing how to set this up.
It is easy.
Thanks
Bob Boys
bob.boys@arm.com
2019-06-19 08:22 PM
Are there any clever tricks to determining if the CM0(+) is currently attached to a debug pod in Keil (or in general)? There is a BKPT/HardFault trick, but perhaps there is something more subtle?
The SWDIO/SWCLK pins on the L072 in the Murata module can be mapped to LPUART1 RX/TX
2019-06-20 02:10 AM
Thanks for your answer. I really apreciate it. :)
2019-06-20 02:50 AM
That's seem working :) Thanks for the time you take to answer at my question :=)
2019-07-25 10:12 AM
Hello
I have finished the appnote describing 1) using Event Recorder in Keil MDK to provide printf (no UART is used) and various useful timing values about your program. I addition is a section on Power Measurement using Keil ULINKplus.
http://www.keil.com/appnotes/docs/apnt_321.asp
This can be easily adapted to work with any STM32 Cortex-M with or without SWV.
Comments are welcome.
Thanks
Bob