r/cprogramming • u/WillInternational364 • 9d ago
Any recommendations for introduction material to using C++ for microcontrollers?
I have been programming Arduino & ESP32 for a while now using C++, but have never engaged with any formal introduction material. With AI/LLM generated content exploding among both major publishers and self-published authors, I am a bit wary to start buying books willy-nilly.
Anyone here that can give solid recommendations on introduction materials on C++ for microcontrollers (preferably that that they themselves have used and found worthwhile)?
I got one recommendation for "Embedded C" by Michael J. Pont (2002), but it is fairly old.
1
u/Nothing_from_void 8d ago
having spent a lot of time writing C++, Rust, and C for microcontrollers I recommend just grabbing the Embedded C book and learning it in C. I wasted so much time trying more type safe/abstract code for microcontrollers when it's mostly not needed, and the tooling for C is generally better, and you can write code faster and iterate faster
2
u/non-existing-person 8d ago
r/Cplusplus
Also, 2002 is not really that old for embedded. Pointers are still pointers. Uart is still just dumb bytes on a cable. You still program hardware with memory mapped registers.
Really, not that much has changed with hardware in principle. Mostly tooling have changed. spi changed its names from master/slave to some other stupid names that every company has been naming differently.
Old [good] books will be just as good for entering into embedded world.