Summary
Keywords
Full Transcript
This lesson explains "debugging by printf" as the most common software tracing technique. You'll learn how to implement printf on the TivaC LaunchPad board, as well as NUCLEO-L152. You'll also explore some shortcomings of this primitive technique. Contents with Timestamps: ------------------------- 3:18 Adding printf tracing to the BSP code 4:25 Attempts to run and the hardcoded breakpoints 6:00 MicroLIB and the fputc() function 7:25 Instrumentation Trace Macrocell (ITM) 8:00 Demonstration of STM32 NUCLEO board 8:50 Sending output via ITM 9:40 Setting up ST-LINK for tracing with ITM 9:55 Opening view "Debug (printf) Viewer" 10:58 Universal Asynchronous Receiver and Transmitter (UART) 12:11 Code for sending printf output via UART in TivaC 14:19 Opening and connecting serial terminal (Termite) 16:25 Tracing macros (variadic macros and __VA_ARGS__) 19:42 Build Configurations 20:18 Creating the "spy" build configuration for software tracing 22:35 Costs and overheads of printf tracing 23:40 Impact of floating-point format specification 24:45 Impact of printf tracing on execution time End Notes: ---------- Companion web-page to this video course https://www.state-machine.com/video-course/ Project download for this lesson: https://www.state-machine.com/course/lesson45.zip GitHub repository for projects for this video course: https://github.com/QuantumLeaps/modern-embedded-programming-course Transcript of this lesson: https://www.state-machine.com/course/lesson45.txt References resources: --------------------- Termite -- a simple RS232 terminal: https://www.compuphase.com/software_termite.htm STM NUCLEO-L152RE board Instrumentation Trace Macrocell https://developer.arm.com/documentation/ddi0439/b/Instrumentation-Trace-Macrocell-Unit Music credits: -------------- The background music comes from: https://www.bensound.com/royalty-free-music/track/straight
