Open Source ATtiny Adding Machine

Clem Mayer constructed an open source desktop calculator with the ATtiny3226-SU.

Jeremy Cook
10 days ago

Clem Mayer (AKA MAYER MAKES) used a hefty desk calculator for a decade at his old job. This type of calculator’s size and full-sized keys make them ideal for punching in number after number, day after day. While the basic concept is solid, he thought he could improve on the idea with an open source “four-banger” model that includes basic add / subtract / multiply / divide functionality and that runs on batteries, not mains power.

The resulting calculator features a 20-key input setup with Cherry MX keyswitches and custom 3D-printed keycaps. The switches are wired together in a diode-based matrix setup to conserve IO pins, and calculation results are shown on a 20x4 alphanumeric LCD. Power is provided via a pair of AAA batteries, and its case uses the lid of a die-cast electronics enclosure as its bottom, while the top is 3D-printed.

For processing, Mayer selected one of the “new” ATtiny series chips, the ATtiny3226-SU, which gives him a full 32 KB of Flash memory for libraries and code. When all was said and done, the whole program fit onto 8 KB, but, given the different ATtiny options available, it would be easy to swap in a less capable (and less expensive) processor if he needed to save on BOM costs.

As demonstrated towards the end of the video, there are a few limitations to its calculating ability per ATtiny’s eight-bit architecture. Specifically, it can only work with numbers up to a certain size, and it only produces up to two digits after the decimal place. This, however, isn't a problem for Mayer, and could be overcome with a bit of clever programming anyway.

Further documentation and build resources are available if you want to create your own, or even expand on its functionality.

Jeremy Cook
Engineer, maker of random contraptions, love learning about tech. Write for various publications, including Hackster!
Latest articles
Sponsored articles
Related articles
Latest articles
Read more
Related articles