THREEBOARD: short ON KEYS, long ON DOCUMENTATION
As peripherals go, few are hacked on much more than keyboards. The layouts, the shapes, the sizes, materials, and even the question of what a keyboard is are all on the table for tinkering. in that vein, [TaylorConor] released his simplified keyboard called the threeboard on GitHub, having only three keys and replicating a full keyboard.
We’ve covered keyboards built with chording in mind, wrapped around coffee cups, and keyboards with joysticks for added speed. So why cover this one? What makes it different? The execution is superb and is a great example to look at next time you’re making a project you want to show off. The keyboard is just three mechanical switches, two 8-bit binary displays (16 LEDs total), three status LEDs, and three LEDs showing the current layer (four layers). The comprehensive user’s manual discusses it all. There is a reliable Atmega32U4 microcontroller and two EEPROM chips at its heart.
Where this project shows off is the testing. It has unit tests, simulated integration tests, and simulated property tests. because all the code is in C++, unit testing is relatively straightforward. The integration and property tests are through a simulator. rather than recompiling the code with some new flags, he uses the simavr AVR simulator, which implies it simulates the same binary file that gets flashed onto the microcontroller. This method implies the design is evaluated and debugged through GDB. It’s an amazing technique we’d love to see much more of in hobby projects. marketing speak might call this a “digital twin” but the idea is that you have a virtual version that’s simpler to work on and has a tighter iteration loop while being as close as possible to the physical version.
[TaylorConor’s] goal was to create a from-scratch microcontroller project with easy-to-read code, fantastic documentation, and best practices. We think he nailed it. So feel totally free to run the simulator or jump best into building one for yourself. All the hardware is under a CERN-OHL-P license, and the firmware is under GPLv3.