Wednesday, June 13, 2018

TMK with ChibiOS

Setting up the build environment

I usually compile my firmware in Linux. I use either Ubuntu in a virtual machine or Raspbian on a Raspberry Pi. They are both Debian based and the same procedure should work on either.

Start with a fresh install of the OS.

Then update the list of software packages.

sudo apt-get update

Update all the installed packages.

sudo apt-get upgrade

Install the required packages for compiling TMK and ChibiOS

sudo apt-get install gcc-avr avr-libc dfu-programmer git make gcc-arm-none-eabi

Clone the TMK repository

git clone https://github.com/di0ib/tmk_keyboard.git

Change to the chibios folder

cd tmk_keyboard/tmk_core/tool/chibios/

Clone the stable branch of ChibiOS repo

git clone -b stable_17.6.x https://github.com/ChibiOS/ChibiOS.git

Clone the ChibiOS-Contrib repo

git clone https://github.com/ChibiOS/ChibiOS-Contrib.git

That's it. You should be able to compile for TeensyLC, Teensy3.2, Maple Mini, etc...

This video goes through the process on Ubuntu 18.04 LTS server.