summaryrefslogtreecommitdiffstats
path: root/keyboards/jj40/keymaps
diff options
context:
space:
mode:
authorAlex Ong <the.onga@gmail.com>2019-01-04 19:39:14 +1100
committerAlex Ong <the.onga@gmail.com>2019-01-04 19:39:14 +1100
commit47c91fc7f75ae0a477e55b687aa0fc30da0a283c (patch)
tree65ad39452748ff2e6d4a83ce54ede6ca22c9ada9 /keyboards/jj40/keymaps
parentac9b88e8ccbbf38762871504cd827ff0d941c426 (diff)
parent563ce3f225d981ce460c12ca5130dfe47af41df0 (diff)
Merge branch 'master' of https://github.com/qmk/qmk_firmware
Diffstat (limited to 'keyboards/jj40/keymaps')
-rw-r--r--keyboards/jj40/keymaps/ajp10304/config.h8
-rw-r--r--keyboards/jj40/keymaps/cockpit/keymap.c8
-rw-r--r--keyboards/jj40/keymaps/default/keymap.c6
-rw-r--r--keyboards/jj40/keymaps/fun40/config.h1
-rw-r--r--keyboards/jj40/keymaps/krusli/config.h1
-rw-r--r--keyboards/jj40/keymaps/krusli/keymap.c35
-rw-r--r--keyboards/jj40/keymaps/like_jis/config.h49
-rw-r--r--keyboards/jj40/keymaps/like_jis/keymap.c200
-rw-r--r--keyboards/jj40/keymaps/like_jis/rules.mk5
-rw-r--r--keyboards/jj40/keymaps/oscillope/backlight.c60
-rw-r--r--keyboards/jj40/keymaps/oscillope/config.h1
-rw-r--r--keyboards/jj40/keymaps/oscillope/keymap.c17
-rw-r--r--keyboards/jj40/keymaps/skewwhiffy/keymap.c219
-rw-r--r--keyboards/jj40/keymaps/suzuken/config.h1
-rw-r--r--keyboards/jj40/keymaps/waples/config.h1
15 files changed, 513 insertions, 99 deletions
diff --git a/keyboards/jj40/keymaps/ajp10304/config.h b/keyboards/jj40/keymaps/ajp10304/config.h
deleted file mode 100644
index 11cafbefcb..0000000000
--- a/keyboards/jj40/keymaps/ajp10304/config.h
+++ /dev/null
@@ -1,8 +0,0 @@
-#ifndef CONFIG_USER_H
-#define CONFIG_USER_H
-
-#include "../../config.h"
-
-#define PREVENT_STUCK_MODIFIERS
-
-#endif
diff --git a/keyboards/jj40/keymaps/cockpit/keymap.c b/keyboards/jj40/keymaps/cockpit/keymap.c
index 02deaaa8e3..12ed62b6b5 100644
--- a/keyboards/jj40/keymaps/cockpit/keymap.c
+++ b/keyboards/jj40/keymaps/cockpit/keymap.c
@@ -63,7 +63,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | Ctrl | Fn | GUI | Alt |Lower | Space |Raise | Left | Down | Up |Right |
* `-----------------------------------------------------------------------------------'
*/
-[_QWERTY] = LAYOUT_2U_space( \
+[_QWERTY] = LAYOUT_planck_mit( \
KC_GESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, \
KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, \
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , \
@@ -85,7 +85,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | Ctrl | | | Alt |Lower|| Space | | Home | PgDn | PgUp | End |
* `-----------------------------------------------------------------------------------'
*/
-[_LOWER] = LAYOUT_2U_space( \
+[_LOWER] = LAYOUT_planck_mit( \
KC_GRV, LT_A_OG, LT_C_CA, LT_E_OG, LT_E_DO, LT_I_OG, LT_S_CA, LT_U_OG, LT_U_MA, LT_Z_CA, KC_MINS, KC_BSPC, \
KC_TAB, LT_EXLM, LT_AT, LT_HASH, LT_DLR, LT_PERC, LT_CIRC, LT_AMPR, LT_ASTR, KC_LPRN, KC_RPRN, KC_DEL , \
KC_LSFT, KC_PEQL, KC_PPLS, KC_PMNS, KC_PIPE, KC_LBRC, KC_RBRC, KC_LABK, KC_RABK, KC_LCBR, KC_RCBR, KC_INS , \
@@ -107,7 +107,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | Ctrl | | | Alt | | Space |Raise|| Left | Down | Up |Right |
* `-----------------------------------------------------------------------------------'
*/
-[_RAISE] = LAYOUT_2U_space( \
+[_RAISE] = LAYOUT_planck_mit( \
KC_GRV, LT_1, LT_2, LT_3, LT_4, LT_5, LT_6, LT_7, LT_8, LT_9, LT_0, KC_BSPC, \
KC_TAB, LT_4, LT_5, LT_6, _______, _______, _______, _______, _______, _______, _______, KC_BSLS, \
KC_LSFT, LT_7, LT_8, LT_9, LT_0, _______, _______, _______, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , \
@@ -130,7 +130,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | Ctrl |||Fn||| Mode | Alt | | Space |MPrev |MStop |MNext |MPlay | Lock |
* `-----------------------------------------------------------------------------------'
*/
-[_FUNC] = LAYOUT_2U_space( \
+[_FUNC] = LAYOUT_planck_mit( \
KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, \
KC_CAPS, RGB_TOG, RGB_HUI, RGB_SAI, RGB_VAI, BL_TOGG, BL_BRTG, BL_INC, _______, _______, _______, KC_VOLU, \
KC_LSFT, KC_CALC, RGB_HUD, RGB_SAD, RGB_VAD, KC_WBAK, KC_WFWD, BL_DEC, _______, _______, KC_PSCR, KC_VOLD, \
diff --git a/keyboards/jj40/keymaps/default/keymap.c b/keyboards/jj40/keymaps/default/keymap.c
index 1db887bd01..d84b01b15a 100644
--- a/keyboards/jj40/keymaps/default/keymap.c
+++ b/keyboards/jj40/keymaps/default/keymap.c
@@ -23,7 +23,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | | Ctrl | Alt | GUI |Lower | Space |Raise | Left | Down | Up |Right |
* `-----------------------------------------------------------------------------------'
*/
-[_QWERTY] = LAYOUT_2U_space( \
+[_QWERTY] = LAYOUT_planck_mit( \
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, \
KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, \
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , \
@@ -41,7 +41,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | | | | | | | | Next | Vol- | Vol+ | Play |
* `-----------------------------------------------------------------------------------'
*/
-[_LOWER] = LAYOUT_2U_space( \
+[_LOWER] = LAYOUT_planck_mit( \
KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC, \
KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE, \
_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12,S(KC_NUHS),S(KC_NUBS),_______, _______, _______, \
@@ -59,7 +59,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | | | | | | | | Next | Vol- | Vol+ | Play |
* `-----------------------------------------------------------------------------------'
*/
-[_RAISE] = LAYOUT_2U_space( \
+[_RAISE] = LAYOUT_planck_mit( \
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, \
KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, \
_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NUHS, KC_NUBS, _______, _______, _______, \
diff --git a/keyboards/jj40/keymaps/fun40/config.h b/keyboards/jj40/keymaps/fun40/config.h
index 89807d84ad..f2b5d264e7 100644
--- a/keyboards/jj40/keymaps/fun40/config.h
+++ b/keyboards/jj40/keymaps/fun40/config.h
@@ -4,6 +4,5 @@
#include "../../config.h"
#define FORCE_NKRO
-#define PREVENT_STUCK_MODIFIERS
#endif
diff --git a/keyboards/jj40/keymaps/krusli/config.h b/keyboards/jj40/keymaps/krusli/config.h
index 6d98a37a67..e710dbbb60 100644
--- a/keyboards/jj40/keymaps/krusli/config.h
+++ b/keyboards/jj40/keymaps/krusli/config.h
@@ -3,7 +3,6 @@
#include "../../config.h"
-#define PREVENT_STUCK_MODIFIERS
// #define TAPPING_TERM 300
#endif
diff --git a/keyboards/jj40/keymaps/krusli/keymap.c b/keyboards/jj40/keymaps/krusli/keymap.c
index 6fea9d314e..f996fbf35b 100644
--- a/keyboards/jj40/keymaps/krusli/keymap.c
+++ b/keyboards/jj40/keymaps/krusli/keymap.c
@@ -26,11 +26,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | | Ctrl | GUI | Alt |Lower | Space |Raise | Left | Down | Up |Right |
* `-----------------------------------------------------------------------------------'
*/
- [_QWERTY] = LAYOUT_2U_space( \
- KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, \
- KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, \
- KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , \
- _______, KC_LCTL, KC_LGUI, KC_LALT, MO(_LOWER), KC_SPC, MO(_RAISE), KC_LEFT, KC_DOWN, KC_UP, KC_RGHT \
+
+ [_QWERTY] = LAYOUT_planck_mit( \
+ KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, \
+ KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, \
+ KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , \
+ TO(_NUMPAD),KC_LCTL, KC_LGUI, KC_LALT, MO(_LOWER), KC_SPC, MO(_RAISE), KC_LEFT, KC_DOWN, KC_UP, KC_RGHT \
),
/* Lower
@@ -41,10 +42,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | | F7 | F8 | F9 | F10 | F11 | F12 | RGB | RGB | RGB | RGB |Enter |
* |------+------+------+------+------+------+------+------+------+------+------+------|
- * | | RGB | RGB | RGB | | | Next | Vol- | Vol+ | Play | |
+ * | | RGB | RGB | RGB | | | Next | Vol- | Vol+ | Play | |
* `-----------------------------------------------------------------------------------'
*/
- [_LOWER] = LAYOUT_2U_space( \
+ [_LOWER] = LAYOUT_planck_mit( \
KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC, \
KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE, \
_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, RGB_TOG, RGB_MOD, RGB_VAD, RGB_VAI, _______, \
@@ -62,10 +63,28 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | | Prev | Play | Next | | | | Next | Vol- | Vol+ | Play |
* `-----------------------------------------------------------------------------------'
*/
- [_RAISE] = LAYOUT_2U_space( \
+ [_RAISE] = LAYOUT_planck_mit( \
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, \
KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, \
_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_HOME, KC_END, KC_PGUP, KC_PGDN, _______, \
_______, KC_MRWD, KC_MPLY, KC_MNXT, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY \
+ ),
+
+ /* Numpad
+ * ,-----------------------------------------------------------------------------------.
+ * | Esc | 7 | 8 | 9 | * | / | | | | | | |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | <-- | 4 | 5 | 6 | + | - | | | | | | |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | | 1 | 2 | 3 |Enter |Enter | | | | | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * |Qwerty| 0 | . | . |Enter | | | | | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+ [_NUMPAD] = LAYOUT_planck_mit( \
+ KC_ESC, KC_P7, KC_P8, KC_P9, KC_PAST, KC_PSLS, _______, _______, _______, _______, _______, _______, \
+ KC_BSPC, KC_P4, KC_P5, KC_P6, KC_PPLS, KC_PMNS, _______, _______, _______, _______, _______, _______, \
+ _______, KC_P1, KC_P2, KC_P3, KC_PENT, KC_PENT, _______, _______, _______, _______, _______, _______, \
+ TO(_QWERTY),KC_P0, KC_PDOT, KC_PDOT, KC_PENT, _______, _______, _______, _______, _______, _______ \
)
};
diff --git a/keyboards/jj40/keymaps/like_jis/config.h b/keyboards/jj40/keymaps/like_jis/config.h
new file mode 100644
index 0000000000..cd9709272c
--- /dev/null
+++ b/keyboards/jj40/keymaps/like_jis/config.h
@@ -0,0 +1,49 @@
+/*
+This is the c configuration file for the keymap
+
+Copyright 2012 Jun Wako <wakojun@gmail.com>
+Copyright 2015 Jack Humbert
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#pragma once
+
+// place overrides here
+
+#define TAPPING_TERM 200
+
+#ifdef MOUSEKEY_ENABLE
+ #undef MOUSEKEY_INTERVAL
+ #define MOUSEKEY_INTERVAL 5
+
+ #undef MOUSEKEY_TIME_TO_MAX
+ #define MOUSEKEY_TIME_TO_MAX 150
+
+ #undef MOUSEKEY_MAX_SPEED
+ #define MOUSEKEY_MAX_SPEED 3
+
+ #undef MOUSEKEY_MOVE_DELTA
+ #define MOUSEKEY_MOVE_DELTA 3
+
+ #undef MOUSEKEY_DELAY
+ #define MOUSEKEY_DELAY 0
+#endif
+
+#undef BACKLIGHT_LEVELS
+#define BACKLIGHT_LEVELS 15
+// #undef BACKLIGHT_LEVELS
+// #define BACKLIGHT_BREATHING
+// #undef BREATHING_PERIOD
+// #define BREATHING_PERIOD 4
diff --git a/keyboards/jj40/keymaps/like_jis/keymap.c b/keyboards/jj40/keymaps/like_jis/keymap.c
new file mode 100644
index 0000000000..24db919472
--- /dev/null
+++ b/keyboards/jj40/keymaps/like_jis/keymap.c
@@ -0,0 +1,200 @@
+#include QMK_KEYBOARD_H
+
+#define _QWERTY 0
+#define _LOWER 3
+#define _RAISE 4
+#define _ADJUST 16
+
+enum custom_keycodes {
+ LOWER = SAFE_RANGE,
+ RAISE,
+ ADJUST,
+ RGBRST
+};
+
+#define KC______ KC_TRNS
+#define KC_XXXXX KC_NO
+#define KC_KANJI KC_GRV
+
+#define KC_LOWER LOWER
+#define KC_RAISE RAISE
+#define KC_ADJST ADJUST
+
+#define KC_RST RESET
+
+#define KC_LRST RGBRST
+#define KC_LTOG RGB_TOG
+#define KC_LHUI RGB_HUI
+#define KC_LHUD RGB_HUD
+#define KC_LSAI RGB_SAI
+#define KC_LSAD RGB_SAD
+#define KC_LVAI RGB_VAI
+#define KC_LVAD RGB_VAD
+#define KC_LMOD RGB_MOD
+#define KC_BTOG BL_TOGG
+#define KC_BINC BL_INC
+#define KC_BDEC BL_DEC
+// #define KC_BRTG BL_BRTG
+
+#define KC_KNRM AG_NORM
+#define KC_KSWP AG_SWAP
+
+// Layer Mode aliases
+// #define KC_L_LO MO(_LOWER)
+// #define KC_L_RA MO(_RAISE)
+// #define KC_L_AD MO(_ADJUST)
+#define KC_TBSF LSFT_T(KC_TAB)
+// #define KC_SPSF LSFT_T(KC_SPC)
+// #define KC_GUAP LALT_T(KC_APP)
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+ [_QWERTY] = KC_LAYOUT_ortho_4x12( \
+ //,-----------------------------------------------------------------------------------.
+ ESC, Q, W, E, R, T, Y, U, I, O, P, MINS,\
+ //|------+------+------+------+------+------|------+------+------+------+------+------|
+ TBSF, A, S, D, F, G, H, J, K, L, SCLN, ENT,\
+ //|------+------+------+------+------+------|------+------+------+------+------+------|
+ LSFT, Z, X, C, V, B, N, M, COMM, DOT, UP, RSFT,\
+ //|------+------+------+------+------+------|------+------+------+------+------+------|
+ LCTRL, LALT, LGUI, ADJST, LOWER, BSPC, SPC, RAISE, APP, LEFT, DOWN, RGHT \
+ //|------+------+------+------+------+-------------+------+------+------+------+------|
+ ),
+
+ [_LOWER] = KC_LAYOUT_ortho_4x12( \
+ //,-----------------------------------------------------------------------------------.
+ TAB, F1, F2, F3, F4, F5, XXXXX, MINS, EQL, JYEN, LBRC, RBRC,\
+ //|------+------+------+------+------+------|------+------+------+------+------+------|
+ _____, F6, F7, F8, F9, F10, XXXXX, XXXXX, XXXXX, SCLN, QUOT, BSLS,\
+ //|------+------+------+------+------+------|------+------+------+------+------+------|
+ _____, F11, F12, XXXXX, KANJI, ENT, XXXXX, XXXXX, COMM, DOT, SLSH, RO,\
+ //|------+------+------+------+------+-------------+------+------+------+------+------|
+ _____, _____, _____, _____, _____, DEL, _____, _____, _____, _____, _____, _____ \
+ //|------+------+------+------+------+-------------+------+------+------+------+------|
+ ),
+
+ [_RAISE] = KC_LAYOUT_ortho_4x12( \
+ //,-----------------------------------------------------------------------------------.
+ _____, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, MINS,\
+ //|------+------+------+------+------+------|------+------+------+------+------+------|
+ _____, XXXXX, XXXXX, XXXXX, XXXXX, XXXXX, XXXXX, 4, 5, 6, QUOT, PLUS,\
+ //|------+------+------+------+------+------|------+------+------+------+------+------|
+ _____, XXXXX, XXXXX, XXXXX, XXXXX, XXXXX, 0, 1, 2, 3, DOT, SLSH,\
+ //|------+------+------+------+------+-------------+------+------+------+------+------|
+ _____, _____, _____, _____, _____, BSPC, _____, _____, _____, _____, _____, _____ \
+ //|------+------+------+------+------+-------------+------+------+------+------+------|
+ ),
+
+ [_ADJUST] = KC_LAYOUT_ortho_4x12( \
+ //,-----------------------------------------------------------------------------------.
+ XXXXX, RST, LRST, KNRM, KSWP, XXXXX, XXXXX, WH_L, WH_U, HOME, PGUP, XXXXX,\
+ //|------+------+------+------+------+------|------+------+------+------+------+------|
+ XXXXX, LTOG, LHUI, LSAI, LVAI, BTOG, BINC, WH_R, WH_D, END, PGDN, XXXXX,\
+ //|------+------+------+------+------+------|------+------+------+------+------+------|
+ XXXXX, LMOD, LHUD, LSAD, LVAD, XXXXX, BDEC, XXXXX, BTN1, BTN2, MS_U, XXXXX,\
+ //|------+------+------+------+------+-------------+------+------+------+------+------|
+ _____, _____, _____, _____, _____, XXXXX, XXXXX, _____, _____, MS_L, MS_D, MS_R \
+ //|------+------+------+------+------+-------------+------+------+------+------+------|
+ )
+};
+
+
+#ifdef BACKLIGHT_ENABLE
+ extern backlight_config_t backlight_config;
+
+ inline void enable_backright(bool on) {
+ backlight_config.enable = on;
+ if (backlight_config.raw == 1) // enabled but level = 0
+ backlight_config.level = 1;
+ eeconfig_update_backlight(backlight_config.raw);
+ // dprintf("backlight toggle: %u\n", backlight_config.enable);
+ backlight_set(backlight_config.enable ? backlight_config.level : 0);
+ }
+
+ uint8_t bl_breath_count;
+ uint8_t bl_breath_speed = 10;
+ int8_t bl_breath_updown = 1;
+ bool bl_breath_on;
+ backlight_config_t bl_breath_backup;
+
+ void bl_breath_start(uint8_t speed) {
+
+ bl_breath_on = true;
+ bl_breath_speed = speed;
+ bl_breath_backup = backlight_config;
+ }
+
+ void bl_breath_end(void) {
+
+ bl_breath_on = false;
+ backlight_config = bl_breath_backup;
+ eeconfig_update_backlight(backlight_config.raw);
+ backlight_set(backlight_config.enable ? backlight_config.level : 0);
+ }
+
+ void bl_breath_update(void) {
+
+ if (bl_breath_on) {
+ ++bl_breath_count;
+ if (bl_breath_count > bl_breath_speed) {
+ bl_breath_count = 0;
+
+ backlight_config.level += bl_breath_updown;
+ bl_breath_updown = (backlight_config.level > BACKLIGHT_LEVELS) ? -1 :
+ (backlight_config.level <= 0) ? 1 :
+ bl_breath_updown;
+ enable_backright(true);
+ }
+ }
+ }
+
+ #define BL_BREATH_START bl_breath_start
+ #define BL_BREATH_END bl_breath_end
+ #define BL_BREATH_UPDATE bl_breath_update
+
+#else
+
+ #define BL_BREATH_START(a)
+ #define BL_BREATH_END()
+ #define BL_BREATH_UPDATE()
+#endif
+
+// Loop
+void matrix_scan_user(void) {
+
+ BL_BREATH_UPDATE();
+}
+
+bool process_record_user(uint16_t keycode, keyrecord_t *record) {
+
+ switch (keycode) {
+ case LOWER:
+ if (record->event.pressed) {
+ BL_BREATH_START(50);
+ layer_on(_LOWER);
+ } else {
+ BL_BREATH_END();
+ layer_off(_LOWER);
+ }
+ break;
+ case RAISE:
+ if (record->event.pressed) {
+ BL_BREATH_START(100);
+ layer_on(_RAISE);
+ } else {
+ BL_BREATH_END();
+ layer_off(_RAISE);
+ }
+ break;
+ case ADJUST:
+ if (record->event.pressed) {
+ layer_on(_ADJUST);
+ } else {
+ layer_off(_ADJUST);
+ }
+ break;
+ default:
+ return true;
+ }
+
+ return false;
+}
diff --git a/keyboards/jj40/keymaps/like_jis/rules.mk b/keyboards/jj40/keymaps/like_jis/rules.mk
new file mode 100644
index 0000000000..0103be5f4a
--- /dev/null
+++ b/keyboards/jj40/keymaps/like_jis/rules.mk
@@ -0,0 +1,5 @@
+MOUSEKEY_ENABLE = yes
+BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
+
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
diff --git a/keyboards/jj40/keymaps/oscillope/backlight.c b/keyboards/jj40/keymaps/oscillope/backlight.c
deleted file mode 100644
index 14c677cd6c..0000000000
--- a/keyboards/jj40/keymaps/oscillope/backlight.c
+++ /dev/null
@@ -1,60 +0,0 @@
-/**
- * Backlighting code for PS2AVRGB boards (ATMEGA32A)
- * Kenneth A. (github.com/krusli | krusli.me)
- */
-
-#include "quantum.h"
-
-#include <avr/pgmspace.h>
-#include <avr/interrupt.h>
-
-// Port D: digital pins of the AVR chipset
-#define NUMLOCK_PORT (1 << 0) // D0
-#define CAPSLOCK_PORT (1 << 1) // D1
-#define BACKLIGHT_PORT (1 << 4) // D4
-#define SCROLLLOCK_PORT (1 << 6) // D6
-
-/**
- * References
- * Port Registers: https://www.arduino.cc/en/Reference/PortManipulation
- * TCCR1A: https://electronics.stackexchange.com/questions/92350/what-is-the-difference-between-tccr1a-and-tccr1b
- * Timers: http://www.avrbeginners.net/architecture/timers/timers.html
- * 16-bit timer setup: http://sculland.com/ATmega168/Interrupts-And-Timers/16-Bit-Timer-Setup/
- * PS2AVRGB firmware: https://github.com/showjean/ps2avrU/tree/master/firmware
- */
-
-// @Override
-// turn LEDs on and off depending on USB caps/num/scroll lock states.
-__attribute__ ((weak))
-void led_set_user(uint8_t usb_led) {
-/* It appears that these cause the v1 JJ40 PCB to hang.
- * I haven't looked into why, but I don't have any LEDs on my board anyway. */
-#if 0
- if (usb_led & (1 << USB_LED_NUM_LOCK)) {
- // turn on
- DDRD |= NUMLOCK_PORT;
- PORTD |= NUMLOCK_PORT;
- } else {
- // turn off
- DDRD &= ~NUMLOCK_PORT;
- PORTD &= ~NUMLOCK_PORT;
- }
-
- if (usb_led & (1 << USB_LED_CAPS_LOCK)) {
- DDRD |= CAPSLOCK_PORT;
- PORTD |= CAPSLOCK_PORT;
- } else {
- DDRD &= ~CAPSLOCK_PORT;
- PORTD &= ~CAPSLOCK_PORT;
- }
-
- if (usb_led & (1 << USB_LED_SCROLL_LOCK)) {
- DDRD |= SCROLLLOCK_PORT;
- PORTD |= SCROLLLOCK_PORT;
- } else {
- DDRD &= ~SCROLLLOCK_PORT;
- PORTD &= ~SCROLLLOCK_PORT;
- }
-#endif
-}
-
diff --git a/keyboards/jj40/keymaps/oscillope/config.h b/keyboards/jj40/keymaps/oscillope/config.h
index d7f991fa91..e812903de9 100644
--- a/keyboards/jj40/keymaps/oscillope/config.h
+++ b/keyboards/jj40/keymaps/oscillope/config.h
@@ -3,7 +3,6 @@
#include "../../config.h"
-#define PREVENT_STUCK_MODIFIERS
#define TAPPING_TERM 200
#endif
diff --git a/keyboards/jj40/keymaps/oscillope/keymap.c b/keyboards/jj40/keymaps/oscillope/keymap.c
index 49ceff864c..1a42261940 100644
--- a/keyboards/jj40/keymaps/oscillope/keymap.c
+++ b/keyboards/jj40/keymaps/oscillope/keymap.c
@@ -17,11 +17,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include QMK_KEYBOARD_H
-#ifdef KEYMAP
-#undef KEYMAP
-#endif
-#define KEYMAP KEYMAP_OFFSET
-
#define _QWERTY 0
#define _LOWER 1
#define _RAISE 2
@@ -51,7 +46,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | Ctrl | OS | Alt |Lower |Shift |Raise | Space | Left | Down | Up |Right |
* `-----------------------------------------------------------------------------------'
*/
-[_QWERTY] = KEYMAP( \
+[_QWERTY] = LAYOUT_planck_1x2uR( \
KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, \
KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, \
KC_GRV, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_QUOT, \
@@ -62,16 +57,16 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* ,-----------------------------------------------------------------------------------.
* | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 |
* |------+------+------+------+------+-------------+------+------+------+------+------|
- * | Ins | | | () | [] | {} | Left | Down | Up |Right | | |
+ * | Ins | | | () | [] | {} | Home | PgDn | PgUp | End | | |
* |------+------+------+------+------+------|------+------+------+------+------+------|
* |RESET | Back | Fwd | | | | | | Mute | Vol- | Vol+ | |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | | | | | Lock | | | Prev | Stop | Play | Next |
* `-----------------------------------------------------------------------------------'
*/
-[_LOWER] = KEYMAP( \
+[_LOWER] = LAYOUT_planck_1x2uR( \
KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, \
- KC_INS, _______, _______, CC_PRN, CC_BRC, CC_CBR, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, _______, _______, \
+ KC_INS, _______, _______, CC_PRN, CC_BRC, CC_CBR, KC_HOME, KC_PGDN, KC_PGUP, KC_END, _______, _______, \
RESET, KC_WBAK, KC_WFWD, _______, _______, _______, _______, _______, KC_MUTE, KC_VOLD, KC_VOLU, _______, \
_______, _______, _______, _______, KC_LOCK, _______, _______, KC_MPRV, KC_MSTP, KC_MPLY, KC_MNXT \
),
@@ -87,14 +82,14 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | Ctrl | OS | Alt | |Shift | | 0 | Home | PgDn | PgUp | End |
* `-----------------------------------------------------------------------------------'
*/
-[_RAISE] = KEYMAP( \
+[_RAISE] = LAYOUT_planck_1x2uR( \
KC_CAPS, KC_AMPR, KC_ASTR, KC_UNDS, KC_LPRN, KC_RPRN, KC_7, KC_8, KC_9, KC_EQL, KC_BSPC, KC_DEL, \
KC_TAB, KC_DLR, KC_PERC, KC_CIRC, KC_LBRC, KC_RBRC, KC_4, KC_5, KC_6, KC_MINS, KC_PLUS, _______, \
CC_ARRW, KC_EXLM, KC_AT, KC_HASH, KC_LCBR, KC_RCBR, KC_1, KC_2, KC_3, _______, KC_BSLS, KC_PIPE, \
_______, _______, _______, _______, _______, _______, KC_0, KC_HOME, KC_PGDN, KC_PGUP, KC_END \
),
-[_NAV] = KEYMAP( \
+[_NAV] = LAYOUT_planck_1x2uR( \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, _______, _______, _______, _______, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
diff --git a/keyboards/jj40/keymaps/skewwhiffy/keymap.c b/keyboards/jj40/keymaps/skewwhiffy/keymap.c
new file mode 100644
index 0000000000..6b193a15cb
--- /dev/null
+++ b/keyboards/jj40/keymaps/skewwhiffy/keymap.c
@@ -0,0 +1,219 @@
+/* Copyright 2017 Kenny Hung
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+#include QMK_KEYBOARD_H
+#include "keymap_uk.h"
+
+// Layer shorthand
+enum Layers {
+ cm, // colemak
+ dv, // dvorak
+ qw, // qwerty
+ nbl, // numbers left
+ nbr, // numbers right
+ syl, // symbols left
+ syr, // symbols right
+ nal, // navigation left
+ nar // navigation right
+};
+
+// Layer buttons
+#define _Z_SFT SFT_T(UK_Z)
+#define _SCLSH SFT_T(UK_SCLN)
+#define _SLSH SFT_T(UK_SLSH)
+
+#define _X_NB LT(nbl, UK_X)
+#define _Q_NB LT(nbl, UK_Q)
+#define _DOT_NB LT(nbr, UK_DOT)
+#define _V_NB LT(nbr, UK_V)
+#define __NBL LT(nbl, _______)
+#define __NBR LT(nbr, _______)
+
+#define _C_SY LT(syl, UK_C)
+#define _J_SY LT(syl, UK_J)
+#define _W_SY LT(syr, UK_W)
+#define _COM_SY LT(syr, UK_COMM)
+#define __SYL LT(syl, _______)
+#define __SYR LT(syr, _______)
+
+#define _V_NAL LT(nal, UK_V)
+#define _K_NAL LT(nal, UK_K)
+#define _M_NAR LT(nar, UK_M)
+#define __NAL LT(nal, _______)
+#define __NAR LT(nar, _______)
+
+// Custom hotkeys
+#define _TERM LCTL(UK_QUOT) // Hotkey for terminal
+#define _S_TAB S(UK_TAB)
+#define _C_LEFT LCTL(UK_LEFT)
+#define _C_RGHT LCTL(UK_RGHT)
+#define _A_LEFT LALT(UK_LEFT)
+#define _A_RGHT LALT(UK_RGHT)
+
+// Custom hotkeys
+#define _TERM LCTL(UK_QUOT) // Hotkey for terminal
+#define _S_TAB S(UK_TAB)
+#define _C_LEFT LCTL(UK_LEFT)
+#define _C_RGHT LCTL(UK_RGHT)
+#define _A_LEFT LALT(UK_LEFT)
+#define _A_RGHT LALT(UK_RGHT)
+
+enum custom_keycodes {
+ IJ_OMN = SAFE_RANGE // IntelliJ Omnibox
+};
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+
+/* Colemak
+ * .-----------------------------------------------------------------------------------------------------------.
+ * | Q | W | F | P | G | | | J | L | U | Y | ; |
+ * |-----------------------------------------------------------------------------------------------------------|
+ * | A | R | S | T | D | | | H | N | E | I | O |
+ * |-----------------------------------------------------------------------------------------------------------|
+ * | Z | X | C | V | B | | | K | M | , | . | / |
+ * | SHIFT | NUMBER | SYMBOL | NAV | | | | | NAV | SYMBOL | FUNC | SHIFT |
+ * |-----------------------------------------------------------------------------------------------------------|
+ * | LSHIFT | LCTRL | LALT | LGUI | SPACE | ENT | DEL | BKSPC | RGUI | RALT | RCTRL | RSHIFT |
+ * .-----------------------------------------------------------------------------------------------------------.
+ */
+ [cm] = LAYOUT_ortho_4x12( \
+ UK_Q, UK_W, UK_F, UK_P, UK_G, _______, _______, UK_J, UK_L, UK_U, UK_Y, UK_SCLN, \
+ UK_A, UK_R, UK_S, UK_T, UK_D, _______, _______, UK_H, UK_N, UK_E, UK_I, UK_O, \
+ _Z_SFT, _X_NB, _C_SY, _V_NAL, UK_B, _______, _______, UK_K, _M_NAR, _COM_SY, _DOT_NB, _SLSH, \
+ UK_LSFT, UK_LCTL, UK_LALT, UK_LGUI, UK_SPC, UK_ENT, UK_DEL, UK_BSPC, UK_RGUI, UK_RALT, UK_RCTL, UK_RSFT \
+ ),
+
+/* Dvorak
+ * .-----------------------------------------------------------------------------------------------------------.
+ * | ' | , | . | P | Y | | | F | G | C | R | L |
+ * |-----------------------------------------------------------------------------------------------------------|
+ * | A | O | E | U | I | | | D | H | T | N | S |
+ * |-----------------------------------------------------------------------------------------------------------|
+ * | ; | Q | J | K | X | | | B | M | W | V | Z |
+ * | SHIFT | NUMBER | SYMBOL | NAV | | | | | NAV | SYMBOL | FUNC | SHIFT |
+ * |-----------------------------------------------------------------------------------------------------------|
+ * | | | | | | | | | | | | |
+ * |-----------------------------------------------------------------------------------------------------------|
+ */
+ [dv] = LAYOUT_ortho_4x12( \
+ UK_QUOT, UK_COMM, UK_DOT, UK_P, UK_Y, _______, _______, UK_F, UK_G, UK_C, UK_R, UK_L, \
+ UK_A, UK_O, UK_E, UK_U, UK_I, _______, _______, UK_D, UK_H, UK_T, UK_N, UK_S, \
+ _SCLSH, _Q_NB, _J_SY, _K_NAL, UK_X, _______, _______, UK_B, _M_NAR, _W_SY, _V_NB, _Z_SFT, \
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ \
+ ),
+
+/* QWERTY
+ * .-----------------------------------------------------------------------------------------------------------.
+ * | Q | W | E | R | T | | | Y | U | I | O | P |
+ * |-----------------------------------------------------------------------------------------------------------|
+ * | A | S | D | F | G | | | H | J | K | L | ; |
+ * |-----------------------------------------------------------------------------------------------------------|
+ * | Z | X | C | V | B | | | N | M | , | . | / |
+ * | SHIFT | NUMBER | SYMBOL | NAV | | | | | NAV | SYMBOL | FUNC | SHIFT |
+ * |-----------------------------------------------------------------------------------------------------------|
+ * | | | | | | | | | | | | |
+ * .-----------------------------------------------------------------------------------------------------------.
+ */
+ [qw] = LAYOUT_ortho_4x12( \
+ UK_Q, UK_W, UK_E, UK_R, UK_T, _______, _______, UK_Y, UK_U, UK_I, UK_O, UK_P, \
+ UK_A, UK_S, UK_D, UK_F, UK_G, _______, _______, UK_H, UK_J, UK_K, UK_L, UK_SCLN, \
+ _Z_SFT, _X_NB, _C_SY, _V_NAL, UK_B, _______, _______, UK_N, _M_NAR, _COM_SY, _DOT_NB, _SLSH, \
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ \
+ ),
+
+/* Numbers _NB
+ * .-----------------------------------------------------------------------------------------------------------.
+ * | | F7 | F8 | F9 | F10 | | | | 7 | 8 | 9 | |
+ * |-----------------+--------+--------+-