Merge branch 'master' of http://github.com/jackhumbert/qmk_firmware
@ -0,0 +1,28 @@
|
||||
FROM debian:jessie
|
||||
MAINTAINER Erik Dasque <erik@frenchguys.com>
|
||||
|
||||
RUN apt-get update
|
||||
RUN apt-get install --no-install-recommends -y build-essential \
|
||||
gcc \
|
||||
unzip \
|
||||
wget \
|
||||
zip \
|
||||
gcc-avr \
|
||||
binutils-avr \
|
||||
avr-libc \
|
||||
dfu-programmer \
|
||||
dfu-util \
|
||||
gcc-arm-none-eabi \
|
||||
binutils-arm-none-eabi \
|
||||
libnewlib-arm-none-eabi \
|
||||
git
|
||||
|
||||
RUN apt-get clean
|
||||
RUN rm -rf /var/lib/apt/lists/*
|
||||
|
||||
ENV keyboard=ergodox
|
||||
ENV keymap=default
|
||||
|
||||
VOLUME /qmk
|
||||
WORKDIR /qmk
|
||||
CMD make clean ; make keyboard=${keyboard} keymap=${keymap}
|
@ -0,0 +1,96 @@
|
||||
# How keys are registered, and interpreted by computers
|
||||
|
||||
In this file, you can will learn the concepts of how keyboards work over USB,
|
||||
and you'll be able to better understand what you can expect from changing your
|
||||
firmware directly.
|
||||
|
||||
## Schematic view
|
||||
|
||||
Whenever you type on 1 particular key, here is the chain of actions taking
|
||||
place:
|
||||
|
||||
``` text
|
||||
+------+ +-----+ +----------+ +----------+ +----+
|
||||
| User |-------->| Key |------>| Firmware |----->| USB wire |---->| OS |
|
||||
+------+ +-----+ +----------+ +----------+ |----+
|
||||
```
|
||||
|
||||
This scheme is a very simple view of what's going on, and more details follow
|
||||
in the next sections.
|
||||
|
||||
## 1. You Press a Key
|
||||
|
||||
Whenever you press a key, the firmware of your keyboard can register this event.
|
||||
It can register when the key is pressed, held and released.
|
||||
|
||||
This usually happens with a [periodic scan of key presses with a frequency around 100 hz](https://github.com/benblazak/ergodox-firmware/blob/master/references.md#typical-keyboard-information).
|
||||
This speed often is limited by the mechanical key response time, the protocol
|
||||
to transfer those key presses (here USB HID), and by the software it is used in.
|
||||
|
||||
## 2. What the Firmware Sends
|
||||
|
||||
The [HID specification](http://www.usb.org/developers/hidpage/Hut1_12v2.pdf)
|
||||
tells what a keyboard can actually send through USB to have a chance to be
|
||||
properly recognised. This includes a pre-defined list of keycodes which are
|
||||
simple numbers from `0x00` to `0xE7`. The firmware assigns a keycode to each
|
||||
key of the keyboard.
|
||||
|
||||
The firmware does not send actually letters or characters, but only keycodes.
|
||||
Thus, by modifying the firmware, you only can modify what keycode is sent over
|
||||
USB for a given key.
|
||||
|
||||
## 3. What the Operating System Does
|
||||
|
||||
Once the keycode reaches the operating system, a piece of software has to have
|
||||
it match an actual character thanks to a keyboard layout. For example, if your
|
||||
layout is set to QWERTY, a sample of the matching table is as follow:
|
||||
|
||||
``` text
|
||||
| keycode | character |
|
||||
|---------+-----------|
|
||||
| 0x04 | a/A |
|
||||
| 0x05 | b/B |
|
||||
| 0x06 | c/C |
|
||||
| ... | ... |
|
||||
| 0x1C | y/Y |
|
||||
| 0x1D | z/Z |
|
||||
| ... | ... |
|
||||
|---------+-----------|
|
||||
```
|
||||
|
||||
## Back to the firmware
|
||||
|
||||
As the layout is generally fixed (unless you create your own), the firmware can
|
||||
actually call a keycode by its layout name directly to ease things for you.
|
||||
|
||||
This is exactly what is done here with `KC_A` actually representing `0x04` in
|
||||
QWERTY. The full list can be found in `keycode.txt`.
|
||||
|
||||
## List of Characters You Can Send
|
||||
|
||||
Putting aside shortcuts, having a limited set of keycodes mapped to a limited
|
||||
layout means that **the list of characters you can assign to a given key only
|
||||
is the ones present in the layout**.
|
||||
|
||||
For example, this means that if you have a QWERTY US layout, and you want to
|
||||
assign 1 key to produce `€` (euro currency symbol), you are unable to do so,
|
||||
because the QWERTY US layout does not have such mapping. You could fix that by
|
||||
using a QWERTY UK layout, or a QWERTY US International.
|
||||
|
||||
You may wonder why a keyboard layout containing all of Unicode is not devised
|
||||
then? The limited number of keycode available through USB simply disallow such
|
||||
a thing.
|
||||
|
||||
## How to (Maybe) Enter Unicode Characters
|
||||
|
||||
You can have the firmware send *sequences of keys* to use the [software Unicode
|
||||
Input
|
||||
Method](https://en.wikipedia.org/wiki/Unicode_input#Hexadecimal_code_input) of
|
||||
the target operating system, thus effectively entering characters independently
|
||||
of the layout defined in the OS.
|
||||
|
||||
Yet, it does come with multiple disadvantages:
|
||||
|
||||
- Tied to a specific OS a a time (need recompilation when changing OS);
|
||||
- Within a given OS, does not work in all software;
|
||||
- Limited to a subset of Unicode on some systems.
|
@ -0,0 +1,4 @@
|
||||
Alps64 keyboard firmware
|
||||
======================
|
||||
|
||||
TODO: to be updated.
|
@ -0,0 +1,4 @@
|
||||
Clueboard keyboard firmware
|
||||
======================
|
||||
|
||||
TODO: to be updated.
|
@ -0,0 +1,4 @@
|
||||
Cluepad number pad firmware
|
||||
======================
|
||||
|
||||
TODO: to be updated.
|
@ -0,0 +1,34 @@
|
||||
#----------------------------------------------------------------------------
|
||||
# On command line:
|
||||
#
|
||||
# make = Make software.
|
||||
#
|
||||
# make clean = Clean out built project files.
|
||||
#
|
||||
# That's pretty much all you need. To compile, always go make clean,
|
||||
# followed by make.
|
||||
#
|
||||
# For advanced users only:
|
||||
# make teensy = Download the hex file to the device, using teensy_loader_cli.
|
||||
# (must have teensy_loader_cli installed).
|
||||
#
|
||||
#----------------------------------------------------------------------------
|
||||
SUBPROJECT_DEFAULT = ez
|
||||
|
||||
# Build Options
|
||||
# comment out to disable the options.
|
||||
#
|
||||
BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
|
||||
MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE ?= no # Console for debug(+400)
|
||||
COMMAND_ENABLE ?= yes # Commands for debug and configuration
|
||||
CUSTOM_MATRIX ?= yes # Custom matrix file for the ErgoDox EZ
|
||||
SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
|
||||
NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
|
||||
MIDI_ENABLE ?= no # MIDI controls
|
||||
UNICODE_ENABLE ?= yes # Unicode
|
||||
|
||||
ifndef QUANTUM_DIR
|
||||
include ../../Makefile
|
||||
endif
|
@ -0,0 +1,36 @@
|
||||
#ifndef KEYBOARDS_ERGODOX_CONFIG_H_
|
||||
#define KEYBOARDS_ERGODOX_CONFIG_H_
|
||||
|
||||
#define MOUSEKEY_DELAY 100
|
||||
#define MOUSEKEY_INTERVAL 20
|
||||
#define MOUSEKEY_MAX_SPEED 3
|
||||
#define MOUSEKEY_TIME_TO_MAX 10
|
||||
|
||||
#define TAPPING_TOGGLE 1
|
||||
|
||||
/* define if matrix has ghost */
|
||||
//#define MATRIX_HAS_GHOST
|
||||
|
||||
#define TAPPING_TERM 200
|
||||
#define IGNORE_MOD_TAP_INTERRUPT // this makes it possible to do rolling combos (zx) with keys that convert to other keys on hold (z becomes ctrl when you hold it, and when this option isn't enabled, z rapidly followed by x actually sends Ctrl-x. That's bad.)
|
||||
|
||||
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
|
||||
#define LOCKING_SUPPORT_ENABLE
|
||||
/* Locking resynchronize hack */
|
||||
#define LOCKING_RESYNC_ENABLE
|
||||
|
||||
/* key combination for command */
|
||||
#define IS_COMMAND() ( \
|
||||
keyboard_report->mods == (MOD_BIT(KC_LCTL) | MOD_BIT(KC_RCTL)) || \
|
||||
keyboard_report->mods == (MOD_BIT(KC_LSFT) | MOD_BIT(KC_RSFT)) \
|
||||
)
|
||||
|
||||
#ifdef SUBPROJECT_ez
|
||||
#include "ez/config.h"
|
||||
#endif
|
||||
#ifdef SUBPROJECT_infinity
|
||||
#include "infinity/config.h"
|
||||
#endif
|
||||
|
||||
|
||||
#endif /* KEYBOARDS_ERGODOX_CONFIG_H_ */
|
@ -0,0 +1,10 @@
|
||||
#ifndef KEYBOARDS_ERGODOX_ERGODOX_H_
|
||||
#define KEYBOARDS_ERGODOX_ERGODOX_H_
|
||||
#ifdef SUBPROJECT_ez
|
||||
#include "ez.h"
|
||||
#endif
|
||||
#ifdef SUBPROJECT_infinity
|
||||
#include "infinity.h"
|
||||
#endif
|
||||
|
||||
#endif /* KEYBOARDS_ERGODOX_ERGODOX_H_ */
|
@ -1,4 +1,4 @@
|
||||
#include "ergodox_ez.h"
|
||||
#include "ez.h"
|
||||
#include "i2cmaster.h"
|
||||
|
||||
bool i2c_initialized = 0;
|
@ -0,0 +1,110 @@
|
||||
#ifndef KEYBOARDS_ERGODOX_INFINITY_INFINITY_H_
|
||||
#define KEYBOARDS_ERGODOX_INFINITY_INFINITY_H_
|
||||
|
||||
#include "quantum.h"
|
||||
|
||||
void ergodox_board_led_on(void);
|
||||
void ergodox_right_led_1_on(void);
|
||||
void ergodox_right_led_2_on(void);
|
||||
void ergodox_right_led_3_on(void);
|
||||
void ergodox_right_led_on(uint8_t led);
|
||||
|
||||
void ergodox_board_led_off(void);
|
||||
void ergodox_right_led_1_off(void);
|
||||
void ergodox_right_led_2_off(void);
|
||||
void ergodox_right_led_3_off(void);
|
||||
void ergodox_right_led_off(uint8_t led);
|
||||
|
||||
inline void ergodox_led_all_on(void)
|
||||
{
|
||||
ergodox_board_led_on();
|
||||
ergodox_right_led_1_on();
|
||||
ergodox_right_led_2_on();
|
||||
ergodox_right_led_3_on();
|
||||
}
|
||||
|
||||
inline void ergodox_led_all_off(void)
|
||||
{
|
||||
ergodox_board_led_off();
|
||||
ergodox_right_led_1_off();
|
||||
ergodox_right_led_2_off();
|
||||
ergodox_right_led_3_off();
|
||||
}
|
||||
|
||||
inline void ergodox_right_led_1_set(uint8_t n){
|
||||
if (n) {
|
||||
ergodox_right_led_1_on();
|
||||
} else {
|
||||
ergodox_right_led_1_off();
|
||||
}
|
||||
}
|
||||
|
||||
inline void ergodox_right_led_2_set(uint8_t n){
|
||||
if (n) {
|
||||
ergodox_right_led_2_on();
|
||||
} else {
|
||||
ergodox_right_led_2_off();
|
||||
}
|
||||
}
|
||||
|
||||
inline void ergodox_right_led_3_set(uint8_t n){
|
||||
if (n) {
|
||||
ergodox_right_led_3_on();
|
||||
} else {
|
||||
ergodox_right_led_3_off();
|
||||
}
|
||||
}
|
||||
|
||||
inline void ergodox_right_led_set(uint8_t led, uint8_t n){
|
||||
if (n) {
|
||||
ergodox_right_led_on(led);
|
||||
} else {
|
||||
ergodox_right_led_off(led);
|
||||
}
|
||||
}
|
||||
|
||||
inline void ergodox_led_all_set(uint8_t n) {
|
||||
ergodox_right_led_1_set(n);
|
||||
ergodox_right_led_2_set(n);
|
||||
ergodox_right_led_3_set(n);
|
||||
}
|
||||
|
||||
#define KEYMAP( \
|
||||
A80, A70, A60, A50, A40, A30, A20, \
|
||||
A81, A71, A61, A51, A41, A31, A21, \
|
||||
A82, A72, A62, A52, A42, A32, \
|
||||
A83, A73, A63, A53, A43, A33, A23, \
|
||||
A84, A74, A64, A54, A44, \
|
||||
A13, A03, \
|
||||
A04, \
|
||||
A34, A24, A14, \
|
||||
B20, B30, B40, B50, B60, B70, B80, \
|
||||
B21, B31, B41, B51, B61, B71, B81, \
|
||||
B32, B42, B52, B62, B72, B82, \
|
||||
B23, B33, B43, B53, B63, B73, B83, \
|
||||
B44, B54, B64, B74, B84, \
|
||||
B03, B13, \
|
||||
B04, \
|
||||
B14, B24, B34 \
|
||||
) { \
|
||||
{ KC_NO, KC_NO, KC_NO, A03, A04 }, \
|
||||
{ KC_NO, KC_NO, KC_NO, A13, A14 }, \
|
||||
{ A20, A21, KC_NO, A23, A24 }, \
|
||||
{ A30, A31, A32, A33, A34 }, \
|
||||
{ A40, A41, A42, A43, A44 }, \
|
||||
{ A50, A51, A52, A53, A54 }, \
|
||||
{ A60, A61, A62, A63, A64 }, \
|
||||
{ A70, A71, A72, A73, A74 }, \
|
||||
{ A80, A81, A82, A83, A84 }, \
|
||||
{ KC_NO, KC_NO, KC_NO, B03, B04 }, \
|
||||
{ KC_NO, KC_NO, KC_NO, B13, B14 }, \
|
||||
{ B20, B21, KC_NO, B23, B24 }, \
|
||||
{ B30, B31, B32, B33, B34 }, \
|
||||
{ B40, B41, B42, B43, B44 }, \
|
||||
{ B50, B51, B52, B53, B54 }, \
|
||||
{ B60, B61, B62, B63, B64 }, \
|
||||
{ B70, B71, B72, B73, B74 }, \
|
||||
{ B80, B81, B82, B83, B84 } \
|
||||
}
|
||||
|
||||
#endif /* KEYBOARDS_ERGODOX_INFINITY_INFINITY_H_ */
|
Before Width: | Height: | Size: 79 KiB After Width: | Height: | Size: 79 KiB |
@ -1,4 +1,4 @@
|
||||
#include "ergodox_ez.h"
|
||||
#include "ergodox.h"
|
||||
#include "debug.h"
|
||||
#include "action_layer.h"
|
||||
|
@ -1,4 +1,4 @@
|
||||
#include "ergodox_ez.h"
|
||||
#include "ergodox.h"
|
||||
#include "debug.h"
|
||||
#include "action_layer.h"
|
||||
#include "keymap_german.h"
|
@ -1,4 +1,4 @@
|
||||
#include "ergodox_ez.h"
|
||||
#include "ergodox.h"
|
||||
#include "debug.h"
|
||||
#include "action_layer.h"
|
||||
|
Before Width: | Height: | Size: 814 KiB After Width: | Height: | Size: 814 KiB |
After Width: | Height: | Size: 93 KiB |
After Width: | Height: | Size: 93 KiB |
After Width: | Height: | Size: 135 KiB |
Before Width: | Height: | Size: 66 KiB After Width: | Height: | Size: 66 KiB |
Before Width: | Height: | Size: 93 KiB After Width: | Height: | Size: 93 KiB |
Before Width: | Height: | Size: 89 KiB After Width: | Height: | Size: 89 KiB |
Before Width: | Height: | Size: 68 KiB After Width: | Height: | Size: 68 KiB |
@ -0,0 +1,198 @@
|
||||
<!-- -*- mode: markdown; fill-column: 8192 -*- -->
|
||||
|
||||
algernon's layout
|
||||
=======================
|
||||
|
||||
This is an unconventional layout for the ErgoDox EZ. For more details about the history of the layout, see my [blog posts about my ErgoDox journey][blog-ergodox].
|
||||
|
||||
[blog-ergodox]: https://asylum.madhouse-project.org/blog/tags/ergodox/
|
||||
|
||||
Some of the things in the layout only work when one uses Spacemacs and GNOME under Linux. Your mileage may vary.
|
||||
|
||||
## Table of Contents
|
||||
|
||||
* [Layouts](#layouts)
|
||||
- [Base layer](#base-layer)
|
||||
- [ADORE layer](#adore-layer)
|
||||
- [Hungarian layer](#hungarian-layer)
|
||||
- [Navigation and media layer](#navigation-and-media-layer)
|
||||
- [One-handed layer](#one-handed-layer)
|
||||
- [Steno layer](#steno-layer)
|
||||
- [LED states](#led-states)
|
||||
* [Tools](#tools)
|
||||
- [Heatmap](#heatmap)
|
||||
* [Building](#building)
|
||||
- [Using on Windows](#using-on-windows)
|
||||
* [Changelog](#changelog)
|
||||
* [License](#license)
|
||||
|
||||
# Layouts
|
||||
|
||||
## Base layer
|
||||
|
||||
[![Base layer](images/base-layer.png)](http://www.keyboard-layout-editor.com/#/gists/28f7eb305fdbff943613e1dc7aa9e82b)
|
||||
|
||||
At its core, this is a Dvorak layout, with some minor changes. The more interesting parts are how certain keys behave:
|
||||
|
||||
* The keys on the number row double as function keys, when held for a bit longer than an usual tap. This allows me to use the function keys without having to switch layers.
|
||||
* The `Shift`, `Alt`, and `Control` modifiers are one-shot. When tapped, they are considered active for the next key press only. When double tapped, they toggle on, until a third, single tap sometime later. When held, they act as expected. My usual pattern is that I use these for the next keypress only, so this behaviour is perfect. If I need them held, I'll just double-tap.
|
||||
* The `GUI` key is special, because when I double-tap it, it sends `GUI + w`, which pops up an application selector. It also switches to a one-shot layer, where the number row on the left half turns into app selector macros, for the most common things I usually want to switch to. Otherwise it behaves as on a normal layout.
|
||||
* The `ESC` key also doubles as a one-shot cancel key: if tapped while any of the one-shot modifiers are in-flight (as in, single-tapped, and not expired yet), it cancels all one-shot modifiers. It also cancels the **Hun** layer, if active. Otherwise it sends the usual keycode.
|
||||
* The **Media** and **Hun** layer keys are one-shot, the **1Hand** and **STENO** keys are toggles.
|
||||
* When holding any of the **Arrow** layer keys, the arrow layer activates while the layer key is held. Tapping the key produces the normal key.
|
||||
* Tapping the `:` key once yields `:`, tapping it twice yields `;`.
|
||||
* The **Lead** key allows me to type in a sequence of keys, and trigger some actions:
|
||||
- `LEAD u` enters unicode input mode, by sending the GTK+ key sequence that does this.
|
||||
- `LEAD l` uses the unicode input method to enter a `λ`.
|
||||
- `LEAD s` does a lot of magic to type in a shruggie: `¯\_(ツ)_/¯`
|
||||
- `LEAD y` types `\o/`.
|
||||
- `LEAD w m` maximises the currently focused window.
|
||||
- `LEAD a` makes the [ADORE layer](#adore-layer) the default.
|
||||
- `LEAD v` prints the firmware version, the keyboard and the keymap.
|
||||
- `LEAD d` toggles logging keypress positions to the HID console.
|
||||
- `LEAD t` toggles time travel. Figuring out the current `date` is left as an exercise to the reader.
|
||||
|
||||
## ADORE layer
|
||||
|
||||
[![ADORE layer](images/adore-layer.png)](http://www.keyboard-layout-editor.com/#/gists/45681a17453d235925b6028dd83bf12a)
|
||||
|
||||
While using the standard Dvorak layout, I encountered a number of inconveniences, and on this layer, I am playing with ideas to make the layout feel better. Initially, it was based on [Capewell-Dvorak][cpd], but that too, had shortcomings I was not happy with. So now this is something inbetween, with own observations thrown in. How it works out in the long run remains to be seen.
|
||||
|
||||
[cpd]: http://www.michaelcapewell.com/projects/keyboard/layout_capewell-dvorak.htm
|
||||
|
||||
Based on a week and a half of typing, the keys were rearranged, and the home row neatly spelled out **ADORE**, that gave the layout its name.
|
||||
|
||||
## Hungarian layer
|
||||
|
||||
[![Hungarian layer](images/hun-layer.png)](http://www.keyboard-layout-editor.com/#/gists/b160f6ec90d58c127c114c89f66e9dc9)
|
||||
|
||||
On this layer, the accented characters are at the same position as their base variant. For some, which can have other diatribes, the long one is on top, short's on bottom. Tapping any of the accented characters takes us back to the base layer.
|
||||
|
||||
## Navigation and media layer
|
||||
|
||||
[![Navigation and media layer](images/nav-n-media-layer.png)](http://www.keyboard-layout-editor.com/#/gists/c59c453f9fe1a3238ba1494e7e5c6892)
|
||||
|
||||
This layer is primarily for navigating with the cursor or the mouse, and some media things.
|
||||
|
||||
## One-handed layer
|
||||
|
||||
[![One-handed layer](images/one-handed-layer.png)](http://www.keyboard-layout-editor.com/#/gists/edff2495135955b8963198dace7f7ece)
|
||||
|
||||
The one-handed layer is used in situations where the right hand is occupied, by mousing around, for example. Tapping the `OTHER` key switches which side is active. For the most part, keys remain in their usual position. When the right half is active, keys are mirrored to the left half.
|
||||
|
||||
The differences are as follows:
|
||||
|
||||
* The `ESC` key has been moved to the bottom row, so the `OTHER` key is easier to tap.
|
||||
* Most keys on the thumb cluster now have dual uses, and these do not change when switching sides:
|
||||
- The `Space`/`Backspace` key sends `Space` on tap, `Backspace` when held for longer than a normal tap.
|
||||
- The `Enter`/`Shift` key sends `Enter` on short-tap, `Shift` on long-tap.
|
||||
* The `Apps`/`BASE` key can be used to go back to the base layer, by long-tapping it. A short-tap will send the `App` key, as usual.
|
||||
|
||||
## Steno layer
|
||||
|
||||
[![Steno layer for Plover](images/steno-layer.png)](http://www.keyboard-layout-editor.com/#/gists/401ef9a84369e47c57f9aedcf0a0d667)
|
||||
|
||||
This is to be used with [Plover](http://www.openstenoproject.org/plover/), nothing really fancy here. The **STENO** key toggles the layer on and off, and sends the toggle command to Plover too.
|
||||
|
||||
## LED states
|
||||
|
||||
The primary purpose of the LEDs is to show the modifier status, a secondary, to show which layer is active. Each modifier, `Shift`, `Alt` and `Control` each have their designated LEDs: the *red*, *green* and *blue*, respectively. When a modifier is in a one-shot state, the respective LED will turn on with a dimmer light. If the modifier is toggled on, the brightness of the LED turns full.
|
||||
|
||||
For the layers, the following rules apply:
|
||||
|
||||
* When the [ADORE layer](#adore-layer) is toggled on, LEDs will light up from left to right in a sequence, then turn off. When the layer is toggled off, the LEDs light up and turn off in the other direction. No LEDs are on while the layer is active.
|
||||
* When the [Hungarian layer](#hungarian-layer) is active, the *green* and *blue* LEDs are on.
|
||||
* When the [Navigation and media layer](#navigation-and-media-layer) is active, the *red* and *green* ones are on.
|
||||
* When the [One-handed layer](#one-handed-layer) is active, the *green* LED is on and bright, and either the *red* or the *blue* one is going to slowly blink, depending on the currently active side.
|
||||
* For the [Steno layer](#steno-layer), all LEDs will be turned on.
|
||||
|
||||
Unless noted otherwise, the layers use a dim light for the LEDs, while modifiers use a stronger one, and modifiers override any layer preferences. For example, when on the one-handed layer, with the left side active (*red* light blinking), if `Shift` is on, the *red* light will be constantly on.
|
||||
|
||||
# Tools
|
||||
|
||||
## Heatmap
|
||||
|
||||
When the keypress logging functionality is enabled (by `LEAD d`), the keyboard will output a line every time a key is pressed, containing the position of the key in the matrix. This allows one to collect this information, and build analytics over it, such as a heat map, including dead keys too.
|
||||
|
||||
Included with the firmware is a small tool that can parse these logs, and create a heatmap that one can import into [KLE][kle]. To use it, simply point `tools/log-to-heatmap.py` to a base layout file (one is included in the `tools/` directory), and the key position log. The latter one can create by running `hid-listen`, and redirecting its output to a file.
|
||||
|
||||
[kle]: http://www.keyboard-layout-editor.com/
|
||||
|
||||
The generated heatmap looks somewhat like this:
|
||||
|
||||
![Heatmap](images/heatmap.png)
|
||||
|
||||
# Building
|
||||
|
||||
To make my workflow easier, this layout is maintained in [its own repository][algernon:ez-layout]. To build it, you will need the [QMK][qmk] firmware checked out, and this repo either checked out to something like `keyboards/ergodox_ez/algernon-master`. One way to achieve that is this:
|
||||
|
||||
[algernon:ez-layout]: https://github.com/algernon/ergodox-layout
|
||||
[qmk]: https://github.com/jackhumbert/qmk_firmware
|
||||
|
||||
```
|
||||
$ git clone https://github.com/jackhumbert/qmk_firmware.git
|
||||
$ cd qmk_firmware
|
||||
$ git clone https://github.com/algernon/ergodox-layout.git \
|
||||
keyboards/ergodox_ez/keymaps/algernon-master
|
||||
$ make KEYBOARD=ergodox_ez KEYMAP=algernon-master
|
||||
```
|
||||
|
||||
From time to time, updates may be submitted back to the QMK repository. If you are reading it there, you can build the firmware like any other firmware included with it (assuming you are in the root directory of the firmware):
|
||||
|
||||
```
|
||||
$ make KEYBOARD=ergodox_ez KEYMAP=algernon
|
||||
```
|
||||
|
||||
## Using on Windows
|
||||
|
||||
The keymap default to forcing NKRO, which seems to upset Windows, and except the modifiers, none of them work. If you experience this problem, recompile the firmware with `FORCE_NKRO=no` added to the `make` command line.
|
||||
|
||||
# Changelog
|
||||
|
||||
## v1.4 - 2016-07-29
|
||||
|
||||
* When toggling the key logging on or off, the LEDs will do a little dance.
|
||||
* The keylogger is now optional, but enabled by default. Use `KEYLOGGER_ENABLE=no` on the `make` command line to disable it.
|
||||
* The `TAB`/`ARRW` key was turned into a tap-dance key, allowing one to toggle the **ARROW** layer on by double-tapping, and as such, avoid the need to hold the key.
|
||||
* The `-`/`_` key was turned into a tap-dance key too.
|
||||
* There is now a way to travel time with the keyboard, toggle the feature on by hitting `LEAD t`.
|
||||
|
||||
## v1.3 - 2016-07-06
|
||||
|
||||
* Added support for logging keys, by pressing `LEAD d`. Also included is a tool to generate a [heatmap](#heatmap) out of the logs.
|
||||
* The arrow and navigation keys were rearranged again, and now require an additional key being held to activate. See the [base layer](#base-layer) for an image that shows where arrows are.
|
||||
* The **experimental** layer has been redone, and is now called [ADORE](#adore-layer), and as such, can be enabled by `LEAD a` now.
|
||||
* Switching between Dvorak and ADORE is now persisted into EEPROM, and survives a reboot.
|
||||
|
||||
## v1.2 - 2016-06-22
|
||||
|
||||
* The forced NKRO mode can be easily toggled off at compile-time, to make the firmware compatible with [certain operating systems](#using-on-windows).
|
||||
* The `:;` key has changed behaviour: to access the `;` symbol, the key needs to be double-tapped, instead of shifted.
|
||||
* The `=` and `\` keys were swapped, `=` moved to the home row, on both the [base](#base-layer) and the **experimental** layers.
|
||||
* The arrow and navigation keys were redone, they are now more accessible, but the navigation keys require an extra tap to access.
|
||||
* The **Emacs** layer is gone, replaced by a simplified [navigation and media](#navigation-and-media-layer) layer.
|
||||
* `LEAD v` types the firmware version, and the keymap version.
|
||||
* On the **experimental** layer, the `L` and `Q`, and the `K` and `G` keys were swapped.
|
||||
* The [Steno](#steno-layer) layer gained a few more `#` and `*` keys, to make it easier on my fingers.
|
||||
|
||||
## v1.1 - 2016-06-14
|
||||
|
||||
* The keyboard starts in NKRO mode, bootmagic and other things are disabled.
|
||||
* A [Steno](#steno-layer) layer was added, to be used with Plover.
|
||||
* An **experimental** layer was added, something halfway between Dvorak and Capewell-Dvorak. A work in progress.
|
||||
* `LEAD y` types `\o/`.
|
||||
* Some keys on the [Base](#base-layer) layer have been moved around:
|
||||
- `?` moved to the left pinky, left of `Q`.
|
||||
- `=` shifted one row down, but `F11` stayed where it was.
|
||||
- `-` on the left half was replaced by `Tab`.
|
||||
- `Tab`'s original position is taken by a `Media Next`/`Media Prev` key.
|
||||
- `:` now inputs `;` when shifted.
|
||||
* `ESC` cancels the [Hungarian](#hungarian-layer) layer too, not just modifiers.
|
||||
|
||||
## v1.0 - 2016-05-26
|
||||
|
||||
Initial version.
|
||||
|
||||
# License
|
||||
|
||||
The layout, being a derivative of the original TMK firmware which is under the GPL-2+, this layout is under the GPL as well, but GPL-3+, rather than the older version.
|
@ -0,0 +1,533 @@
|
||||
[
|
||||
{
|
||||
"backcolor": "#ffffff",
|
||||
"name": "ErgoDox - algernon's layout: Heatmap",
|
||||
"author": "Gergely Nagy <kbd@gergo.csillger.hu>",
|
||||
"notes": "See [here](https://github.com/algernon/ergodox-layout#readme) for the QMK keymap source.",
|
||||
"switchMount": "cherry",
|
||||
"switchBrand": "gateron",
|
||||
"switchType": "KS-3-Tea",
|
||||
"pcb": true,
|
||||
"css": ".keyborder { -webkit-filter: blur(5px); filter: blur(5px); } .keytop { -webkit-filter: blur(10px); } .keylabels { border: 1px solid black; }"
|
||||
},
|
||||
[
|
||||
{
|
||||
"x": 3.5,
|
||||
"c": "#a7d0db",
|
||||
"fa": [
|
||||
0,
|
||||
0,
|
||||
2
|
||||
]
|
||||
},
|
||||
"#\n3\nF3",
|
||||
{
|
||||
"x": 10.5,
|
||||
"c": "#a7d0db",
|
||||
"t": "#000000",
|
||||
"a": 4,
|
||||
"fa": [
|
||||
0,
|
||||
0,
|
||||
2
|
||||
]
|
||||
},
|
||||
"*\n8\nF8"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 2.5,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"@\n2\nF2",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000"
|
||||
},
|
||||
"$\n4\nF4",
|
||||
{
|
||||
"x": 8.5
|
||||
},
|
||||
"&\n7\nF7",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"(\n9\nF9"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 5.5,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000"
|
||||
},
|
||||
"%\n5\nF5",
|
||||
{
|
||||
"c": "#f9cd31",
|
||||
"a": 7,
|
||||
"f": 2
|
||||
},
|
||||
"STENO",
|
||||
{
|
||||
"x": 4.5,
|
||||
"f": 6
|
||||
},
|
||||
"<i class='mss mss-Unicode-Option-3'></i>",
|
||||
{
|
||||
"c": "#7adabd",
|
||||
"a": 4,
|
||||
"f": 3,
|
||||
"fa": [
|
||||
0,
|
||||
0,
|
||||
2
|
||||
]
|
||||
},
|
||||
"^\n6\nF6"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"c": "#ffb2d2",
|
||||
"f": 3,
|
||||
"w": 1.5
|
||||
},
|
||||
"\n\n~\n`",
|
||||
{
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"!\n1\nF1",
|
||||
{
|
||||
"x": 14.5
|
||||
},
|
||||
")\n0\nF10",
|
||||
{
|
||||
"a": 7,
|
||||
"w": 1.5
|
||||
},
|
||||
"F11"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.375,
|
||||
"x": 3.5,
|
||||
"c": "#a7d0db",
|
||||
"t": "#000000",
|
||||
"a": 6
|
||||
},
|
||||
"L",
|
||||
{
|
||||
"x": 10.5
|
||||
},
|
||||
"C"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 2.5,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b",
|
||||
"a": 4
|
||||
},
|
||||
">\n.",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000",
|
||||
"a": 6
|
||||
},
|
||||
"W",
|
||||
{
|
||||
"x": 8.5
|
||||
},
|
||||
"H",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"P"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 5.5,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000"
|
||||
},
|
||||
"M",
|
||||
{
|
||||
"c": "#93c9b7",
|
||||
"a": 4,
|
||||
"h": 1.5
|
||||
},
|
||||
"{\n[",
|
||||
{
|
||||
"x": 4.5,
|
||||
"h": 1.5
|
||||
},
|
||||
"}\n]",
|
||||
{
|
||||
"c": "#7adabd",
|
||||
"a": 6
|
||||
},
|
||||
"F"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"c": "#ffb07b",
|
||||
"t": "#0d0d0b",
|
||||
"f": 6,
|
||||
"w": 1.5
|
||||
},
|
||||
"<i class='fa fa-fast-backward'></i>\n\n<i class='fa fa-fast-forward'></i>",
|
||||
{
|
||||
"c": "#ffb2d2",
|
||||
"a": 4,
|
||||
"f": 3
|
||||
},
|
||||
"<\n,",
|
||||
{
|
||||
"x": 14.5,
|
||||
"a": 6
|
||||
},
|
||||
"Y",
|
||||
{
|
||||
"a": 4,
|
||||
"w": 1.5
|
||||
},
|
||||
"|\n\\"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.375,
|
||||
"x": 3.5,
|
||||
"c": "#a7d0db",
|
||||
"t": "#000000",
|
||||
"a": 6
|
||||
},
|
||||
"E",
|
||||
{
|
||||
"x": 10.5
|
||||
},
|
||||
"T"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 2.5,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"O",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000",
|
||||
"n": true
|
||||
},
|
||||
"I",
|
||||
{
|
||||
"x": 8.5,
|
||||
"n": true
|
||||
},
|
||||
"R",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"N"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 5.5,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000"
|
||||
},
|
||||
"U",
|
||||
{
|
||||
"x": 6.5
|
||||
},
|
||||
"D"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"c": "#ffb2d2",
|
||||
"t": "#0d0d0b",
|
||||
"fa": [
|
||||
6
|
||||
],
|
||||
"w": 1.5
|
||||
},
|
||||
"<i class='fa fa-arrows'></i>\n\nTab",
|
||||
{
|
||||
"f": 3
|
||||
},
|
||||
"A",
|
||||
{
|
||||
"x": 14.5,
|
||||
"f": 3
|
||||
},
|
||||
"S",
|
||||
{
|
||||
"a": 4,
|
||||
"fa": [
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
6
|
||||
],
|
||||
"w": 1.5
|
||||
},
|
||||
"+\n="
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.625,
|
||||
"x": 6.5,
|
||||
"c": "#93c9b7",
|
||||
"t": "#000000",
|
||||
"a": 7,
|
||||
"h": 1.5
|
||||
},
|
||||
"(",
|
||||
{
|
||||
"x": 4.5,
|
||||
"h": 1.5
|
||||
},
|
||||
")"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.75,
|
||||
"x": 3.5,
|
||||
"c": "#a7d0db",
|
||||
"a": 4,
|
||||
"f": 3
|
||||
},
|
||||
"\"\n'",
|
||||
{
|
||||
"x": 10.5
|
||||
},
|
||||
"V"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 2.5,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"Z",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000"
|
||||
},
|
||||
"K",
|
||||
{
|
||||
"x": 8.5
|
||||
},
|
||||
"G",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"J"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 5.5,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000"
|
||||
},
|
||||
"X",
|
||||
{
|
||||
"x": 6.5
|
||||
},
|
||||
"B"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"c": "#ffb07b",
|
||||
"f": 9,
|
||||
"w": 1.5
|
||||
},
|
||||
"\n\n<i class='kb kb-Multimedia-Play-Pause'></i>",
|
||||
{
|
||||
"c": "#ffb2d2",
|
||||
"t": "#0d0d0b",
|
||||
"a": 4,
|
||||
"f": 3
|
||||
},
|
||||
"?\n/",
|
||||
{
|
||||
"x": 14.5,
|
||||
"a": 6
|
||||
},
|
||||
"Q",
|
||||
{
|
||||
"c": "#ffb07b",
|
||||
"t": "#000000",
|
||||
"f": 9,
|
||||
"w": 1.5
|
||||
},
|
||||
"<i class='kb kb-Multimedia-Stop'></i>"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.375,
|
||||
"x": 3.5,
|
||||
"c": "#d9dae0",
|
||||
"g": true,
|
||||
"a": 7,
|
||||
"f": 3
|
||||
},
|
||||
"",
|
||||
{
|
||||
"x": 10.5
|
||||
},
|
||||
""
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 2.5
|
||||
},
|
||||
"",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#d4872a",
|
||||
"g": false,
|
||||
"a": 5
|
||||
},
|
||||
";\n:",
|
||||
{
|
||||
"x": 8.5
|
||||
},
|
||||
"_\n-",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#d9dae0",
|
||||
"g": true,
|
||||
"a": 7
|
||||
},
|
||||
""
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.75,
|
||||
"x": 0.5
|
||||
},
|
||||
"",
|
||||
{},
|
||||
"",
|
||||
{
|
||||
"x": 14.5
|
||||
},
|
||||
"",
|
||||
{},
|
||||
""
|
||||
],
|
||||
[
|
||||
{
|
||||
"r": 30,
|
||||
"rx": 6.5,
|
||||
"ry": 4.25,
|
||||
"y": -1,
|
||||
"x": 1,
|
||||
"c": "#f9cd31",
|
||||
"g": false
|
||||
},
|
||||
"Alt",
|
||||
{
|
||||
"a": 4,
|
||||
"fa": [
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
9
|
||||
]
|
||||
},
|
||||
"\n\n\n<i class='kb kb-logo-linux-debian fa-large'></i>"
|
||||
],
|
||||
[
|
||||
{
|
||||
"c": "#d4872a",
|
||||
"a": 7,
|
||||
"f": 9,
|
||||
"h": 2
|
||||
},
|
||||
"<i class='kb kb-Unicode-BackSpace-DeleteLeft-Big'></i>",
|
||||
{
|
||||
"h": 2
|
||||
},
|
||||
"<i class='fa fa-angle-double-up'></i>",
|
||||
{
|
||||
"c": "#f9cd31",
|
||||
"f": 3
|
||||
},
|
||||
"Ctrl"
|
||||
],
|
||||
[
|
||||
{
|
||||
"x": 2,
|
||||
"c": "#e26757"
|
||||
},
|
||||
"ESC"
|
||||
],
|
||||
[
|
||||
{
|
||||
"r": -30,
|
||||
"rx": 13,
|
||||
"y": -1,
|
||||
"x": -3,
|
||||
"c": "#f9cd31",
|
||||
"f": 2
|
||||
},
|
||||
"MEDIA",
|
||||
{},
|
||||
"1HAND"
|
||||
],
|
||||
[
|
||||
{
|
||||
"x": -3
|
||||
},
|
||||
"LEAD",
|
||||
{
|
||||
"c": "#d4872a",
|
||||
"f": 9,
|
||||
"h": 2
|
||||
},
|
||||
"<i class='kb kb-Return-2'></i>",
|
||||
{
|
||||
"f": 3,
|
||||
"h": 2
|
||||
},
|
||||
"SPC"
|
||||
],
|
||||
[
|
||||
{
|
||||
"x": -3,
|
||||
"c": "#f9cd31",
|
||||
"f": 2
|
||||
},
|
||||
"HUN"
|
||||
]
|
||||
]
|
@ -0,0 +1,533 @@
|
||||
[
|
||||
{
|
||||
"backcolor": "#ffffff",
|
||||
"name": "ErgoDox - algernon's layout: Heatmap",
|
||||
"author": "Gergely Nagy <kbd@gergo.csillger.hu>",
|
||||
"notes": "See [here](https://github.com/algernon/ergodox-layout#readme) for the QMK keymap source.",
|
||||
"switchMount": "cherry",
|
||||
"switchBrand": "gateron",
|
||||
"switchType": "KS-3-Tea",
|
||||
"pcb": true,
|
||||
"css": ".keyborder { -webkit-filter: blur(5px); filter: blur(5px); } .keytop { -webkit-filter: blur(10px); } .keylabels { border: 1px solid black; }"
|
||||
},
|
||||
[
|
||||
{
|
||||
"x": 3.5,
|
||||
"c": "#a7d0db",
|
||||
"fa": [
|
||||
0,
|
||||
0,
|
||||
2
|
||||
]
|
||||
},
|
||||
"#\n3\nF3",
|
||||
{
|
||||
"x": 10.5,
|
||||
"c": "#a7d0db",
|
||||
"t": "#000000",
|
||||
"a": 4,
|
||||
"fa": [
|
||||
0,
|
||||
0,
|
||||
2
|
||||
]
|
||||
},
|
||||
"*\n8\nF8"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 2.5,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"@\n2\nF2",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000"
|
||||
},
|
||||
"$\n4\nF4",
|
||||
{
|
||||
"x": 8.5
|
||||
},
|
||||
"&\n7\nF7",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"(\n9\nF9"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 5.5,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000"
|
||||
},
|
||||
"%\n5\nF5",
|
||||
{
|
||||
"c": "#f9cd31",
|
||||
"a": 7,
|
||||
"f": 2
|
||||
},
|
||||
"STENO",
|
||||
{
|
||||
"x": 4.5,
|
||||
"f": 6
|
||||
},
|
||||
"<i class='mss mss-Unicode-Option-3'></i>",
|
||||
{
|
||||
"c": "#7adabd",
|
||||
"a": 4,
|
||||
"f": 3,
|
||||
"fa": [
|
||||
0,
|
||||
0,
|
||||
2
|
||||
]
|
||||
},
|
||||
"^\n6\nF6"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"c": "#ffb2d2",
|
||||
"f": 3,
|
||||
"w": 1.5
|
||||
},
|
||||
"\n\n~\n`",
|
||||
{
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"!\n1\nF1",
|
||||
{
|
||||
"x": 14.5
|
||||
},
|
||||
")\n0\nF10",
|
||||
{
|
||||
"a": 7,
|
||||
"w": 1.5
|
||||
},
|
||||
"F11"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.375,
|
||||
"x": 3.5,
|
||||
"c": "#a7d0db",
|
||||
"t": "#000000",
|
||||
"a": 4
|
||||
},
|
||||
">\n.",
|
||||
{
|
||||
"x": 10.5,
|
||||
"a": 6
|
||||
},
|
||||
"C"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 2.5,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b",
|
||||
"a": 4
|
||||
},
|
||||
"<\n,",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000",
|
||||
"a": 6
|
||||
},
|
||||
"P",
|
||||
{
|
||||
"x": 8.5
|
||||
},
|
||||
"G",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"R"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 5.5,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000"
|
||||
},
|
||||
"Y",
|
||||
{
|
||||
"c": "#93c9b7",
|
||||
"a": 4,
|
||||
"h": 1.5
|
||||
},
|
||||
"{\n[",
|
||||
{
|
||||
"x": 4.5,
|
||||
"h": 1.5
|
||||
},
|
||||
"}\n]",
|
||||
{
|
||||
"c": "#7adabd",
|
||||
"a": 6
|
||||
},
|
||||
"F"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"c": "#ffb07b",
|
||||
"t": "#0d0d0b",
|
||||
"f": 6,
|
||||
"w": 1.5
|
||||
},
|
||||
"<i class='fa fa-fast-backward'></i>\n\n<i class='fa fa-fast-forward'></i>",
|
||||
{
|
||||
"c": "#ffb2d2",
|
||||
"a": 4,
|
||||
"f": 3
|
||||
},
|
||||
"\"\n'",
|
||||
{
|
||||
"x": 14.5,
|
||||
"a": 6
|
||||
},
|
||||
"L",
|
||||
{
|
||||
"a": 4,
|
||||
"w": 1.5
|
||||
},
|
||||
"|\n\\"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.375,
|
||||
"x": 3.5,
|
||||
"c": "#a7d0db",
|
||||
"t": "#000000",
|
||||
"a": 6
|
||||
},
|
||||
"E",
|
||||
{
|
||||
"x": 10.5
|
||||
},
|
||||
"T"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 2.5,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"O",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000",
|
||||
"n": true
|
||||
},
|
||||
"U",
|
||||
{
|
||||
"x": 8.5,
|
||||
"n": true
|
||||
},
|
||||
"H",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"N"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 5.5,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000"
|
||||
},
|
||||
"I",
|
||||
{
|
||||
"x": 6.5
|
||||
},
|
||||
"D"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"c": "#ffb2d2",
|
||||
"t": "#0d0d0b",
|
||||
"fa": [
|
||||
6
|
||||
],
|
||||
"w": 1.5
|
||||
},
|
||||
"<i class='fa fa-arrows'></i>\n\nTab",
|
||||
{
|
||||
"f": 3
|
||||
},
|
||||
"A",
|
||||
{
|
||||
"x": 14.5,
|
||||
"f": 3
|
||||
},
|
||||
"S",
|
||||
{
|
||||
"a": 4,
|
||||
"fa": [
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
6
|
||||
],
|
||||
"w": 1.5
|
||||
},
|
||||
"+\n="
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.625,
|
||||
"x": 6.5,
|
||||
"c": "#93c9b7",
|
||||
"t": "#000000",
|
||||
"a": 7,
|
||||
"h": 1.5
|
||||
},
|
||||
"(",
|
||||
{
|
||||
"x": 4.5,
|
||||
"h": 1.5
|
||||
},
|
||||
")"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.75,
|
||||
"x": 3.5,
|
||||
"c": "#a7d0db",
|
||||
"a": 6
|
||||
},
|
||||
"J",
|
||||
{
|
||||
"x": 10.5
|
||||
},
|
||||
"W"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 2.5,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"Q",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000"
|
||||
},
|
||||
"K",
|
||||
{
|
||||
"x": 8.5
|
||||
},
|
||||
"M",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#bfbad1",
|
||||
"t": "#0d0d0b"
|
||||
},
|
||||
"V"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 5.5,
|
||||
"c": "#7adabd",
|
||||
"t": "#000000"
|
||||
},
|
||||
"X",
|
||||
{
|
||||
"x": 6.5
|
||||
},
|
||||
"B"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"c": "#ffb07b",
|
||||
"f": 9,
|
||||
"w": 1.5
|
||||
},
|
||||
"\n\n<i class='kb kb-Multimedia-Play-Pause'></i>",
|
||||
{
|
||||
"c": "#ffb2d2",
|
||||
"t": "#0d0d0b",
|
||||
"a": 4,
|
||||
"f": 3
|
||||
},
|
||||
"?\n/",
|
||||
{
|
||||
"x": 14.5,
|
||||
"a": 6
|
||||
},
|
||||
"Z",
|
||||
{
|
||||
"c": "#ffb07b",
|
||||
"t": "#000000",
|
||||
"f": 9,
|
||||
"w": 1.5
|
||||
},
|
||||
"<i class='kb kb-Multimedia-Stop'></i>"
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.375,
|
||||
"x": 3.5,
|
||||
"c": "#d9dae0",
|
||||
"g": true,
|
||||
"a": 7,
|
||||
"f": 3
|
||||
},
|
||||
"",
|
||||
{
|
||||
"x": 10.5
|
||||
},
|
||||
""
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.875,
|
||||
"x": 2.5
|
||||
},
|
||||
"",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#d4872a",
|
||||
"g": false,
|
||||
"a": 5
|
||||
},
|
||||
";\n:",
|
||||
{
|
||||
"x": 8.5
|
||||
},
|
||||
"_\n-",
|
||||
{
|
||||
"x": 1,
|
||||
"c": "#d9dae0",
|
||||
"g": true,
|
||||
"a": 7
|
||||
},
|
||||
""
|
||||
],
|
||||
[
|
||||
{
|
||||
"y": -0.75,
|
||||
"x": 0.5
|
||||
},
|
||||
"",
|
||||
{},
|
||||
"",
|
||||
{
|
||||
"x": 14.5
|
||||
},
|
||||
"",
|
||||
{},
|
||||
""
|
||||
],
|
||||
[
|
||||
{
|
||||
"r": 30,
|
||||
"rx": 6.5,
|
||||
"ry": 4.25,
|
||||
"y": -1,
|
||||
"x": 1,
|
||||
"c": "#f9cd31",
|
||||
"g": false
|
||||
},
|
||||
"Alt",
|
||||
{
|
||||
"a": 4,
|
||||
"fa": [
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
9
|
||||
]
|
||||
},
|
||||
"\n\n\n<i class='kb kb-logo-linux-debian fa-large'></i>"
|
||||
],
|
||||
[
|
||||
{
|
||||
"c": "#d4872a",
|
||||
"a": 7,
|
||||
"f": 9,
|
||||
"h": 2
|
||||
},
|
||||
"<i class='kb kb-Unicode-BackSpace-DeleteLeft-Big'></i>",
|
||||
{
|
||||
"h": 2
|
||||
},
|
||||
"<i class='fa fa-angle-double-up'></i>",
|
||||
{
|
||||
"c": "#f9cd31",
|
||||
"f": 3
|
||||
},
|
||||
"Ctrl"
|
||||
],
|
||||
[
|
||||
{
|
||||
"x": 2,
|
||||
"c": "#e26757"
|
||||
},
|
||||
"ESC"
|
||||
],
|
||||
[
|
||||
{
|
||||
"r": -30,
|
||||
"rx": 13,
|
||||
"y": -1,
|
||||
"x": -3,
|
||||
"c": "#f9cd31",
|
||||
"f": 2
|
||||
},
|
||||
"MEDIA",
|
||||
{},
|
||||
"1HAND"
|
||||
],
|
||||
[
|
||||
{
|
||||
"x": -3
|
||||
},
|
||||
"LEAD",
|
||||
{
|
||||
"c": "#d4872a",
|
||||
"f": 9,
|
||||
"h": 2
|
||||
},
|
||||
"<i class='kb kb-Return-2'></i>",
|
||||
{
|
||||
"f": 3,
|
||||
"h": 2
|
||||
},
|
||||
"SPC"
|
||||
],
|
||||
[
|
||||
{
|
||||
"x": -3,
|
||||
"c": "#f9cd31",
|
||||
"f": 2
|
||||
},
|
||||
"HUN"
|
||||
]
|
||||
]
|
@ -0,0 +1,145 @@
|
||||
#! /usr/bin/env python
|
||||
import json
|
||||
import os
|
||||
import sys
|
||||
import re
|
||||
|
||||
from math import floor
|
||||
|
||||
cr_coord_map = [
|
||||
[
|
||||
# Row 0
|
||||
[ 4, 0], [ 4, 2], [ 2, 0], [ 1, 0], [ 2, 2], [ 3, 0], [ 3, 2],
|
||||
[ 3, 4], [ 3, 6], [ 2, 4], [ 1, 2], [ 2, 6], [ 4, 4], [ 4, 6],
|
||||
],
|
||||
[
|
||||
# Row 1
|
||||
[ 8, 0], [ 8, 2], [ 6, 0], [ 5, 0], [ 6, 2], [ 7, 0], [ 7, 2],
|
||||
[ 7, 4], [ 7, 6], [ 6, 4], [ 5, 2], [ 6, 6], [ 8, 4], [ 8, 6],
|
||||
],
|
||||
[
|
||||
# Row 2
|
||||
[12, 0], [12, 2], [10, 0], [ 9, 0], [10, 2], [11, 0], [ ],
|
||||
[ ], [11, 2], [10, 4], [ 9, 2], [10, 6], [12, 4], [12, 6],
|
||||
],
|
||||
[
|
||||
# Row 3
|
||||
[17, 0], [17, 2], [15, 0], [14, 0], [15, 2], [16, 0], [13, 0],
|
||||
[13, 2], [16, 2], [15, 4], [14, 2], [15, 6], [17, 4], [17, 6],
|
||||
],
|
||||
[
|
||||
# Row 4
|
||||
[20, 0], [20, 2], [19, 0], [18, 0], [19, 2], [], [], [], [],
|
||||
[19, 4], [18, 2], [19, 6], [20, 4], [20, 6],
|
||||
],
|
||||
[
|
||||
# Row 5
|
||||
[ ], [23, 0], [22, 2], [22, 0], [22, 4], [21, 0], [21, 2],
|
||||
[24, 0], [24, 2], [25, 0], [25, 4], [25, 2], [26, 0], [ ],
|
||||
],
|
||||
]
|
||||
|
||||
def set_attr_at(j, b, n, attr, fn, val):
|
||||
blk = j[b][n]
|
||||
if attr in blk:
|
||||
blk[attr] = fn(blk[attr], val)
|
||||
else:
|
||||
blk[attr] = fn(None, val)
|
||||
|
||||
def coord(col, row):
|
||||
return cr_coord_map[row][col]
|
||||
|
||||
def set_attr(orig, new):
|
||||
return new
|
||||
|
||||
def set_bg(j, (b, n), color):
|
||||
set_attr_at(j, b, n, "c", set_attr, color)
|
||||
#set_attr_at(j, b, n, "g", set_attr, False)
|
||||
|
||||
def _set_tap_info(o, count, cap):
|
||||
ns = 4 - o.count ("\n")
|
||||
return o + "\n" * ns + "%.02f%%" % (float(count) / float(cap) * 100)
|
||||
|
||||
def set_tap_info(j, (b, n), count, cap):
|
||||
j[b][n + 1] = _set_tap_info (j[b][n + 1], count, cap)
|
||||
|
||||
def heatmap_color (v):
|
||||
colors = [ [0.3, 0.3, 1], [0.3, 1, 0.3], [1, 1, 0.3], [1, 0.3, 0.3]]
|
||||
fb = 0
|
||||
if v <= 0:
|
||||
idx1, idx2 = 0, 0
|
||||
elif v >= 1:
|
||||
idx1, idx2 = len(colors) - 1, len(colors) - 1
|
||||
else:
|
||||
val = v * (len(colors) - 1)
|
||||
idx1 = int(floor(val))
|
||||
idx2 = idx1 + 1
|
||||
fb = val - float(idx1)
|
||||
|
||||
r = (colors[idx2][0] - colors[idx1][0]) * fb + colors[idx1][0]
|
||||
g = (colors[idx2][1] - colors[idx1][1]) * fb + colors[idx1][1]
|
||||
b = (colors[idx2][2] - colors[idx1][2]) * fb + colors[idx1][2]
|
||||
|
||||
r, g, b = [x * 255 for x in r, g, b]
|
||||
return "#%02x%02x%02x" % (r, g, b)
|
||||
|
||||
# Load the keylog
|
||||
def load_keylog(fname, restrict_row):
|
||||
keylog = {}
|
||||
total = 0
|
||||
with open(fname, "r") as f:
|
||||
lines = f.readlines()
|
||||
for line in lines:
|
||||
m = re.search ('KL: col=(\d+), row=(\d+)', line)
|
||||
if not m:
|
||||
continue
|
||||
(c, r) = (int(m.group (2)), int(m.group (1)))
|
||||
if restrict_row != None and r != int(restrict_row):
|
||||
continue
|
||||
if (c, r) in keylog:
|
||||
keylog[(c, r)] = keylog[(c, r)] + 1
|
||||
else:
|
||||
keylog[(c, r)] = 1
|
||||
total = total + 1
|
||||
return total / 2, keylog
|
||||
|
||||
def l_flat(s):
|
||||
f = s.split("\n")
|
||||
return ", ".join (f)
|
||||
|
||||
def main(base_fn, log_fn, restrict_row = None):
|
||||
|
||||
with open(base_fn, "r") as f:
|
||||
layout = json.load (f)
|
||||
|
||||
## Reset colors
|
||||
for row in cr_coord_map:
|
||||
for col in row:
|
||||
if col != []:
|
||||
set_bg (layout, col, "#d9dae0")
|
||||
#set_attr_at (layout, col[0], col[1], "g", set_attr, True)
|
||||
|
||||
total, log = load_keylog (log_fn, restrict_row)
|
||||
max_cnt = 0
|
||||
for (c, r) in log:
|
||||
max_cnt = max(max_cnt, log[(c, r)])
|
||||
|
||||
# Create the heatmap
|
||||
for (c, r) in log:
|
||||
coords = coord(c, r)
|
||||
b, n = coords
|
||||
cap = max_cnt
|
||||
v = float(log[(c, r)]) / cap
|
||||
print >> sys.stderr, "%s => %d/%d => %f = %s" % (l_flat(layout[b][n+1]), log[(c,r)], cap, v, heatmap_color(v))
|
||||
set_bg (layout, coord(c, r), heatmap_color (v))
|
||||
set_tap_info (layout, coord (c, r), log[(c, r)], total)
|
||||
|
||||
print json.dumps(layout)
|
||||
|
||||
if __name__ == "__main__":
|
||||
if len(sys.argv) < 3:
|
||||
print """Log to Heatmap -- creates a heatmap out of keyboard logs
|
||||
|
||||
Usage: log-to-heatmap.py base-layout.json logfile [row] >layout.json"""
|
||||
sys.exit (1)
|
||||
main(*sys.argv[1:])
|
@ -1,7 +1,7 @@
|
||||
// Netable differences vs. the default firmware for the ErgoDox EZ:
|
||||
// 1. The Cmd key is now on the right side, making Cmd+Space easier.
|
||||
// 2. The media keys work on OSX (But not on Windows).
|
||||
#include "ergodox_ez.h"
|
||||
#include "ergodox.h"
|
||||
#include "debug.h"
|
||||
#include "action_layer.h"
|
||||
|
Before Width: | Height: | Size: 78 KiB After Width: | Height: | Size: 78 KiB |
@ -1,4 +1,4 @@
|
||||
#include "ergodox_ez.h"
|
||||
#include "ergodox.h"
|
||||
#include "debug.h"
|
||||
#include "action_layer.h"
|
||||
#include "keymap_bepo.h"
|
@ -0,0 +1,2 @@
|
||||
SLEEP_LED_ENABLE = no
|
||||
UNICODE_ENABLE = yes
|
@ -1,4 +1,4 @@
|
||||
#include "ergodox_ez.h"
|
||||
#include "ergodox.h"
|
||||
#include "debug.h"
|
||||
#include "action_layer.h"
|
||||
|
Before Width: | Height: | Size: 101 KiB After Width: | Height: | Size: 101 KiB |
Before Width: | Height: | Size: 95 KiB After Width: | Height: | Size: 95 KiB |
Before Width: | Height: | Size: 379 KiB After Width: | Height: | Size: 379 KiB |
@ -1,4 +1,4 @@
|
||||
#include "ergodox_ez.h"
|
||||
#include "ergodox.h"
|
||||
#include "debug.h"
|
||||
#include "action_layer.h"
|
||||
|
@ -1,4 +1,4 @@
|
||||
#include "ergodox_ez.h"
|
||||
#include "ergodox.h"
|
||||
#include "debug.h"
|
||||
#include "action_layer.h"
|
||||
|
Before Width: | Height: | Size: 189 KiB After Width: | Height: | Size: 189 KiB |
Before Width: | Height: | Size: 1.4 MiB After Width: | Height: | Size: 1.4 MiB |
@ -1,6 +1,7 @@
|
||||
#include "ergodox_ez.h"
|
||||
#include "ergodox.h"
|
||||
#include "debug.h"
|
||||
#include "action_layer.h"
|
||||
#include "version.h"
|
||||
|
||||
#define BASE 0 // default layer
|
||||
#define SYMB 1 // symbols
|
Before Width: | Height: | Size: 754 KiB After Width: | Height: | Size: 754 KiB |