For this project I decided to lean on the excellent TMK Keyboard Firmware. It has a ton a great features - multi-layer key maps, mouse keys, consumer keys, function callbacks for key presses, and more. Only one "problem" - it is written in AVR C with a Makefile based build, and I wanted to use the Arduino IDE to build and load the firmware. So I ported the tmk_keyboard project to the Arduino platform as a library, and creatively named it arduino_tmk_keyboard.
Click the button below to download the library as a zip file.
- terminal_bluefruit_converter - this is your main sketch, and probably the only place where you'll need to make any actual code changes. The bootstrapping of the firmware and any custom functions are defined here, and your keymaps are configured in this file as well.
- config.h - this is the main configuration file; it is included at the top all other code files so it is a great place to define macros, as well as quickly enable and disable features including debug messages
- include_api.cpp - this is a hack to properly pull in the library's API classes. Don't touch this file.
- include_tmk_.c - this is another hack to pull in the C code from the TMK firmware. Don't touch this either.