Templates

last modified: October 23, 2025

Extreme Integers – Doom from Below

Posted on 2022-09-04— C++, Improve your Code, Learn

I take you on a short, pragmatic journey into C++ integer pitfalls—why signed and unsigned types behave oddly, how literals, negation and overflow can bite, and simple tests to reveal compiler quirks. If you work in embedded or systems code, please read the full post for examples and guidance.

Read this post

C++ Templates for Embedded Code (Part 2)

Posted on 2019-07-27— C++, Improve your Code, Learn

I continue exploring C++ templates for embedded systems, showing template classes, pin abstraction, and combining Sender and Pin examples to reduce firmware size and improve code clarity. I explain static methods, type aliases, and trade-offs between runtime flexibility and efficiency. Read the full post to see code and assembly comparisons.

Read this post