Debugging Arduino firmware with print statements

2 Просмотры
Издатель
#debug #print #arduino
We will get to the basics of using a simple debugging technique: the print statements. We will work our way step by step from adding some conditional statements, to adding a header file and finally a library. To toggle the debug flag on and off will still be as simple as commenting the first line. The original firmware code size will be exactly the same when the debug flag is off. At the end, I share my thoughts on another type of debugging as well as how important it is to incorporate developer happiness in debugging and make it as simple as possible.

⏰ TIMESTAMPS
0:00 Intro
00:30 No print statements
01:33 Add print statements
03:14 Add conditional #ifdef for debug
04:46 Define a function
06:40 Add more info as part of debugging
08:40 Add header file
09:57 Add a library instead
12:56 Add more functions
14:47 My thoughts on using a debugger and developer happiness!

???? DEMO FILES
Debugging with #ifdef DEBUG
Debugging with ArduinoTrace library
Debugging with #ifdef and ArduinoTrace library

???? WATCH NEXT
Arduino CLI and the art of command line
Makefiles for using with Arduino
6 ways to access the serial monitor
Arduino firmware on ATmega328p or SAMD21

???? LINKS SHOWN
Arduino ()
Standard Predefined Macros #Standard-Predefined-Macros
SAMD21 M0-Mini
ARDUINO ZERO
ATSAMD21G18 microcontroller
Arduino Serial communication
Do comments get translated to machine code?
The C preprocessor
Arduino millis()
GitHub search DebugUtils
ArduinoTrace library
Chrome DevTools debugger for JavaScript
Arduino Pro IDE
GDB and OpenOCD
The Philosophy of Ruby A Conversation with Yukihiro Matsumoto

???? PRODUCTION GEAR AND TOOLS
Davinci Resolve for video editing
iPhone 11 for recording video
QuickTime for recording laptop screen
Microphone Audio Technica ATR2100-USB for voice recording
IKEA TERTIAL Work lamp stand hacked as a microphone stand
Tripod SLIK SDV-10iPhone holder Xiletu XJ-8
dotfiles for terminal configuration
for YouTube thumbnail and titles
YouTube Audio library for sound effects and background music
Категория
Поделки своими руками
Комментариев нет.
Яндекс.Метрика