Complete Computing Environment: Hardware Hacking

Table of Contents

(provide 'cce-arduino)

Arduino Programming

More recently, I've been trying to get back in to hardware and "maker" crap, starting with my body computing system that I'm building. A part of this project is going to be based on the Tinylily wearable Arduino derivative. My system should support the actual Arduino programming environment, as well as providing an easy interface to for syntax checking files on the fly, and easily compiling and testing.

(install-pkgs '(arduino-mode))

We can easily tell flymake to run make check-syntax on ino files like so, and then it's a simple matter of adding a check-syntax job to my Make files:

    $(CXX) -c -include Arduino.h   -x c++ $(CXXFLAGS)   $(CPPFLAGS)  -fsyntax-only $(CHK_SOURCES)
(eval-after-load 'flymake (lambda ()
                            (add-to-list 'flymake-allowed-file-name-masks '("\\.ino\\'" flymake-simple-make-init))))

Working with Quantum MK Firmware

I've got a number of mechanical keyboards that I use for various usecases:

  • An Ergodox Infinity for work
  • An OLKB Preonic for when I'm not at my desk
  • An OLKB Planck that I am currently trying to find a new use for, possibly as a MIDI device.

To make things easier, and to eventually be able to standardize my layouts entirely, I'm using the QMK firmware originally developed for the Planck and Preonic. It's easy to work with, and can run on a lot more limited hardware (read: AVR) compared to the firmware which the Ergodox Infinity ships with. QMK supports a tonne of different keybaords, including the Atreus and hand-wired keyboards, which is important since my next keyboard will probably be one of those two. Right now, I'm playing with the idea of a pair of 8U squares, with various 2U keys in it where thumbs should center. It'll be interesting to see if I actually have it manufactured.

Anyways, I need these toolchains installed, starting with AVR.

- name: AVR programming tools installed
    state: installed
    - gcc-avr
    - gdb-avr
    - dfu-util
    - dfu-programmer
    - avrdude
  when: ansible_pkg_mgr == "apt"

- name: AVR programming tools installed
    state: installed
    - avr-gcc
    - avr-gdb
    - avr-gcc-c++
    - dfu-util
    - dfu-programmer
    - avrdude
  when: ansible_pkg_mgr == "dnf"

Author: Ryan Rix

Created: 2019-05-07 Tue 11:12

Validate XHTML 1.0