ARM semihosting ITM, available in M3/M4/M7, output debug msgs over serial SWO / SWV (protocol) ETM SWD: SWCLK, SWDIO plus (optional) SWO SWO is an optional extension of the SWD interface RTT (Segger) [[https://github.com/blacksphere/blackmagic/wiki|Black Magic Probe]] https://www.codeinsideout.com/blog/stm32/swv/ ====== ARM ====== https://interrupt.memfault.com/blog/a-deep-dive-into-arm-cortex-m-debug-interfaces ====== JTAG ====== [[http://dangerousprototypes.com/docs/Bus_Blaster_v2_design_overview|Bus Blaster]] http://openocd.sourceforge.net/doc/html/index.html#toc_OpenOCD-Project-Setup [[http://www.cs.berkeley.edu/~mavam/teaching/cs161-sp11/gdb-refcard.pdf|GDB cheatsheet]] http://hertaville.com/2012/09/16/part-3-debugging-openocd-0-6-0/ http://snowcap.fi/blog/2011/11/21/openocd-with-swd/ ====== J-Link ====== https://gnu-mcu-eclipse.github.io/debug/jlink/install/ https://boundarydevices.com/debugging-using-segger-j-link-jtag/ ====== OpenOCD ====== https://wrongbaud.github.io/stm-xbox-jtag/ https://www.allaboutcircuits.com/technical-articles/getting-started-with-openocd-using-ft2232h-adapter-for-swd-debugging/ ====== gdb ====== {{ :gdb_cheat_sheet.pdf |}} https://www.youtube.com/watch?v=PorfLSr3DDI See gdb chapter in 21st Century C https://github.com/cyrus-and/gdb-dashboard https://news.ycombinator.com/item?id=19972435 https://interrupt.memfault.com/blog/cortex-m-breakpoints Some interesting articles: https://jvns.ca/blog/2014/02/10/three-steps-to-learning-gdb/ https://jvns.ca/blog/2016/08/10/how-does-gdb-work/ https://jvns.ca/blog/2018/01/04/how-does-gdb-call-functions/ ====== gdb automated tests ====== - Discussion on linkedin Embedded Systems Design https://developers.redhat.com/blog/2017/11/10/gdb-python-api/ https://answers.launchpad.net/gcc-arm-embedded/+question/256851 https://launchpad.net/~terry.guo/+archive/ubuntu/gcc-arm-embedded http://thread.gmane.org/gmane.linux.ports.ia64/22770 alternative: http://www.isystem.com/products/software/testidea-pro [[https://interrupt.memfault.com/blog/automate-debugging-with-gdb-python-api|GDB with Python]] https://interrupt.memfault.com/blog/using-pypi-packages-with-GDB https://interrupt.memfault.com/blog/automate-debugging-with-gdb-python-api https://interrupt.memfault.com/blog/gdbundle-plugin-manager [[https://www.youtube.com/watch?v=QQcp8CPjkoY|Debugging ARM hard faults with gdb]]