1
0
Fork 0

[keymap(kyria), refactor] created kyria keymap. refactored ninjonas userspace (#8053)

* [keymap(kyria), refactor] created kyria keymap. refactored ninjonas userspace and keyboards

* [fix(#8053)] removed redundant code based off Duckle29's code review

* [fix(#8053)] fixing typos

* [refactor(#8053)] updating oled timeout

* [fix(8053) resolved code review issues identified by noroadsleft
This commit is contained in:
Jonas Avellana 2020-01-31 23:38:05 -07:00 committed by GitHub
parent fdabf524f2
commit 1aee492c0f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 468 additions and 72 deletions

View file

@ -32,7 +32,7 @@ This keymap is designed based off my typing habits and is subject to change. Inf
### QWERTY
```c
/* Keymap 0: QWERTY
/* QWERTY
*
* ,--------------------------------------------------. ,--------------------------------------------------.
* | ` | 1 | 2 | 3 | 4 | 5 | Play | |K_LOCK | 6 | 7 | 8 | 9 | 0 | - |
@ -43,7 +43,7 @@ This keymap is designed based off my typing habits and is subject to change. Inf
* |--------+------+------+------+------+------| [ | | ] |------+------+------+------+------+--------|
* | LShift | Z | X | C | V | B | | | | N | M | , | . | / | = |
* `--------+------+------+------+------+-------------' `--------------+------+------+------+------+--------'
* |M_SHFT| | Alt |  | Ctl | | BkSP | Del |LOWER |M_XXX1|M_PYNV|
* | | | Alt |  | Ctl | | BkSP | Del |LOWER | | |
* `----------------------------------' `----------------------------------'
* ,-------------. ,-------------.
* | Up | Down | | Left | Right|
@ -57,16 +57,16 @@ This keymap is designed based off my typing habits and is subject to change. Inf
### LOWER
```c
/* Keymap 1: LOWER
/* LOWER
*
* ,--------------------------------------------------. ,----------------------------------------------------.
* | F11 | F1 | F2 | F3 | F4 | F5 | | | | F6 | F7 | F8 | F9 | F10 | F12 |
* |--------+------+------+------+------+-------------| |-------+------+------+------+------+-------+--------|
* | | | |KC_BRU| Play | Mute | | | | PgUp | Home | Up | End | | |
* | | |KC_BRU| Play | Mute | | | | | PgUp | Home | Up | End | | |
* |--------+------+------+------+------+------| | | |------+------+------+------+-------+--------|
* | | | |KC_BRD| Next |VolUp |------| |-------| PgDn | Left | Down |Right |K_LOCK | |
* | | |KC_BRD| Next |VolUp | |------| |-------| PgDn | Left | Down |Right |K_LOCK | |
* |--------+------+------+------+------+------| | | |------+------+------+------+-------+--------|
* | | | | | Prev |VolDn | | | | | | | | | |
* | | | | Prev |VolDn | | | | | | | | | | |
* `--------+------+------+------+------+-------------' `--------------+------+------+------+-------+--------'
* | | | | | | | | | |M_CODE | |
* `----------------------------------' `-----------------------------------'
@ -82,16 +82,16 @@ This keymap is designed based off my typing habits and is subject to change. Inf
### RAISE
```c
/* Keymap 2: RAISE
/* RAISE
*
* ,--------------------------------------------------. ,----------------------------------------------------.
* | | | | |K_CSCN| | | | | | | | | | |
* | | | | | | | | | | | | | | | |
* |--------+------+------+------+------+-------------| |-------+------+------+------+------+-------+--------|
* | M_MAKE | | MS_1 | MS_U | MS_2 | WH_U | | | | | | | | | |
* | | | MS_1 | MS_U | MS_2 | WH_U | | | | | | | | | |
* |--------+------+------+------+------+------| | | |------+------+------+------+-------+--------|
* | M_VRSN | | MS_L | MS_D | MS_R | WH_D |------| |-------| | | | | | |
* | | | MS_L | MS_D | MS_R | WH_D |------| |-------| | | | | | |
* |--------+------+------+------+------+------| | | |------+------+------+------+-------+--------|
* | M_FLSH | | | | | | | | | | | | | | |
* | | | | | | | | | | | | | | | |
* `--------+------+------+------+------+-------------' `--------------+------+------+------+-------+--------'
* | | | | | | | | | | | |
* `----------------------------------' `-----------------------------------'

View file

@ -14,7 +14,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include QMK_KEYBOARD_H
#include "ninjonas.h"
#include "ninjonas.h"
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* QWERTY
@ -28,7 +28,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* |--------+------+------+------+------+------| [ | | ] |------+------+------+------+------+--------|
* | LShift | Z | X | C | V | B | | | | N | M | , | . | / | = |
* `--------+------+------+------+------+-------------' `--------------+------+------+------+------+--------'
* |M_SHFT| | Alt | | Ctl | | BkSP | Del |LOWER |M_XXX1|M_PYNV|
* | | | Alt | | Ctl | | BkSP | Del |LOWER | | |
* `----------------------------------' `----------------------------------'
* ,-------------. ,-------------.
* | Up | Down | | Left | Right|
@ -41,10 +41,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_QWERTY] = LAYOUT_ergodox_wrapper(
// LEFT HAND
_____________________NUM_LEFT_______________________, KC_MPLY,
_____________________QWERTY_L1______________________, KC_NO,
_____________________QWERTY_L1______________________, XXXXXXX,
_____________________QWERTY_L2______________________,
_____________________QWERTY_L3______________________, T_LBRC,
M_SHFT, KC_NO, ________MOD_LEFT_________,
XXXXXXX, XXXXXXX, ________MOD_LEFT_________,
// LEFT THUMB
KC_UP, KC_DOWN,
KC_HOME,
@ -53,10 +53,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
//RIGHT HAND
K_LOCK, _____________________NUM_RIGHT______________________,
KC_NO, _____________________QWERTY_R1______________________,
XXXXXXX,_____________________QWERTY_R1______________________,
_____________________QWERTY_R2______________________,
T_RBRC, _____________________QWERTY_R3______________________,
________MOD_RIGHT________, M_XXX1, M_PYNV,
________MOD_RIGHT________, XXXXXXX, XXXXXXX,
// RIGHT THUMB
KC_LEFT, KC_RGHT,
KC_PGUP,
@ -75,7 +75,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* |--------+------+------+------+------+------| [ | | ] |------+------+------+------+------+--------|
* | LShift | ; | Q | J | K | X | | | | B | M | W | V | Z | = |
* `--------+------+------+------+------+-------------' `--------------+------+------+------+------+--------'
* |M_SHFT| | Alt | | Ctl | | BkSP | Del |LOWER |M_XXX1|M_PYNV|
* | | | Alt | | Ctl | | BkSP | Del |LOWER | | |
* `----------------------------------' `----------------------------------'
* ,-------------. ,-------------.
* | Up | Down | | Left | Right|
@ -88,10 +88,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_DVORAK] = LAYOUT_ergodox_wrapper(
// LEFT HAND
_____________________NUM_LEFT_______________________, KC_MPLY,
_____________________DVORAK_L1______________________, KC_NO,
_____________________DVORAK_L1______________________, XXXXXXX,
_____________________DVORAK_L2______________________,
_____________________DVORAK_L3______________________, T_LBRC,
M_SHFT, KC_NO, ________MOD_LEFT_________,
XXXXXXX, XXXXXXX, ________MOD_LEFT_________,
// LEFT THUMB
KC_UP, KC_DOWN,
KC_HOME,
@ -100,10 +100,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
//RIGHT HAND
K_LOCK, _____________________NUM_RIGHT______________________,
KC_NO, _____________________DVORAK_R1______________________,
XXXXXXX,_____________________DVORAK_R1______________________,
_____________________DVORAK_R2______________________,
T_RBRC, _____________________DVORAK_R3______________________,
________MOD_RIGHT________, M_XXX1, M_PYNV,
________MOD_RIGHT________, XXXXXXX, XXXXXXX,
// RIGHT THUMB
KC_LEFT, KC_RGHT,
KC_PGUP,
@ -122,7 +122,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* |--------+------+------+------+------+------| [ | | ] |------+------+------+------+------+--------|
* | LShift | Z | X | C | V | B | | | | K | M | , | . | / | = |
* `--------+------+------+------+------+-------------' `--------------+------+------+------+------+--------'
* |M_SHFT| | Alt | | Ctl | | BkSP | Del |LOWER |M_XXX1|M_PYNV|
* | | | Alt | | Ctl | | BkSP | Del |LOWER | | |
* `----------------------------------' `----------------------------------'
* ,-------------. ,-------------.
* | Up | Down | | Left | Right|
@ -135,10 +135,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_COLEMAK] = LAYOUT_ergodox_wrapper(
// LEFT HAND
_____________________NUM_LEFT_______________________, KC_MPLY,
_____________________COLEMAK_L1_____________________, KC_NO,
_____________________COLEMAK_L1_____________________, XXXXXXX,
_____________________COLEMAK_L2_____________________,
_____________________COLEMAK_L3_____________________, T_LBRC,
M_SHFT, KC_NO, ________MOD_LEFT_________,
XXXXXXX, XXXXXXX, ________MOD_LEFT_________,
// LEFT THUMB
KC_UP, KC_DOWN,
KC_HOME,
@ -147,10 +147,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
//RIGHT HAND
K_LOCK, _____________________NUM_RIGHT______________________,
KC_NO, _____________________COLEMAK_R1_____________________,
XXXXXXX,_____________________COLEMAK_R1_____________________,
_____________________COLEMAK_R2_____________________,
T_RBRC, _____________________COLEMAK_R3_____________________,
________MOD_RIGHT________, M_XXX1, M_PYNV,
________MOD_RIGHT________, XXXXXXX, XXXXXXX,
// RIGHT THUMB
KC_LEFT, KC_RGHT,
KC_PGUP,
@ -163,11 +163,11 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* ,--------------------------------------------------. ,----------------------------------------------------.
* | F11 | F1 | F2 | F3 | F4 | F5 | | | | F6 | F7 | F8 | F9 | F10 | F12 |
* |--------+------+------+------+------+-------------| |-------+------+------+------+------+-------+--------|
* | | | |KC_BRU| Play | Mute | | | | PgUp | Home | Up | End | | |
* | | |KC_BRU| Play | Mute | | | | | PgUp | Home | Up | End | | |
* |--------+------+------+------+------+------| | | |------+------+------+------+-------+--------|
* | | | |KC_BRD| Next |VolUp |------| |-------| PgDn | Left | Down |Right |K_LOCK | |
* | | |KC_BRD| Next |VolUp | |------| |-------| PgDn | Left | Down |Right |K_LOCK | |
* |--------+------+------+------+------+------| | | |------+------+------+------+-------+--------|
* | | | | | Prev |VolDn | | | | | | | | | |
* | | | | Prev |VolDn | | | | | | | | | | |
* `--------+------+------+------+------+-------------' `--------------+------+------+------+-------+--------'
* | | | | | | | | | |M_CODE | |
* `----------------------------------' `-----------------------------------'
@ -182,9 +182,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_LOWER] = LAYOUT_ergodox_wrapper(
//LEFT HAND
_____________________FUNC_LEFT______________________, _______,
_______, _______, _______, _________MEDIA_1_________, _______,
_______, _______, _______, _________MEDIA_2_________,
_______, _______, _______, _________MEDIA_3_________, _______,
_____________________LOWER_L1_______________________, _______,
_____________________LOWER_L2_______________________,
_____________________LOWER_L3_______________________, _______,
_______, _______, _______, _______, _______,
// LEFT THUMB
_______, _______,
@ -194,9 +194,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
//RIGHT HAND
_______, _____________________FUNC_RIGHT_____________________,
_______, _______________NAV_1______________, _______, _______,
_______________NAV_2______________, K_LOCK, _______,
_______, _______, _______, _______, _______, _______, _______,
_______, _____________________LOWER_R1_______________________,
_____________________LOWER_R2_______________________,
_______, _____________________LOWER_R3_______________________,
_______, _______, _______, M_CODE, _______,
// RIGHT THUMB
_______, _______,
@ -208,7 +208,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* RAISE
*
* ,--------------------------------------------------. ,----------------------------------------------------.
* | | | | |K_CSCN| | | | | | | | | | |
* | | | | | | | | | | | | | | | |
* |--------+------+------+------+------+-------------| |-------+------+------+------+------+-------+--------|
* | | | MS_1 | MS_U | MS_2 | WH_U | | | | | | | | | |
* |--------+------+------+------+------+------| | | |------+------+------+------+-------+--------|
@ -228,7 +228,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
*/
[_RAISE] = LAYOUT_ergodox_wrapper(
//LEFT HAND
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, K_CSCN, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, _____________MOUSE_1______________, XXXXXXX,
XXXXXXX, XXXXXXX, _____________MOUSE_2______________,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
@ -255,11 +255,11 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* ADJUST
*
* ,--------------------------------------------------. ,----------------------------------------------------.
* | | | | | | | | | | | | |COLMAK|DVORAK |QWERTY |
* | | | | | | | | | | | | | | | |
* |--------+------+------+------+------+-------------| |-------+------+------+------+------+-------+--------|
* | M_MAKE | | | | | | | | | | | | | | |
* | M_MAKE |RESET | | | | | | | | | | |COLMAK|DVORAK |QWERTY |
* |--------+------+------+------+------+------| | | |------+------+------+------+-------+--------|
* | M_VRSN | | | | | |------| |-------| | | | | | |
* | M_VRSN |M_MALL| | | | |------| |-------| | | | | | |
* |--------+------+------+------+------+------| | | |------+------+------+------+-------+--------|
* | M_FLSH | | | | | | | | | | | | | | |
* `--------+------+------+------+------+-------------' `--------------+------+------+------+-------+--------'
@ -276,9 +276,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_ADJUST] = LAYOUT_ergodox_wrapper(
//LEFT HAND
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
M_MAKE, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
M_VRSN, M_MALL, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
M_FLSH, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
_____________________ADJUST_L1______________________, XXXXXXX,
_____________________ADJUST_L1______________________,
_____________________ADJUST_L1______________________, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
// LEFT THUMB
_______, _______,
@ -287,10 +287,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
_______,
//RIGHT HAND
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, COLEMAK, DVORAK, QWERTY,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, _____________________ADJUST_R1______________________,
_____________________ADJUST_R1______________________,
XXXXXXX, _____________________ADJUST_R1______________________,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
// RIGHT THUMB
_______, _______,

View file

@ -0,0 +1 @@
LINK_TIME_OPTIMIZATION_ENABLE = yes

View file

@ -0,0 +1,41 @@
/* Copyright 2020 ninjonas
*
* 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
#define TAPPING_TERM 200
#ifdef OLED_DRIVER_ENABLE
#define OLED_DISPLAY_128X64
#define OLED_TIMEOUT 30000
#endif
#ifdef RGBLIGHT_ENABLE
# define RGBLIGHT_SLEEP
# define RGBLIGHT_LIMIT_VAL 200
# define RGBLIGHT_HUE_STEP 8
# define RGBLIGHT_SAT_STEP 8
# define RGBLIGHT_VAL_STEP 8
# define RGBLIGHT_SPLIT
#endif
// Allows to use either side as the master. Look at the documentation for info:
// https://docs.qmk.fm/#/config_options?id=setting-handedness
#define EE_HANDS
// If you are using an Elite C rev3 on the slave side, uncomment the lines below:
#define SPLIT_USB_DETECT
#define SPLIT_USB_TIMEOUT 1000

View file

@ -0,0 +1,315 @@
/* Copyright 2020 ninjonas
*
* 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 "ninjonas.h"
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_QWERTY] = LAYOUT_wrapper(
// ,------—————————-------------------------------------. ,--------—————————-----------------------------------.
_____________________QWERTY_L1______________________, _____________________QWERTY_R1______________________,
// |--------+-----——-+——------+-——-----+——------+——-----| |------—+——------+——------+——------+——------+--------|
_____________________QWERTY_L2______________________, _____________________QWERTY_R2______________________,
// |--------+-----——-+——------+-——-----+——------+——-----+———-----------. ,——————————————+------—+——------+——------+——------+——------+--------|
_____________________QWERTY_L3______________________,XXXXXXX,KC_LALT, M_COPA,XXXXXXX,_____________________QWERTY_R3______________________,
// `--------------------------+--------+--------+-------+-------+------| |------+-------+-------+--------+--------+--------+--------+--------'
_____________MOD_LEFT_____________,T_LBRC, T_RBRC,________MOD_RIGHT________,KC_MUTE
// `----------------------------------------' `----------------------------------------'
),
[_DVORAK] = LAYOUT_wrapper(
// ,------—————————-------------------------------------. ,--------—————————-----------------------------------.
_____________________DVORAK_L1______________________, _____________________DVORAK_R1______________________,
// |--------+-----——-+——------+-——-----+——------+——-----| |------—+——------+——------+——------+——------+--------|
_____________________DVORAK_L2______________________, _____________________DVORAK_R2______________________,
// |--------+-----——-+——------+-——-----+——------+——-----+———-----------. ,——————————————+------—+——------+——------+——------+——------+--------|
_____________________DVORAK_L3______________________,XXXXXXX,KC_LALT, M_COPA,XXXXXXX,_____________________DVORAK_R3______________________,
// `--------------------------+--------+--------+-------+-------+------| |------+-------+-------+--------+--------+--------+--------+--------'
_____________MOD_LEFT_____________,T_LBRC, T_RBRC,________MOD_RIGHT________,KC_MUTE
// `----------------------------------------' `----------------------------------------'
),
[_COLEMAK] = LAYOUT_wrapper(
// ,------—————————-------------------------------------. ,--------—————————-----------------------------------.
_____________________COLEMAK_L1_____________________, _____________________COLEMAK_R1_____________________,
// |--------+-----——-+——------+-——-----+——------+——-----| |------—+——------+——------+——------+——------+--------|
_____________________COLEMAK_L2_____________________, _____________________COLEMAK_R2_____________________,
// |--------+-----——-+——------+-——-----+——------+——-----+———-----------. ,——————————————+------—+——------+——------+——------+——------+--------|
_____________________COLEMAK_L3_____________________,XXXXXXX,KC_LALT, M_COPA,XXXXXXX,_____________________COLEMAK_R3_____________________,
// `--------------------------+--------+--------+-------+-------+------| |------+-------+-------+--------+--------+--------+--------+--------'
_____________MOD_LEFT_____________,T_LBRC, T_RBRC,________MOD_RIGHT________,KC_MUTE
// `----------------------------------------' `----------------------------------------'
),
[_LOWER] = LAYOUT_wrapper(
// ,------—————————-------------------------------------. ,--------—————————-----------------------------------.
_____________________LOWER_L1_______________________, _____________________LOWER_R1_______________________,
// |--------+-----——-+——------+-——-----+——------+——-----| |------—+——------+——------+——------+——------+--------|
_____________________LOWER_L2_______________________, _____________________LOWER_R2_______________________,
// |--------+-----——-+——------+-——-----+——------+——-----+———-----------. ,——————————————+------—+——------+——------+——------+——------+--------|
_____________________LOWER_L3_______________________,_______,_______, _______,_______,_____________________LOWER_R3_______________________,
// `--------------------------+--------+--------+-------+-------+------| |------+-------+-------+--------+--------+--------+--------+--------'
_______,_______,_______,_______,_______, _______,_______,_______,_______,_______
// `----------------------------------------' `----------------------------------------'
),
[_RAISE] = LAYOUT_wrapper(
// ,------—————————-------------------------------------. ,--------—————————-----------------------------------.
_____________________NUM_LEFT_______________________, _____________________NUM_RIGHT______________________,
// |--------+-----——-+——------+-——-----+——------+——-----| |------—+——------+——------+——------+——------+--------|
_____________________SYM_LEFT_______________________, _____________________SYM_RIGHT______________________,
// |--------+-----——-+——------+-——-----+——------+——-----+———-----------. ,——————————————+------—+——------+——------+——------+——------+--------|
_____________________FUNC_LEFT______________________,_______,_______, _______,_______,_____________________FUNC_RIGHT_____________________,
// `--------------------------+--------+--------+-------+-------+------| |------+-------+-------+--------+--------+--------+--------+--------'
_______,_______,_______,_______,_______, _______,_______,_______,_______,_______
// `----------------------------------------' `----------------------------------------'
),
[_ADJUST] = LAYOUT_wrapper(
// ,------—————————-------------------------------------. ,--------—————————-----------------------------------.
_____________________ADJUST_L1______________________, _____________________ADJUST_R1______________________,
// |--------+-----——-+——------+-——-----+——------+——-----| |------—+——------+——------+——------+——------+--------|
_____________________ADJUST_L2______________________, _____________________ADJUST_R2______________________,
// |--------+-----——-+——------+-——-----+——------+——-----+———-----------. ,——————————————+------—+——------+——------+——------+——------+--------|
_____________________ADJUST_L3______________________,_______,_______, _______,_______,_____________________ADJUST_R3______________________,
// `--------------------------+--------+--------+-------+-------+------| |------+-------+-------+--------+--------+--------+--------+--------'
_______,_______,_______,_______,_______, _______,_______,_______,_______,_______
// `----------------------------------------' `----------------------------------------'
),
/*
[_TEMPLATE] = LAYOUT_wrapper(
// ,------—————————-------------------------------------. ,--------—————————-----------------------------------.
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
// |--------+-----——-+——------+-——-----+——------+——-----| |------—+——------+——------+——------+——------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
// |--------+-----——-+——------+-——-----+——------+——-----+———-----------. ,——————————————+------—+——------+——------+——------+——------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX, XXXXXXX,XXXXXXX,XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
// `--------------------------+--------+--------+-------+-------+------| |------+-------+-------+--------+--------+--------+--------+--------'
XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX, XXXXXXX,XXXXXXX,XXXXXXX, XXXXXXX, XXXXXXX
// `----------------------------------------' `----------------------------------------'
),
*/
};
#ifdef OLED_DRIVER_ENABLE
oled_rotation_t oled_init_user(oled_rotation_t rotation) {
return OLED_ROTATION_180;
}
static void render_logo(void) {
static const char PROGMEM logo[] = {
// Converter: https://javl.github.io/image2cpp/
// Image Dimensions: 128x64
// Code Output Format: Plain Bytes
// Draw Mode: Vertical, 1 bit per pixel
0x00, 0x00, 0x80, 0xc0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xc0, 0xc0, 0x00, 0x00, 0xe0,
0xe0, 0xe0, 0xe0, 0x00, 0x00, 0x80, 0xe0, 0xe0, 0xe0, 0xe0, 0x80, 0x00, 0x00, 0xe0, 0xe0, 0xe0,
0xe0, 0x00, 0x60, 0xe0, 0xe0, 0xe0, 0x00, 0x00, 0x00, 0xe0, 0xe0, 0xe0, 0xe0, 0x80, 0x00, 0x00,
0xc0, 0xe0, 0xe0, 0xe0, 0x20, 0x60, 0xe0, 0xe0, 0xe0, 0xe0, 0x00, 0x00, 0x00, 0xe0, 0xe0, 0xe0,
0xe0, 0x00, 0x00, 0xc0, 0xc0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xc0, 0xc0, 0x00, 0x00, 0x00,
0x80, 0xc0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xc0, 0x80, 0x00, 0xe0, 0xe0, 0xfc, 0xfe,
0xfe, 0xfe, 0xee, 0xee, 0x0e, 0x80, 0xc0, 0xc0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xc0, 0x80,
0x00, 0x00, 0x00, 0x80, 0xc0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xe0, 0xc0, 0x80, 0x00, 0x00,
0x00, 0x00, 0x79, 0xfd, 0xfd, 0xfd, 0xec, 0xee, 0x76, 0x7f, 0xff, 0xff, 0xff, 0x80, 0x00, 0x00,
0x07, 0x3f, 0xff, 0xfc, 0xf8, 0xff, 0x7f, 0x07, 0x0f, 0x7f, 0xff, 0xf8, 0xfc, 0xff, 0x3f, 0x07,
0x00, 0x00, 0x00, 0x03, 0x1f, 0xff, 0xfe, 0xf0, 0xff, 0x7f, 0x0f, 0x07, 0x3f, 0xff, 0xfc, 0xf8,
0xff, 0x7f, 0x0f, 0x01, 0x00, 0x00, 0x01, 0x0f, 0x3f, 0xff, 0xfe, 0xf8, 0xff, 0xff, 0x1f, 0x03,
0x00, 0x00, 0x1f, 0x7f, 0x7f, 0xff, 0xf6, 0xe6, 0xe6, 0xf7, 0xf7, 0x77, 0x37, 0x17, 0x00, 0x30,
0x79, 0xfd, 0xfd, 0xfd, 0xee, 0xee, 0x76, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0xff, 0xff,
0xff, 0xff, 0x00, 0x00, 0x00, 0x3f, 0x7f, 0x7f, 0xff, 0xf1, 0xe0, 0xe0, 0xff, 0xff, 0x7f, 0x3f,
0x0e, 0x00, 0x0e, 0x3f, 0x7f, 0xff, 0xff, 0xe0, 0xe0, 0xe1, 0xff, 0x7f, 0x7f, 0x3f, 0x04, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0,
0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x0e, 0x0e, 0x0f, 0x0f, 0x07, 0x03, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x0c, 0x3c, 0xfc, 0xfc, 0xfc, 0xc0, 0x00, 0xe0, 0xfc, 0xfc, 0x7c, 0x1c, 0x00, 0xf0, 0xf8,
0xf8, 0xfc, 0xdc, 0xdc, 0xdc, 0xfc, 0xfc, 0xf8, 0xf0, 0xe0, 0x00, 0x00, 0x30, 0xb8, 0xbc, 0xbc,
0xdc, 0xdc, 0xdc, 0xfc, 0xfc, 0xf8, 0xf0, 0x00, 0x1c, 0x1c, 0xff, 0xff, 0xff, 0xff, 0x1d, 0x1d,
0x00, 0xf0, 0xf8, 0xf8, 0xfc, 0x3c, 0x1c, 0x1c, 0xfc, 0xfc, 0xf8, 0xf0, 0xc0, 0x00, 0xe0, 0xf0,
0xf8, 0xfc, 0x3c, 0x1c, 0x1c, 0x3c, 0xfc, 0xf8, 0xf8, 0xe0, 0x00, 0x00, 0x20, 0xb8, 0xbc, 0xbc,
0xbc, 0xdc, 0xdc, 0xfc, 0xfc, 0xfc, 0xf8, 0xe0, 0x00, 0x0c, 0x7c, 0xfc, 0xfc, 0xc0, 0x00, 0xe0,
0xfc, 0xfc, 0xfc, 0xfc, 0xf0, 0x80, 0x00, 0xf8, 0xfc, 0xfc, 0x3c, 0x04, 0x0c, 0x7c, 0xfc, 0xfc,
0xf0, 0x00, 0xc0, 0xfc, 0xfc, 0x7c, 0xfc, 0xf8, 0xc0, 0x00, 0xf0, 0xfc, 0xfc, 0x7c, 0x0c, 0x00,
0x00, 0x00, 0xc0, 0xc1, 0xc7, 0xff, 0xff, 0xff, 0x7f, 0x1f, 0x03, 0x00, 0x00, 0x00, 0x07, 0x0f,
0x1f, 0x1f, 0x1e, 0x1c, 0x1c, 0x1e, 0x1e, 0x0e, 0x06, 0x00, 0x00, 0x06, 0x0f, 0x1f, 0x1f, 0x1f,
0x1d, 0x1d, 0x0e, 0x1f, 0x1f, 0x1f, 0x1f, 0x00, 0x00, 0x00, 0x1f, 0x1f, 0x1f, 0x1f, 0x00, 0x00,
0x00, 0x07, 0x0f, 0x0f, 0x1f, 0x1e, 0x1c, 0x1c, 0x1f, 0x1f, 0x0f, 0x07, 0x01, 0x00, 0x03, 0x07,
0x0f, 0x1f, 0x1e, 0x1c, 0x1c, 0x1e, 0x1f, 0x0f, 0x0f, 0x03, 0x00, 0x00, 0x0f, 0x1f, 0x1f, 0x1f,
0x1d, 0x1d, 0x0c, 0x0f, 0x1f, 0x1f, 0x1f, 0x1f, 0x00, 0x00, 0x00, 0x03, 0x1f, 0x1f, 0x1e, 0x1f,
0x0f, 0x01, 0x00, 0x07, 0x1f, 0x1f, 0x1f, 0x1f, 0x0f, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x0f,
0x1f, 0x1e, 0x1f, 0x1f, 0x03, 0x00, 0x03, 0x1f, 0x1f, 0x1e, 0x1f, 0x0f, 0x01, 0x00, 0x00, 0x00,
0x00, 0x80, 0xc1, 0xf1, 0xf9, 0xf9, 0xf9, 0xb8, 0xb8, 0x00, 0x00, 0x00, 0x80, 0x80, 0x80, 0x80,
0x80, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00,
0x00, 0x00, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00,
0x80, 0x80, 0x80, 0x80, 0x00, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x80, 0x80, 0x80, 0x80,
0x00, 0x00, 0x00, 0x00, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00,
0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00,
0x00, 0x03, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x03, 0x7c, 0xfe, 0xff, 0xff, 0xc7, 0x83, 0x83,
0xc7, 0xff, 0xff, 0xff, 0x7c, 0x00, 0x00, 0x7c, 0xff, 0xff, 0xff, 0xc7, 0x83, 0x83, 0xc7, 0xff,
0xff, 0xfe, 0x7c, 0x00, 0xc0, 0xe6, 0xf7, 0xf7, 0xf7, 0xbb, 0xbb, 0xdb, 0xff, 0xff, 0xff, 0xfe,
0x00, 0x00, 0x03, 0x1f, 0xff, 0xff, 0xf0, 0xe0, 0xfe, 0xff, 0x1f, 0x3f, 0xff, 0xfe, 0xe0, 0xf0,
0xff, 0xff, 0x1f, 0x03, 0x00, 0x01, 0x0f, 0x7f, 0xff, 0xf8, 0xc0, 0xfc, 0xff, 0x3f, 0x1f, 0xff,
0xfe, 0xf0, 0xe0, 0xff, 0xff, 0x3f, 0x07, 0x00, 0x01, 0x07, 0x3f, 0xff, 0xff, 0xf8, 0xe0, 0xfc,
0xff, 0x7f, 0x0f, 0x03, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xdb, 0x9b, 0x9b, 0xdf, 0xdf, 0xdf, 0xde,
0x1c, 0x00, 0xc0, 0xe6, 0xf7, 0xf7, 0xf7, 0xbb, 0xbb, 0xdb, 0xff, 0xff, 0xff, 0xfe, 0x00, 0x00,
0x00, 0x00, 0x03, 0x03, 0x03, 0x03, 0x03, 0x00, 0x00, 0x00, 0x00, 0x01, 0x03, 0x03, 0x03, 0x03,
0x03, 0x03, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03,
0x01, 0x00, 0x00, 0x00, 0x00, 0x01, 0x03, 0x03, 0x03, 0x03, 0x03, 0x01, 0x03, 0x03, 0x03, 0x03,
0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x03, 0x03, 0x03, 0x01, 0x00, 0x00, 0x01, 0x03, 0x03, 0x03,
0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x03, 0x03, 0x03, 0x01, 0x00, 0x00, 0x00,
0x03, 0x03, 0x03, 0x03, 0x01, 0x00, 0x00, 0x00, 0x00, 0x38, 0x38, 0x38, 0x3f, 0x3f, 0x1f, 0x0f,
0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x01, 0x00,
0x00, 0x00, 0x00, 0x01, 0x03, 0x03, 0x03, 0x03, 0x03, 0x01, 0x03, 0x03, 0x03, 0x03, 0x00, 0x00
};
oled_write_raw_P(logo, sizeof(logo));
}
static void render_qmk_logo(void) {
static const char PROGMEM qmk_logo[] = {
0x80,0x81,0x82,0x83,0x84,0x85,0x86,0x87,0x88,0x89,0x8a,0x8b,0x8c,0x8d,0x8e,0x8f,0x90,0x91,0x92,0x93,0x94,
0xa0,0xa1,0xa2,0xa3,0xa4,0xa5,0xa6,0xa7,0xa8,0xa9,0xaa,0xab,0xac,0xad,0xae,0xaf,0xb0,0xb1,0xb2,0xb3,0xb4,
0xc0,0xc1,0xc2,0xc3,0xc4,0xc5,0xc6,0xc7,0xc8,0xc9,0xca,0xcb,0xcc,0xcd,0xce,0xcf,0xd0,0xd1,0xd2,0xd3,0xd4,0};
oled_write_P(qmk_logo, false);
}
void oled_white_space(void){
oled_write_P(PSTR(" "), false);
}
static void render_status(void) {
oled_write_P(PSTR("\nLayer: "), false);
oled_write_P(PSTR("LOW"), (layer_state_is(_LOWER) & !layer_state_is(_ADJUST)));
oled_white_space();
oled_write_P(PSTR("RAI"), (layer_state_is(_RAISE) & !layer_state_is(_ADJUST)));
oled_white_space();
oled_write_P(PSTR("ADJ"), layer_state_is(_ADJUST));
}
void render_default_layer_state(void) {
oled_write_P(PSTR("\nLayout: "), false);
switch (biton32(default_layer_state)) {
case _COLEMAK:
oled_write_P(PSTR("Colemak"), false);
break;
case _DVORAK:
oled_write_P(PSTR("Dvorak"), false);
break;
case _QWERTY:
oled_write_P(PSTR("Qwerty"), false);
break;
default:
oled_write_ln_P(PSTR("Undefined"), false);
}
}
void render_mod_status(uint8_t modifiers) {
oled_write_P(PSTR("\nMods: "), false);
oled_write_P(PSTR("SHF"), (modifiers & MOD_MASK_SHIFT));
oled_white_space();
oled_write_P(PSTR("CTL"), (modifiers & MOD_MASK_CTRL));
oled_white_space();
oled_write_P(PSTR("ALT"), (modifiers & MOD_MASK_ALT));
oled_white_space();
oled_write_P(PSTR("GUI"), (modifiers & MOD_MASK_GUI));
}
void oled_task_user(void) {
if (is_keyboard_master()) {
render_qmk_logo();
render_default_layer_state();
render_status();
render_mod_status(get_mods()|get_oneshot_mods());
} else {
render_logo();
oled_scroll_left();
}
}
#endif
#ifdef ENCODER_ENABLE
void encoder_update_user(uint8_t index, bool clockwise) {
if (index == 0) {
switch (biton32(layer_state)) {
case _LOWER:
if (clockwise) {
tap_code16(SGUI(KC_TAB));
} else {
tap_code16(LGUI(KC_TAB));
}
break;
case _RAISE:
if (clockwise) {
tap_code(KC_PGUP);
} else {
tap_code(KC_PGDN);
}
break;
case _ADJUST:
if (clockwise) {
rgblight_increase_hue();
} else {
rgblight_decrease_hue();
}
break;
default:
if (clockwise) {
tap_code(KC_BRIU);
} else {
tap_code(KC_BRID);
}
break;
}
} else if (index == 1) {
switch (biton32(layer_state)) {
case _LOWER:
if (!clockwise) {
tap_code(KC_UP);
} else {
tap_code(KC_DOWN);
}
break;
case _RAISE:
if (!clockwise) {
tap_code16(LCTL(KC_TAB));
} else {
tap_code16(LCTL(LSFT(KC_TAB)));
}
break;
case _ADJUST:
if (!clockwise) {
rgblight_increase_val();
} else {
rgblight_decrease_val();
}
break;
default:
if (!clockwise) {
tap_code(KC_VOLU);
} else {
tap_code(KC_VOLD);
}
break;
}
}
}
#endif

View file

@ -0,0 +1,4 @@
OLED_DRIVER_ENABLE = yes # Enables the use of OLED displays
ENCODER_ENABLE = yes # Enables the use of one or more encoders
RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow
LINK_TIME_OPTIMIZATION_ENABLE = yes

View file

@ -37,7 +37,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
_____________________QWERTY_L1______________________, _____________________QWERTY_R1______________________, \
_____________________QWERTY_L2______________________, _____________________QWERTY_R2______________________, \
_____________________QWERTY_L3______________________, T_LBRC, T_RBRC, _____________________QWERTY_R3______________________, \
________MOD_LEFT_________, LT_RAI, LT_LOW, ________MOD_RIGHT________ \
_____________MOD_LEFT_____________, _____________MOD_RIGHT____________ \
),
/* DVORAK
@ -59,7 +59,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
_____________________DVORAK_L1______________________, _____________________DVORAK_R1______________________, \
_____________________DVORAK_L2______________________, _____________________DVORAK_R2______________________, \
_____________________DVORAK_L3______________________, T_LBRC, T_RBRC, _____________________DVORAK_R3______________________, \
________MOD_LEFT_________, LT_RAI, LT_LOW, ________MOD_RIGHT________ \
_____________MOD_LEFT_____________, _____________MOD_RIGHT____________ \
),
/* COLEMAK
@ -81,7 +81,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
_____________________COLEMAK_L1_____________________, _____________________COLEMAK_R1_____________________, \
_____________________COLEMAK_L2_____________________, _____________________COLEMAK_R2_____________________, \
_____________________COLEMAK_L3_____________________, T_LBRC, T_RBRC, _____________________COLEMAK_R3_____________________, \
________MOD_LEFT_________, LT_RAI, LT_LOW, ________MOD_RIGHT________ \
_____________MOD_LEFT_____________, _____________MOD_RIGHT____________ \
),
/* LOWER

View file

@ -14,6 +14,7 @@ See: https://docs.qmk.fm/#/feature_userspace
- [Hotdox](../../keyboards/hotdox/keymaps/ninjonas)
- [Pinky3](../../keyboards/pinky/3/keymaps/ninjonas)
- [Lily58](../../keyboards/lily58/keymaps/ninjonas)
- [Kyria](../../keyboards/kyria/keymaps/ninjonas)
## Features
### [Keys](ninjonas.h#L37)
@ -33,6 +34,8 @@ See: https://docs.qmk.fm/#/feature_userspace
|LT_LOW + LT_RAI | Hold for ADJUST |
|LM_LOW | Dedicated key to momentarily toggle to use LOWER layer |
|LM_RAI | Dedicated key to momentarily toggle to use RAISE layer |
|LG_LOW | Press to toggle LOWER layer |
|LG_RAI | Press to toggle RAISE layer |
### [Mod-Taps](ninjonas.h#L50)
|Code | Description |
@ -59,13 +62,15 @@ Predefined keyboard layout templates to speed up configuring split keyboards
### [Macros](process_records.c)
|Code | Description |
|---|---|
|M_PYNV | macro to activate pyenv with the name `jira` |
|M_MAKE | macro to send QMK make command to compile keyboard |
|M_FLSH | macro to send QMK make command to compile keyboard with the correct bootloader |
|M_VRSN | macro to send QMK version |
|M_PYNV | Macro to activate pyenv with the name `jira` |
|M_MAKE | Macro to send QMK make command to compile keyboard |
|M_MALL | Macro to send QMK make command to all [ninjonas](#Supported%20Keyboards) keyboards |
|M_FLSH | Macro to send QMK make command to compile keyboard with the correct bootloader |
|M_VRSN | Macro to send QMK version |
|M_SHFT | Sends  + alt + shift to a keycode to activate [ShiftIt](https://github.com/fikovnik/ShiftIt) |
|M_CODE | Opens [Visual Studio Code](https://code.visualstudio.com/) on current directory |
|M_TERM | Launches Spotlight and calls Terminal |
|M_COPA | Single key copy/paste |
|M_XXX1 to M_XXX5 | Reserved for secret macros see [Secrets](#secrets) |
### [Tap-Dance](tap_dances.h)

View file

@ -44,6 +44,8 @@
// Layer Keys
#define LM_LOW MO(_LOWER)
#define LM_RAI MO(_RAISE)
#define LG_LOW TG(_LOWER)
#define LG_RAI TG(_RAISE)
#define LT_LOW LT(_LOWER, KC_ENT)
#define LT_RAI LT(_RAISE, KC_SPC)
@ -52,7 +54,7 @@
#define MT_EQL MT(MOD_LALT | MOD_LSFT, KC_EQL)
// Layout blocks
#define _____________________QWERTY_L1______________________ T_TAB, T_Q, T_W, KC_E, KC_R, KC_T
#define _____________________QWERTY_L1______________________ T_TAB, T_Q, KC_W, KC_E, KC_R, KC_T
#define _____________________QWERTY_L2______________________ T_ESC, KC_A, KC_S, KC_D, KC_F, KC_G
#define _____________________QWERTY_L3______________________ KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B
@ -62,13 +64,13 @@
#define _____________________DVORAK_L1______________________ T_TAB, KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y
#define _____________________DVORAK_L2______________________ T_ESC, KC_A, KC_O, KC_E, KC_U, KC_I
#define _____________________DVORAK_L3______________________ KC_LSFT, KC_SCLN, T_Q, KC_J, KC_K, KC_X
#define _____________________DVORAK_L3______________________ KC_LSFT, KC_SCLN, KC_Q, KC_J, KC_K, KC_X
#define _____________________DVORAK_R1______________________ KC_F, KC_G, KC_C, KC_R, KC_L, KC_BSLS
#define _____________________DVORAK_R2______________________ KC_D, KC_H, KC_T, KC_N, KC_S, KC_SLSH
#define _____________________DVORAK_R3______________________ KC_B, KC_M, T_W, KC_V, KC_Z, MT_EQL
#define _____________________DVORAK_R3______________________ KC_B, KC_M, KC_W, KC_V, KC_Z, MT_EQL
#define _____________________COLEMAK_L1_____________________ T_TAB, T_Q, T_W, KC_F, KC_P, KC_G
#define _____________________COLEMAK_L1_____________________ T_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G
#define _____________________COLEMAK_L2_____________________ T_ESC, KC_A, KC_R, KC_S, KC_T, KC_D
#define _____________________COLEMAK_L3_____________________ KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B
@ -94,7 +96,8 @@
#define _____________________LOWER_R3_______________________ T_RBRC, KC_M, M_TERM, M_CODE, M_XXX1, M_PYNV
#define _____________________ADJUST_L1______________________ M_MAKE, EEP_RST, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
#ifdef RGB_MATRIX_ENABLE
#if defined(RGB_MATRIX_ENABLE) || defined(RGBLIGHT_ENABLE)
#define _____________________ADJUST_L2______________________ M_VRSN, M_MALL, RGB_SPI, RGB_SAI, RGB_HUI, RGB_VAI
#define _____________________ADJUST_L3______________________ M_FLSH, XXXXXXX, RGB_SPD, RGB_SAD, RGB_HUD, RGB_VAD
#else
@ -102,7 +105,7 @@
#define _____________________ADJUST_L3______________________ M_FLSH, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
#endif
#ifdef RGB_MATRIX_ENABLE
#if defined(RGB_MATRIX_ENABLE) || defined(RGBLIGHT_ENABLE)
#define _____________________ADJUST_R1______________________ RGB_TOG, XXXXXXX, XXXXXXX, COLEMAK, DVORAK, QWERTY
#define _____________________ADJUST_R3______________________ RGB_MOD, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
#else
@ -119,11 +122,14 @@
#define __________________________________ _______, _______, _______, _______
#define _____________MOD_LEFT_____________ KC_LALT, T_GUI, KC_LCTL, LT_RAI
#define _____________MOD_RIGHT____________ LT_LOW, KC_BSPC, MT_DEL, LM_LOW
#define _________MEDIA_1_________ KC_BRIU, KC_MPLY, KC_MUTE
#define _________MEDIA_2_________ KC_BRID, KC_MFFD, KC__VOLUP
#define _________MEDIA_3_________ XXXXXXX, KC_MRWD, KC__VOLDOWN
#ifdef KEYBOARD_crkbd_rev1
#if defined(KEYBOARD_crkbd_rev1) || defined(KEYBOARD_kyria_rev1)
#define ________MOD_LEFT_________ T_GUI, KC_LCTL, LT_RAI
#define ________MOD_RIGHT________ LT_LOW, KC_BSPC, MT_DEL
#else

View file

@ -2,7 +2,7 @@
#include <stdio.h>
#include "ninjonas.h"
#ifdef OLED_DRIVER_ENABLE
#if defined(OLED_DRIVER_ENABLE) & !defined(KEYBOARD_kyria_rev1)
static uint32_t oled_timer = 0;
extern uint8_t is_master;
@ -38,19 +38,28 @@ void render_default_layer_state(void) {
}
}
void oled_white_space(void){
oled_write_P(PSTR(" "), false);
}
void render_layer_state(void) {
oled_write_P(PSTR("\nLayer:"), false);
oled_write_P(PSTR(" LOW"), layer_state_is(_LOWER));
oled_write_P(PSTR(" RAI"), layer_state_is(_RAISE));
oled_write_P(PSTR(" ADJ"), layer_state_is(_ADJUST));
oled_write_P(PSTR("\nLayer: "), false);
oled_write_P(PSTR("LOW"), (layer_state_is(_LOWER) & !layer_state_is(_ADJUST)));
oled_white_space();
oled_write_P(PSTR("RAI"), (layer_state_is(_RAISE) & !layer_state_is(_ADJUST)));
oled_white_space();
oled_write_P(PSTR("ADJ"), layer_state_is(_ADJUST));
}
void render_mod_status(uint8_t modifiers) {
oled_write_P(PSTR("\nMods: "), false);
oled_write_P(PSTR("SHF "), (modifiers & MOD_MASK_SHIFT));
oled_write_P(PSTR("CTL "), (modifiers & MOD_MASK_CTRL));
oled_write_P(PSTR("ALT "), (modifiers & MOD_MASK_ALT));
oled_write_P(PSTR("GUI"), (modifiers & MOD_MASK_GUI));
oled_write_P(PSTR("\nMods: "), false);
oled_write_P(PSTR("SHF"), (modifiers & MOD_MASK_SHIFT));
oled_white_space();
oled_write_P(PSTR("CTL"), (modifiers & MOD_MASK_CTRL));
oled_white_space();
oled_write_P(PSTR("ALT"), (modifiers & MOD_MASK_ALT));
oled_white_space();
oled_write_P(PSTR("GUI"), (modifiers & MOD_MASK_GUI));
}
void render_status(void){

View file

@ -1,5 +1,7 @@
#include "ninjonas.h"
uint16_t copy_paste_timer;
__attribute__((weak))
bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { return true; }
@ -44,7 +46,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
// Sends QMK make command to compile all keyboards
case M_MALL:
if (record->event.pressed) {
SEND_STRING("rm -f *.hex && rm -rf .build/ && make crkbd:ninjonas lily58:ninjonas hotdox:ninjonas pinky/3:ninjonas\n");
SEND_STRING("rm -f *.hex && rm -rf .build/ && make crkbd:ninjonas lily58:ninjonas hotdox:ninjonas pinky/3:ninjonas kyria:ninjonas\n");
}
break;
@ -90,6 +92,18 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
}
break;
// Single key copy/paste
case M_COPA:
if (record->event.pressed) {
copy_paste_timer = timer_read();
} else {
if (timer_elapsed(copy_paste_timer) > TAPPING_TERM) {
tap_code16(LGUI(KC_C)); // Hold  + C
} else {
tap_code16(LGUI(KC_V)); // Tap  + V
}
}
// BEGIN: Layer macros
case QWERTY:
if (record->event.pressed) {

View file

@ -15,6 +15,7 @@ enum custom_keycodes {
M_VRSN,
M_CODE,
M_TERM,
M_COPA,
// Secret Macros
M_XXX1,
M_XXX2,