Refactor and Configurator updates for 9key (#3024)

master
noroadsleft 2018-05-22 15:58:56 -07:00 committed by Drashna Jaelre
parent c29d8ffd5a
commit c465cf2fd3
3 changed files with 16 additions and 4 deletions

View File

@ -3,7 +3,7 @@
#include "quantum.h"
#define KEYMAP( \
#define LAYOUT( \
k00, k01, k02, \
k10, k11, k12, \
k20, k21, k22 \

View File

@ -0,0 +1,12 @@
{
"keyboard_name": "9key",
"url": "",
"maintainer": "qmk",
"width": 3,
"height": 3,
"layouts": {
"LAYOUT": {
"layout": [{"label":"k00", "x":0, "y":0}, {"label":"k01", "x":1, "y":0}, {"label":"k02", "x":2, "y":0}, {"label":"k10", "x":0, "y":1}, {"label":"k11", "x":1, "y":1}, {"label":"k12", "x":2, "y":1}, {"label":"k20", "x":0, "y":2}, {"label":"k21", "x":1, "y":2}, {"label":"k22", "x":2, "y":2}]
}
}
}

View File

@ -1,4 +1,4 @@
#include "9key.h"
#include QMK_KEYBOARD_H
// Tap Dance Declarations
enum {
@ -22,7 +22,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | 7/0 | 8 | 9/FN | 7/0 = Dbl Tap 7 for 0 - 9/FN = Hold 9 for FN
* `-----------------------'
*/
[0] = KEYMAP( \
[0] = LAYOUT( \
KC_1, KC_2, KC_3, \
KC_4, TD(ENT_5), KC_6, \
TD(ZERO_7), KC_8, LT(1, KC_9) \
@ -37,7 +37,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | 00 | . | |
* `-----------------------'
*/
[1] = KEYMAP( \
[1] = LAYOUT( \
KC_ESC, KC_PLUS, KC_MINS, \
KC_BSPC, KC_ASTR, KC_SLSH, \
M(DBL_0), KC_DOT, KC_TRNS \