In your program code, you often deal with unitless values. You can add the units of measurements in the variable or function name, or by adding a comment, but there is still the risk you accidentally make wrong conversions. I will describe how to handle units of measurements for common time values using a custom…
Tag: compiler
Class or Module for Singletons?
Should you use a class or a module with a namespace for a singleton interface in your firmware? I found there are many misunderstandings which lead beginners to make a wrong decision in this matter. With this article, I try to visualize these misunderstandings with simple example code for the Arduino platform. Before we start,…