Merge tag 'tags/0.21.0'
This commit is contained in:
@@ -1,44 +0,0 @@
|
||||
/*
|
||||
Copyright 2019 @foostan
|
||||
Copyright 2020 Drashna Jaelre <@drashna>
|
||||
|
||||
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 MATRIX_ROW_PINS \
|
||||
{ D4, C6, D7, E6 }
|
||||
|
||||
// wiring of each half
|
||||
#define MATRIX_COL_PINS \
|
||||
{ F4, F5, F6, F7, B1, B3 }
|
||||
// #define MATRIX_COL_PINS { B2, B3, B1, F7, F6, F5, F4 } //uncomment this line and comment line above if you need to reverse left-to-right key order
|
||||
|
||||
/*
|
||||
* Feature disable options
|
||||
* These options are also useful to firmware size reduction.
|
||||
*/
|
||||
|
||||
/* disable debug print */
|
||||
// #define NO_DEBUG
|
||||
|
||||
/* disable print */
|
||||
// #define NO_PRINT
|
||||
|
||||
/* disable action features */
|
||||
//#define NO_ACTION_LAYER
|
||||
//#define NO_ACTION_TAPPING
|
||||
//#define NO_ACTION_ONESHOT
|
@@ -16,20 +16,148 @@ 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 "crkbd.h"
|
||||
#include "quantum.h"
|
||||
|
||||
#ifdef SWAP_HANDS_ENABLE
|
||||
__attribute__ ((weak))
|
||||
const keypos_t PROGMEM hand_swap_config[MATRIX_ROWS][MATRIX_COLS] = {
|
||||
// Left
|
||||
{{0, 4}, {1, 4}, {2, 4}, {3, 4}, {4, 4}, {5, 4}},
|
||||
{{0, 5}, {1, 5}, {2, 5}, {3, 5}, {4, 5}, {5, 5}},
|
||||
{{0, 6}, {1, 6}, {2, 6}, {3, 6}, {4, 6}, {5, 6}},
|
||||
{{0, 7}, {1, 7}, {2, 7}, {3, 7}, {4, 7}, {5, 7}},
|
||||
// Right
|
||||
{{0, 0}, {1, 0}, {2, 0}, {3, 0}, {4, 0}, {5, 0}},
|
||||
{{0, 1}, {1, 1}, {2, 1}, {3, 1}, {4, 1}, {5, 1}},
|
||||
{{0, 2}, {1, 2}, {2, 2}, {3, 2}, {4, 2}, {5, 2}},
|
||||
{{0, 3}, {1, 3}, {2, 3}, {3, 3}, {4, 3}, {5, 3}}
|
||||
__attribute__((weak)) const keypos_t PROGMEM hand_swap_config[MATRIX_ROWS][MATRIX_COLS] = {
|
||||
// Left
|
||||
{{0, 4}, {1, 4}, {2, 4}, {3, 4}, {4, 4}, {5, 4}},
|
||||
{{0, 5}, {1, 5}, {2, 5}, {3, 5}, {4, 5}, {5, 5}},
|
||||
{{0, 6}, {1, 6}, {2, 6}, {3, 6}, {4, 6}, {5, 6}},
|
||||
{{0, 7}, {1, 7}, {2, 7}, {3, 7}, {4, 7}, {5, 7}},
|
||||
// Right
|
||||
{{0, 0}, {1, 0}, {2, 0}, {3, 0}, {4, 0}, {5, 0}},
|
||||
{{0, 1}, {1, 1}, {2, 1}, {3, 1}, {4, 1}, {5, 1}},
|
||||
{{0, 2}, {1, 2}, {2, 2}, {3, 2}, {4, 2}, {5, 2}},
|
||||
{{0, 3}, {1, 3}, {2, 3}, {3, 3}, {4, 3}, {5, 3}}
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef OLED_ENABLE
|
||||
|
||||
oled_rotation_t oled_init_kb(oled_rotation_t rotation) {
|
||||
if (!is_keyboard_master()) {
|
||||
return OLED_ROTATION_180; // flips the display 180 degrees if offhand
|
||||
}
|
||||
return rotation;
|
||||
}
|
||||
|
||||
static void oled_render_layer_state(void) {
|
||||
oled_write_P(PSTR("Layer: "), false);
|
||||
switch (get_highest_layer(layer_state)) {
|
||||
case 0:
|
||||
oled_write_ln_P(PSTR("Default"), false);
|
||||
break;
|
||||
case 1:
|
||||
oled_write_ln_P(PSTR("Lower"), false);
|
||||
break;
|
||||
case 2:
|
||||
oled_write_ln_P(PSTR("Raise"), false);
|
||||
break;
|
||||
case 3:
|
||||
oled_write_ln_P(PSTR("Adjust"), false);
|
||||
break;
|
||||
default:
|
||||
oled_write_ln_P(PSTR("Undef"), false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
char key_name = ' ';
|
||||
uint16_t last_keycode;
|
||||
uint8_t last_row;
|
||||
uint8_t last_col;
|
||||
|
||||
static const char PROGMEM code_to_name[60] = {' ', ' ', ' ', ' ', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', '1', '2', '3', '4', '5', '6', '7', '8', '9', '0', 'R', 'E', 'B', 'T', '_', '-', '=', '[', ']', '\\', '#', ';', '\'', '`', ',', '.', '/', ' ', ' ', ' '};
|
||||
|
||||
static void set_keylog(uint16_t keycode, keyrecord_t *record) {
|
||||
key_name = ' ';
|
||||
last_keycode = keycode;
|
||||
if (IS_QK_MOD_TAP(keycode)) {
|
||||
if (record->tap.count) {
|
||||
keycode = QK_MOD_TAP_GET_TAP_KEYCODE(keycode);
|
||||
} else {
|
||||
keycode = 0xE0 + biton(QK_MOD_TAP_GET_MODS(keycode) & 0xF) + biton(QK_MOD_TAP_GET_MODS(keycode) & 0x10);
|
||||
}
|
||||
} else if (IS_QK_LAYER_TAP(keycode) && record->tap.count) {
|
||||
keycode = QK_LAYER_TAP_GET_TAP_KEYCODE(keycode);
|
||||
} else if (IS_QK_MODS(keycode)) {
|
||||
keycode = QK_MODS_GET_BASIC_KEYCODE(keycode);
|
||||
} else if (IS_QK_ONE_SHOT_MOD(keycode)) {
|
||||
keycode = 0xE0 + biton(QK_ONE_SHOT_MOD_GET_MODS(keycode) & 0xF) + biton(QK_ONE_SHOT_MOD_GET_MODS(keycode) & 0x10);
|
||||
}
|
||||
if (keycode > ARRAY_SIZE(code_to_name)) {
|
||||
return;
|
||||
}
|
||||
|
||||
// update keylog
|
||||
key_name = pgm_read_byte(&code_to_name[keycode]);
|
||||
last_row = record->event.key.row;
|
||||
last_col = record->event.key.col;
|
||||
}
|
||||
|
||||
static const char *depad_str(const char *depad_str, char depad_char) {
|
||||
while (*depad_str == depad_char)
|
||||
++depad_str;
|
||||
return depad_str;
|
||||
}
|
||||
|
||||
static void oled_render_keylog(void) {
|
||||
const char *last_row_str = get_u8_str(last_row, ' ');
|
||||
oled_write(depad_str(last_row_str, ' '), false);
|
||||
oled_write_P(PSTR("x"), false);
|
||||
const char *last_col_str = get_u8_str(last_col, ' ');
|
||||
oled_write(depad_str(last_col_str, ' '), false);
|
||||
oled_write_P(PSTR(", k"), false);
|
||||
const char *last_keycode_str = get_u16_str(last_keycode, ' ');
|
||||
oled_write(depad_str(last_keycode_str, ' '), false);
|
||||
oled_write_P(PSTR(":"), false);
|
||||
oled_write_char(key_name, false);
|
||||
}
|
||||
|
||||
// static void render_bootmagic_status(bool status) {
|
||||
// /* Show Ctrl-Gui Swap options */
|
||||
// static const char PROGMEM logo[][2][3] = {
|
||||
// {{0x97, 0x98, 0}, {0xb7, 0xb8, 0}},
|
||||
// {{0x95, 0x96, 0}, {0xb5, 0xb6, 0}},
|
||||
// };
|
||||
// if (status) {
|
||||
// oled_write_ln_P(logo[0][0], false);
|
||||
// oled_write_ln_P(logo[0][1], false);
|
||||
// } else {
|
||||
// oled_write_ln_P(logo[1][0], false);
|
||||
// oled_write_ln_P(logo[1][1], false);
|
||||
// }
|
||||
// }
|
||||
|
||||
__attribute__((weak)) void oled_render_logo(void) {
|
||||
// clang-format off
|
||||
static const char PROGMEM crkbd_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};
|
||||
// clang-format on
|
||||
oled_write_P(crkbd_logo, false);
|
||||
}
|
||||
|
||||
bool oled_task_kb(void) {
|
||||
if (!oled_task_user()) {
|
||||
return false;
|
||||
}
|
||||
if (is_keyboard_master()) {
|
||||
oled_render_layer_state();
|
||||
oled_render_keylog();
|
||||
} else {
|
||||
oled_render_logo();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
bool process_record_kb(uint16_t keycode, keyrecord_t *record) {
|
||||
if (record->event.pressed) {
|
||||
set_keylog(keycode, record);
|
||||
}
|
||||
return process_record_user(keycode, record);
|
||||
}
|
||||
#endif // OLED_ENABLE
|
||||
|
@@ -1,28 +0,0 @@
|
||||
/*
|
||||
Copyright 2019 @foostan
|
||||
Copyright 2020 Drashna Jaelre <@drashna>
|
||||
|
||||
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
|
||||
|
||||
#ifdef KEYBOARD_crkbd_rev1
|
||||
# include "rev1.h"
|
||||
#endif
|
||||
#ifdef KEYBOARD_crkbd_r2g
|
||||
# include "r2g.h"
|
||||
#endif
|
||||
|
||||
|
||||
#include "quantum.h"
|
@@ -1,115 +1,35 @@
|
||||
{
|
||||
"keyboard_name": "Corne",
|
||||
"manufacturer": "foostan",
|
||||
"url": "",
|
||||
"maintainer": "qmk",
|
||||
"usb": {
|
||||
"vid": "0x4653",
|
||||
"pid": "0x0001",
|
||||
"device_version": "0.0.1"
|
||||
},
|
||||
"processor": "atmega32u4",
|
||||
"community_layouts": ["split_3x5_3", "split_3x6_3"],
|
||||
"layouts": {
|
||||
"LAYOUT_split_3x6_3": {
|
||||
"layout": [
|
||||
{"label":"Esc", "x":0, "y":0.3},
|
||||
{"label":"Q", "x":1, "y":0.3},
|
||||
{"label":"W", "x":2, "y":0.1},
|
||||
{"label":"E", "x":3, "y":0},
|
||||
{"label":"R", "x":4, "y":0.1},
|
||||
{"label":"T", "x":5, "y":0.2},
|
||||
|
||||
{"label":"Y", "x":9, "y":0.2},
|
||||
{"label":"U", "x":10, "y":0.1},
|
||||
{"label":"I", "x":11, "y":0},
|
||||
{"label":"O", "x":12, "y":0.1},
|
||||
{"label":"P", "x":13, "y":0.3},
|
||||
{"label":"Back Space", "x":14, "y":0.3},
|
||||
|
||||
{"label":"Ctrl / Tab", "x":0, "y":1.3},
|
||||
{"label":"A", "x":1, "y":1.3},
|
||||
{"label":"S", "x":2, "y":1.1},
|
||||
{"label":"D", "x":3, "y":1},
|
||||
{"label":"F", "x":4, "y":1.1},
|
||||
{"label":"G", "x":5, "y":1.2},
|
||||
|
||||
{"label":"H", "x":9, "y":1.2},
|
||||
{"label":"J", "x":10, "y":1.1},
|
||||
{"label":"K", "x":11, "y":1},
|
||||
{"label":"L", "x":12, "y":1.1},
|
||||
{"label":";", "x":13, "y":1.3},
|
||||
{"label":"'", "x":14, "y":1.3},
|
||||
|
||||
{"label":"Shift", "x":0, "y":2.3},
|
||||
{"label":"Z", "x":1, "y":2.3},
|
||||
{"label":"X", "x":2, "y":2.1},
|
||||
{"label":"C", "x":3, "y":2},
|
||||
{"label":"V", "x":4, "y":2.1},
|
||||
{"label":"B", "x":5, "y":2.2},
|
||||
|
||||
{"label":"N", "x":9, "y":2.2},
|
||||
{"label":"M", "x":10, "y":2.1},
|
||||
{"label":",", "x":11, "y":2},
|
||||
{"label":".", "x":12, "y":2.1},
|
||||
{"label":"/", "x":13, "y":2.3},
|
||||
{"label":"Shift", "x":14, "y":2.3},
|
||||
|
||||
{"label":"GUI", "x":4, "y":3.7},
|
||||
{"label":"Lower", "x":5, "y":3.7},
|
||||
{"label":"Space", "x":6, "y":3.2, "h":1.5},
|
||||
|
||||
{"label":"Enter", "x":8, "y":3.2, "h":1.5},
|
||||
{"label":"Raise", "x":9, "y":3.7},
|
||||
{"label":"Alt", "x":10, "y":3.7}
|
||||
]
|
||||
"keyboard_name": "Corne",
|
||||
"manufacturer": "foostan",
|
||||
"url": "",
|
||||
"maintainer": "qmk",
|
||||
"usb": {
|
||||
"vid": "0x4653",
|
||||
"pid": "0x0001",
|
||||
"device_version": "0.0.1"
|
||||
},
|
||||
"LAYOUT_split_3x5_3": {
|
||||
"layout": [
|
||||
{"label":"Q", "x":0, "y":0.3},
|
||||
{"label":"W", "x":1, "y":0.1},
|
||||
{"label":"E", "x":2, "y":0},
|
||||
{"label":"R", "x":3, "y":0.1},
|
||||
{"label":"T", "x":4, "y":0.2},
|
||||
|
||||
{"label":"Y", "x":8, "y":0.2},
|
||||
{"label":"U", "x":9, "y":0.1},
|
||||
{"label":"I", "x":10, "y":0},
|
||||
{"label":"O", "x":11, "y":0.1},
|
||||
{"label":"P", "x":12, "y":0.3},
|
||||
|
||||
{"label":"A", "x":0, "y":1.3},
|
||||
{"label":"S", "x":1, "y":1.1},
|
||||
{"label":"D", "x":2, "y":1},
|
||||
{"label":"F", "x":3, "y":1.1},
|
||||
{"label":"G", "x":4, "y":1.2},
|
||||
|
||||
{"label":"H", "x":8, "y":1.2},
|
||||
{"label":"J", "x":9, "y":1.1},
|
||||
{"label":"K", "x":10, "y":1},
|
||||
{"label":"L", "x":11, "y":1.1},
|
||||
{"label":";", "x":12, "y":1.3},
|
||||
|
||||
{"label":"Z", "x":0, "y":2.3},
|
||||
{"label":"X", "x":1, "y":2.1},
|
||||
{"label":"C", "x":2, "y":2},
|
||||
{"label":"V", "x":3, "y":2.1},
|
||||
{"label":"B", "x":4, "y":2.2},
|
||||
|
||||
{"label":"N", "x":8, "y":2.2},
|
||||
{"label":"M", "x":9, "y":2.1},
|
||||
{"label":",", "x":10, "y":2},
|
||||
{"label":".", "x":11, "y":2.1},
|
||||
{"label":"/", "x":12, "y":2.3},
|
||||
|
||||
{"label":"GUI", "x":3, "y":3.7},
|
||||
{"label":"Lower", "x":4, "y":3.7},
|
||||
{"label":"Space", "x":5, "y":3.2, "h":1.5},
|
||||
|
||||
{"label":"Enter", "x":7, "y":3.2, "h":1.5},
|
||||
{"label":"Raise", "x":8, "y":3.7},
|
||||
{"label":"Alt", "x":9, "y":3.7}
|
||||
]
|
||||
}
|
||||
}
|
||||
"rgb_matrix": {
|
||||
"driver": "WS2812"
|
||||
},
|
||||
"features": {
|
||||
"bootmagic": true,
|
||||
"extrakey": true,
|
||||
"lto": true,
|
||||
"mousekey": true,
|
||||
"nkro": true,
|
||||
"oled": true
|
||||
},
|
||||
"build": {
|
||||
"lto": true
|
||||
},
|
||||
"matrix_pins": {
|
||||
"cols": [ "F4", "F5", "F6", "F7", "B1", "B3" ],
|
||||
"rows": [ "D4", "C6", "D7", "E6" ]
|
||||
},
|
||||
"diode_direction": "COL2ROW",
|
||||
"split": {
|
||||
"enabled": true
|
||||
},
|
||||
"processor": "atmega32u4",
|
||||
"community_layouts": [ "split_3x5_3", "split_3x6_3" ]
|
||||
}
|
||||
|
@@ -32,6 +32,5 @@
|
||||
#endif
|
||||
|
||||
#define TAPPING_TERM 200
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
#define COMBO_TERM 30
|
||||
|
||||
|
@@ -165,11 +165,8 @@ enum combo_events {
|
||||
DELQ_COMBO,
|
||||
SAVEQ_COMBO,
|
||||
BSPCQ_COMBO,
|
||||
BSPCWQ_COMBO,
|
||||
|
||||
COMBO_LENGTH
|
||||
BSPCWQ_COMBO
|
||||
};
|
||||
uint16_t COMBO_LEN = COMBO_LENGTH;
|
||||
|
||||
const uint16_t PROGMEM ru_combo[] = {KC_R, U_CTRL, COMBO_END};
|
||||
const uint16_t PROGMEM en_combo[] = {U_CTRL, S_ALT, COMBO_END};
|
||||
@@ -216,7 +213,7 @@ combo_t key_combos[] = {
|
||||
[SAVEQ_COMBO] = COMBO(saveq_combo, VIM_SAVE),
|
||||
[BSPCWQ_COMBO] = COMBO(bspcwq_combo, DELETE_WORD),
|
||||
};
|
||||
|
||||
|
||||
|
||||
#ifdef OLED_ENABLE
|
||||
oled_rotation_t oled_init_user(oled_rotation_t rotation) {
|
||||
@@ -398,4 +395,3 @@ void matrix_scan_user(void) {
|
||||
#include "mod_tap_keys.h"
|
||||
#undef MOD_TAP_KEY
|
||||
}
|
||||
|
||||
|
@@ -34,7 +34,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#define QUICK_TAP_TERM 0
|
||||
#define TAPPING_TERM 200
|
||||
#define PERMISSIVE_HOLD
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
#define RETRO_TAPPING
|
||||
|
||||
|
||||
|
@@ -31,7 +31,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
// #define QUICK_TAP_TERM 0
|
||||
// #define PERMISSIVE_HOLD
|
||||
#define TAPPING_TERM 300
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
#undef RGBLED_NUM
|
||||
|
@@ -31,7 +31,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#define QUICK_TAP_TERM 0
|
||||
#define TAPPING_TERM 175
|
||||
#define PERMISSIVE_HOLD
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
#undef RGBLED_NUM
|
||||
|
@@ -31,7 +31,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
// #define QUICK_TAP_TERM 0
|
||||
#define TAPPING_TERM 150
|
||||
// #define RETRO_TAPPING
|
||||
// #define IGNORE_MOD_TAP_INTERRUPT
|
||||
// #define PERMISSIVE_HOLD
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
|
@@ -25,7 +25,6 @@
|
||||
#define TAPPING_FORCE_HOLD
|
||||
#define TAPPING_TERM 135
|
||||
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
#define CAPS_WORD_IDLE_TIMEOUT 5000 // Turn off Caps Word after 5 seconds.
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
|
@@ -30,7 +30,7 @@ enum layers {
|
||||
|
||||
// One shot mods
|
||||
enum keycodes {
|
||||
OS_SHFT = QK_USER,
|
||||
OS_SHFT = QK_USER,
|
||||
OS_CTRL,
|
||||
OS_ALT,
|
||||
OS_GUI,
|
||||
@@ -159,11 +159,8 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
};
|
||||
|
||||
enum combo_events {
|
||||
CAPS_COMBO,
|
||||
// Other combos...
|
||||
COMBO_LENGTH
|
||||
CAPS_COMBO
|
||||
};
|
||||
uint16_t COMBO_LEN = COMBO_LENGTH;
|
||||
|
||||
const uint16_t PROGMEM caps_combo[] = {KC_F, KC_J, COMBO_END};
|
||||
|
||||
|
@@ -29,7 +29,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#define QUICK_TAP_TERM 0
|
||||
#define TAPPING_TERM 200
|
||||
// #define RETRO_TAPPING
|
||||
// #define IGNORE_MOD_TAP_INTERRUPT
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
#define RGBLIGHT_SLEEP
|
||||
|
@@ -35,7 +35,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#define QUICK_TAP_TERM 0
|
||||
#define TAPPING_TERM 200
|
||||
// #define RETRO_TAPPING
|
||||
// #define IGNORE_MOD_TAP_INTERRUPT
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
#undef RGBLED_NUM
|
||||
|
@@ -47,5 +47,3 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#define RGBLIGHT_SAT_STEP 17
|
||||
#define RGBLIGHT_VAL_STEP 17
|
||||
#endif
|
||||
|
||||
#define OLED_FONT_H "keyboards/crkbd/lib/glcdfont.c"
|
||||
|
@@ -17,10 +17,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include QMK_KEYBOARD_H
|
||||
#include <stdio.h>
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[0] = LAYOUT_split_3x6_3(
|
||||
[0] = LAYOUT_split_3x6_3(
|
||||
//,-----------------------------------------------------. ,-----------------------------------------------------.
|
||||
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC,
|
||||
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
|
||||
@@ -33,7 +32,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
),
|
||||
|
||||
[1] = LAYOUT_split_3x6_3(
|
||||
[1] = LAYOUT_split_3x6_3(
|
||||
//,-----------------------------------------------------. ,-----------------------------------------------------.
|
||||
KC_TAB, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC,
|
||||
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
|
||||
@@ -45,7 +44,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
//`--------------------------' `--------------------------'
|
||||
),
|
||||
|
||||
[2] = LAYOUT_split_3x6_3(
|
||||
[2] = LAYOUT_split_3x6_3(
|
||||
//,-----------------------------------------------------. ,-----------------------------------------------------.
|
||||
KC_TAB, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC,
|
||||
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
|
||||
@@ -57,7 +56,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
//`--------------------------' `--------------------------'
|
||||
),
|
||||
|
||||
[3] = LAYOUT_split_3x6_3(
|
||||
[3] = LAYOUT_split_3x6_3(
|
||||
//,-----------------------------------------------------. ,-----------------------------------------------------.
|
||||
QK_BOOT, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
|
||||
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
|
||||
@@ -69,108 +68,3 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
//`--------------------------' `--------------------------'
|
||||
)
|
||||
};
|
||||
|
||||
#ifdef OLED_ENABLE
|
||||
oled_rotation_t oled_init_user(oled_rotation_t rotation) {
|
||||
if (!is_keyboard_master()) {
|
||||
return OLED_ROTATION_180; // flips the display 180 degrees if offhand
|
||||
}
|
||||
return rotation;
|
||||
}
|
||||
|
||||
#define L_BASE 0
|
||||
#define L_LOWER 2
|
||||
#define L_RAISE 4
|
||||
#define L_ADJUST 8
|
||||
|
||||
void oled_render_layer_state(void) {
|
||||
oled_write_P(PSTR("Layer: "), false);
|
||||
switch (layer_state) {
|
||||
case L_BASE:
|
||||
oled_write_ln_P(PSTR("Default"), false);
|
||||
break;
|
||||
case L_LOWER:
|
||||
oled_write_ln_P(PSTR("Lower"), false);
|
||||
break;
|
||||
case L_RAISE:
|
||||
oled_write_ln_P(PSTR("Raise"), false);
|
||||
break;
|
||||
case L_ADJUST:
|
||||
case L_ADJUST|L_LOWER:
|
||||
case L_ADJUST|L_RAISE:
|
||||
case L_ADJUST|L_LOWER|L_RAISE:
|
||||
oled_write_ln_P(PSTR("Adjust"), false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
char keylog_str[24] = {};
|
||||
|
||||
const char code_to_name[60] = {
|
||||
' ', ' ', ' ', ' ', 'a', 'b', 'c', 'd', 'e', 'f',
|
||||
'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p',
|
||||
'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z',
|
||||
'1', '2', '3', '4', '5', '6', '7', '8', '9', '0',
|
||||
'R', 'E', 'B', 'T', '_', '-', '=', '[', ']', '\\',
|
||||
'#', ';', '\'', '`', ',', '.', '/', ' ', ' ', ' '};
|
||||
|
||||
void set_keylog(uint16_t keycode, keyrecord_t *record) {
|
||||
char name = ' ';
|
||||
if ((keycode >= QK_MOD_TAP && keycode <= QK_MOD_TAP_MAX) ||
|
||||
(keycode >= QK_LAYER_TAP && keycode <= QK_LAYER_TAP_MAX)) { keycode = keycode & 0xFF; }
|
||||
if (keycode < 60) {
|
||||
name = code_to_name[keycode];
|
||||
}
|
||||
|
||||
// update keylog
|
||||
snprintf(keylog_str, sizeof(keylog_str), "%dx%d, k%2d : %c",
|
||||
record->event.key.row, record->event.key.col,
|
||||
keycode, name);
|
||||
}
|
||||
|
||||
void oled_render_keylog(void) {
|
||||
oled_write(keylog_str, false);
|
||||
}
|
||||
|
||||
void render_bootmagic_status(bool status) {
|
||||
/* Show Ctrl-Gui Swap options */
|
||||
static const char PROGMEM logo[][2][3] = {
|
||||
{{0x97, 0x98, 0}, {0xb7, 0xb8, 0}},
|
||||
{{0x95, 0x96, 0}, {0xb5, 0xb6, 0}},
|
||||
};
|
||||
if (status) {
|
||||
oled_write_ln_P(logo[0][0], false);
|
||||
oled_write_ln_P(logo[0][1], false);
|
||||
} else {
|
||||
oled_write_ln_P(logo[1][0], false);
|
||||
oled_write_ln_P(logo[1][1], false);
|
||||
}
|
||||
}
|
||||
|
||||
void oled_render_logo(void) {
|
||||
static const char PROGMEM crkbd_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(crkbd_logo, false);
|
||||
}
|
||||
|
||||
bool oled_task_user(void) {
|
||||
if (is_keyboard_master()) {
|
||||
oled_render_layer_state();
|
||||
oled_render_keylog();
|
||||
} else {
|
||||
oled_render_logo();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
if (record->event.pressed) {
|
||||
set_keylog(keycode, record);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
#endif // OLED_ENABLE
|
||||
|
@@ -1,5 +0,0 @@
|
||||
MOUSEKEY_ENABLE = yes # Mouse keys
|
||||
RGBLIGHT_ENABLE = yes # Enable WS2812 RGB underlight.
|
||||
OLED_ENABLE = yes
|
||||
OLED_DRIVER = SSD1306
|
||||
LTO_ENABLE = yes
|
@@ -10,7 +10,6 @@
|
||||
|
||||
// #define QUICK_TAP_TERM 0
|
||||
#define TAPPING_TERM 300
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
# undef RGBLED_NUM
|
||||
|
@@ -3,7 +3,6 @@
|
||||
#define EE_HANDS
|
||||
#define SPLIT_USB_DETECT
|
||||
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
#define PERMISSIVE_HOLD
|
||||
#define TAPPING_TERM 250
|
||||
|
||||
|
@@ -33,7 +33,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#define TAPPING_TERM 150
|
||||
#define PERMISSIVE_HOLD
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
# undef RGBLED_NUM
|
||||
|
@@ -25,9 +25,6 @@
|
||||
// Configure the global tapping term (default: 200ms)
|
||||
#define TAPPING_TERM 500
|
||||
|
||||
// Prevent normal rollover on alphas from accidentally triggering mods.
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
|
||||
// Enable rapid switch from tap to hold, disables double tap hold auto-repeat.
|
||||
#define QUICK_TAP_TERM 0
|
||||
|
||||
|
@@ -42,15 +42,10 @@ This is the C configuration file for the keymap
|
||||
#define QMK_LED D5
|
||||
#define QMK_SPEAKER C6
|
||||
|
||||
// Prevent normal rollover on alphas from accidentally triggering mods.
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
|
||||
// When enabled, typing a mod-tap plus second within term will register as the mod-combo
|
||||
// Ref: https://beta.docs.qmk.fm/using-qmk/software-features/tap_hold#permissive-hold
|
||||
// Ref: https://beta.docs.qmk.fm/using-qmk/software-features/tap_hold#permissive-hold
|
||||
#define PERMISSIVE_HOLD
|
||||
|
||||
#define COMBO_COUNT 2
|
||||
|
||||
// Set the COMBO_TERM so low that I won't type the keys one after each other during normal typing.
|
||||
// They would have be held together intentionally to trigger this.
|
||||
#define COMBO_TERM 40
|
||||
@@ -59,4 +54,3 @@ This is the C configuration file for the keymap
|
||||
// I want a relatively low timeout, so if I accidentally type "Shift", I can pause just briefly and move on.
|
||||
#define ONESHOT_TAP_TOGGLE 3 /* Tapping this number of times holds the key until tapped once again. */
|
||||
#define ONESHOT_TIMEOUT 2000 /* Time (in ms) before the one shot key is released */
|
||||
|
||||
|
@@ -18,7 +18,7 @@ enum combos {
|
||||
const uint16_t PROGMEM df_combo[] = {KC_D, KC_F, COMBO_END};
|
||||
const uint16_t PROGMEM jk_combo[] = {KC_J, KC_K, COMBO_END};
|
||||
|
||||
combo_t key_combos[COMBO_COUNT] = {
|
||||
combo_t key_combos[] = {
|
||||
// Add commonly used dash to home row
|
||||
[DF_DASH] = COMBO(df_combo, KC_MINS),
|
||||
// For Vim, put Escape on the home row
|
||||
@@ -43,7 +43,7 @@ enum custom_layers {
|
||||
#define GUI_ENT GUI_T(KC_ENT)
|
||||
#define LOW_TAB LT(_LOWER, KC_TAB)
|
||||
#define RSE_BSP LT(_RAISE, KC_BSPC)
|
||||
#define OSM_SFT OSM(MOD_LSFT)
|
||||
#define OSM_SFT OSM(MOD_LSFT)
|
||||
|
||||
|
||||
// For _RAISE layer
|
||||
|
@@ -15,13 +15,11 @@
|
||||
|
||||
|
||||
// combo
|
||||
#define COMBO_COUNT 7
|
||||
#define EXTRA_SHORT_COMBOS
|
||||
|
||||
//Tapping values
|
||||
//#define QUICK_TAP_TERM 0
|
||||
#define TAPPING_TERM 200
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
#define PERMISSIVE_HOLD_PER_KEY
|
||||
|
||||
|
||||
@@ -69,7 +67,7 @@
|
||||
// NOTE: the below effects are super cool but they go absolutely nuts if you manually set hsv colors (eg with layers)
|
||||
|
||||
//#define ENABLE_RGB_MATRIX_TYPING_HEATMAP
|
||||
//#define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH
|
||||
//#define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH
|
||||
//#define ENABLE_RGB_MATRIX_SOLID_REACTIVE
|
||||
#endif
|
||||
|
||||
|
@@ -20,7 +20,7 @@ enum custom_key_codes {
|
||||
MOVE_END_LINE_TERMINAL, // move to the end of the line in the terminal
|
||||
/* macros */
|
||||
PASTE_VIM, // paste in vim from system register
|
||||
ACIRCLE, // å
|
||||
ACIRCLE, // å
|
||||
ADOT, // ä
|
||||
ODOT, // ö
|
||||
COMPOSE_MACRO, // compose key for mac or linux
|
||||
@@ -44,7 +44,7 @@ enum {
|
||||
#define SHOW_WINDOWS LCTL(KC_UP) //'Expose' on Mac, overview on linux. Just all the windows
|
||||
#define WINDOW_LEFT LCTL(LGUI(LSFT(KC_LEFT))) //custom shortcut for this feature -- make window take up 50% left screen (using gui and ctl to make it os agnostic)
|
||||
#define WINDOW_RIGHT LCTL(LGUI(LSFT(KC_RIGHT))) //custom shortcut for this feature -- make window take up 50% right screen (using gui and ctl to make it os agnostic)/fully custom shortcut, using ctl and gui keys so will need them both irrespective of os
|
||||
#define SHOW_APP_WINDOWS LCTL(KC_DOWN)
|
||||
#define SHOW_APP_WINDOWS LCTL(KC_DOWN)
|
||||
#define LOCK_SCREEN LCTL(LGUI(KC_Q)) //manually set this on linux to match osx default
|
||||
#define EURO LALT(LSFT(KC_2))
|
||||
#define EMOJI_KBD LCTL(LGUI(KC_SPACE)) //manually set this on linux to match osx default, with 'emote' on linux and a custom shortcut (probably better to use compose feature)
|
||||
@@ -86,7 +86,7 @@ const uint16_t PROGMEM adot_combo[] = {KC_BSPC, KC_SPACE, MT(MOD_RALT,KC_L), COM
|
||||
// combo - press combo+ ; to get ö
|
||||
const uint16_t PROGMEM odot_combo[] = {KC_BSPC, KC_SPACE, MT(MOD_LCTL,KC_SCLN),COMBO_END};
|
||||
|
||||
combo_t key_combos[COMBO_COUNT] = {
|
||||
combo_t key_combos[] = {
|
||||
COMBO(compose_combo, COMPOSE_MACRO),
|
||||
COMBO(search_combo, FINDER),
|
||||
COMBO(calculator_combo, CALCULATOR),
|
||||
@@ -113,7 +113,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_NUMS] = LAYOUT_split_3x6_3( //numbers
|
||||
//,-----------------------------------------------------. ,-----------------------------------------------------.
|
||||
SCREENSHOT, KC_EXCLAIM,KC_AT, KC_HASH, KC_DOLLAR,KC_PERCENT, KC_CIRCUMFLEX, KC_7, KC_8, KC_9, KC_TRANSPARENT, KC_PIPE,
|
||||
SCREENSHOT, KC_EXCLAIM,KC_AT, KC_HASH, KC_DOLLAR,KC_PERCENT, KC_CIRCUMFLEX, KC_7, KC_8, KC_9, KC_TRANSPARENT, KC_PIPE,
|
||||
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
|
||||
TO(_BASE), KC_LCTL, KC_LALT, KC_RSFT, KC_LGUI,KC_PLUS, KC_EQL, KC_4, KC_5, KC_6, KC_BSLS, KC_TRANSPARENT,
|
||||
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
|
||||
@@ -125,7 +125,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_NUM_MASK] = LAYOUT_split_3x6_3( //NUM MASK, so I can still have backspace/enter/tab etc but with the nums, arrows and formatters too
|
||||
//,-----------------------------------------------------. ,-----------------------------------------------------.
|
||||
KC_TRANSPARENT, KC_TRANSPARENT,KC_TRANSPARENT, KC_UP, KC_TRANSPARENT,KC_TRANSPARENT, KC_TRANSPARENT, KC_7, KC_8, KC_9, KC_TRANSPARENT, KC_TRANSPARENT,
|
||||
KC_TRANSPARENT, KC_TRANSPARENT,KC_TRANSPARENT, KC_UP, KC_TRANSPARENT,KC_TRANSPARENT, KC_TRANSPARENT, KC_7, KC_8, KC_9, KC_TRANSPARENT, KC_TRANSPARENT,
|
||||
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
|
||||
TO(_BASE), KC_TRANSPARENT, KC_LEFT, KC_DOWN, KC_RIGHT,KC_TRANSPARENT, KC_TRANSPARENT, KC_4, KC_5, KC_6, KC_TRANSPARENT, KC_TRANSPARENT,
|
||||
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
|
||||
@@ -164,7 +164,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_FN_KEYS] = LAYOUT_split_3x6_3( //fn keys, terminal text navigation keys
|
||||
//,-----------------------------------------------------. ,-----------------------------------------------------.
|
||||
KC_TRANSPARENT, KC_LCBR,KC_LBRC, KC_RBRC, KC_RCBR, MOVE_BEGIN_LINE_TERMINAL, MOVE_END_LINE_TERMINAL, KC_F7, KC_F8, KC_F9, KC_F11, KC_TRANSPARENT,
|
||||
KC_TRANSPARENT, KC_LCBR,KC_LBRC, KC_RBRC, KC_RCBR, MOVE_BEGIN_LINE_TERMINAL, MOVE_END_LINE_TERMINAL, KC_F7, KC_F8, KC_F9, KC_F11, KC_TRANSPARENT,
|
||||
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
|
||||
TO(_BASE), KC_LCTL, KC_LALT, KC_RSFT, KC_LGUI, KC_TRANSPARENT, KC_TRANSPARENT, KC_F4, KC_F5, KC_F6, KC_F12, KC_TRANSPARENT,
|
||||
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
|
||||
@@ -173,7 +173,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
KC_TRANSPARENT, KC_TRANSPARENT, KC_TRANSPARENT , KC_HASH , KC_TRANSPARENT, KC_F10
|
||||
//`--------------------------' `--------------------------'
|
||||
)
|
||||
|
||||
|
||||
};
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
@@ -183,19 +183,19 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
|
||||
// as of this writing, you can't do a layer tap (LT)
|
||||
// and also send a shifted code, like left parens
|
||||
// If you call such a function, it'll do the layer shift but
|
||||
// If you call such a function, it'll do the layer shift but
|
||||
// it'll ignore the key code on tap... this is the workaround
|
||||
|
||||
|
||||
case LT(_NUMS,KC_LPRN): // Shift to _NUMS layer on hold, but send left paren on press
|
||||
if (record->tap.count && record->event.pressed) {
|
||||
tap_code16(KC_LPRN);
|
||||
return false;
|
||||
tap_code16(KC_LPRN);
|
||||
return false;
|
||||
}
|
||||
break;
|
||||
case LT(_NUMS,KC_RPRN): // Shift to _NUMS on hold, send right parens on press
|
||||
if (record->tap.count && record->event.pressed) {
|
||||
tap_code16(KC_RPRN);
|
||||
return false;
|
||||
tap_code16(KC_RPRN);
|
||||
return false;
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -203,20 +203,20 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
if (record->tap.count && record->event.pressed) {
|
||||
tap_code16(SHOW_WINDOWS); // Intercept tap function
|
||||
} else if (record->event.pressed) {
|
||||
tap_code16(WINDOW_LEFT); // Intercept hold function
|
||||
tap_code16(WINDOW_LEFT); // Intercept hold function
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
|
||||
|
||||
case LT(0, NUMERIC_WIN_RIGHT):
|
||||
if (record->tap.count && record->event.pressed) {
|
||||
layer_on(_NUM_MASK);// Intercept tap function
|
||||
} else if (record->event.pressed) {
|
||||
tap_code16(WINDOW_RIGHT); // Intercept hold function
|
||||
tap_code16(WINDOW_RIGHT); // Intercept hold function
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
|
||||
|
||||
case PASTE_VIM:
|
||||
if (record->event.pressed){
|
||||
SEND_STRING(SS_TAP(X_ESCAPE)"\"+pi");
|
||||
@@ -225,7 +225,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
break;
|
||||
|
||||
//only read the keymap config if it's one of the below cases (instead of every time)
|
||||
case DEL_WORD:
|
||||
case DEL_WORD:
|
||||
case SELECT_LEFT_WD:
|
||||
case SELECT_RIGHT_WD:
|
||||
case SELECT_LEFT_LINE:
|
||||
@@ -235,7 +235,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
case MOVE_LEFT_LINE:
|
||||
case MOVE_RIGHT_LINE:
|
||||
case PASTE_NOSTYLE:
|
||||
case MOVE_BEGIN_LINE_TERMINAL:
|
||||
case MOVE_BEGIN_LINE_TERMINAL:
|
||||
case MOVE_END_LINE_TERMINAL:
|
||||
case ACIRCLE:
|
||||
case ADOT:
|
||||
@@ -313,28 +313,28 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
if(keymap_config.swap_lctl_lgui){ //Linux
|
||||
tap_code16(LCTL(RSFT(KC_V)));
|
||||
} else { //osx
|
||||
tap_code16(LGUI(LALT(LSFT(KC_V))));
|
||||
tap_code16(LGUI(LALT(LSFT(KC_V))));
|
||||
}
|
||||
break;
|
||||
case MOVE_BEGIN_LINE_TERMINAL:
|
||||
if(keymap_config.swap_lctl_lgui){ //Linux
|
||||
tap_code16(KC_HOME);
|
||||
} else { //osx
|
||||
tap_code16(LSFT(KC_HOME));
|
||||
tap_code16(LSFT(KC_HOME));
|
||||
}
|
||||
break;
|
||||
case MOVE_END_LINE_TERMINAL:
|
||||
if(keymap_config.swap_lctl_lgui){ //Linux
|
||||
tap_code16(KC_END);
|
||||
} else { //osx
|
||||
tap_code16(LSFT(KC_END));
|
||||
tap_code16(LSFT(KC_END));
|
||||
}
|
||||
break;
|
||||
case ACIRCLE: // å
|
||||
if(keymap_config.swap_lctl_lgui){ //Linux
|
||||
SEND_STRING(SS_TAP(X_COMPOSE_KEY)"aa");
|
||||
} else { //osx
|
||||
tap_code16(LALT(KC_A));
|
||||
tap_code16(LALT(KC_A));
|
||||
}
|
||||
break;
|
||||
case ADOT: // ä
|
||||
@@ -351,14 +351,14 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
SEND_STRING(SS_LALT("u")"o");
|
||||
}
|
||||
break;
|
||||
case COMPOSE_MACRO:
|
||||
case COMPOSE_MACRO:
|
||||
if(keymap_config.swap_lctl_lgui){ //Linux
|
||||
tap_code16(COMPOSE_KEY);
|
||||
} else { //osx
|
||||
tap_code16(COMPOSE_MAC);
|
||||
}
|
||||
break;
|
||||
case SCREENSHOT:
|
||||
case SCREENSHOT:
|
||||
if(keymap_config.swap_lctl_lgui){ //Linux
|
||||
tap_code16(KC_PSCR);
|
||||
} else { //osx
|
||||
@@ -381,7 +381,7 @@ void dance_left_finished (tap_dance_state_t *state, void *user_data) {
|
||||
if(keymap_config.swap_lctl_lgui){ //Linux
|
||||
tap_code16(KC_HOME);
|
||||
} else { //osx
|
||||
tap_code16(LGUI(KC_LEFT));
|
||||
tap_code16(LGUI(KC_LEFT));
|
||||
}
|
||||
} else { //2 taps, make a circumflex
|
||||
tap_code16(KC_CIRC);
|
||||
@@ -394,7 +394,7 @@ void dance_right_finished (tap_dance_state_t *state, void *user_data) {
|
||||
if(keymap_config.swap_lctl_lgui){ //Linux
|
||||
tap_code16(KC_END);
|
||||
} else { //osx
|
||||
tap_code16(LGUI(KC_RIGHT));
|
||||
tap_code16(LGUI(KC_RIGHT));
|
||||
}
|
||||
} else { //2 taps, dollar
|
||||
tap_code16(KC_DOLLAR);
|
||||
@@ -429,7 +429,7 @@ void set_lighting_user(void) {
|
||||
led_t led_state = host_keyboard_led_state();
|
||||
if(led_state.caps_lock){
|
||||
rgblight_sethsv_noeeprom(HSV_RED);
|
||||
}
|
||||
}
|
||||
//rgblight_sethsv(HSV_OFF);
|
||||
break;
|
||||
case _NUMS:
|
||||
@@ -482,7 +482,7 @@ void oled_render_general_state(void){
|
||||
else {
|
||||
oled_write_ln_P(PSTR("OSX"), false);
|
||||
}
|
||||
|
||||
|
||||
//oled_write_ln(get_u8_str(get_current_wpm(), '0'), false);
|
||||
/*
|
||||
led_t led_state = host_keyboard_led_state();
|
||||
@@ -492,7 +492,7 @@ void oled_render_general_state(void){
|
||||
//Layer color has to be handled by master
|
||||
|
||||
|
||||
// led state doesn't have to be handled by master, but
|
||||
// led state doesn't have to be handled by master, but
|
||||
// the keyboard will freeze if you type too fast
|
||||
// and have this handled on the slave side
|
||||
|
||||
@@ -541,7 +541,7 @@ void oled_render_layer_mod_state(void) {
|
||||
break;
|
||||
case _FN_KEYS:
|
||||
oled_write_ln_P(PSTR("Fn"), false);
|
||||
break;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@@ -575,7 +575,7 @@ void oled_render_layer_mod_state(void) {
|
||||
bool oled_task_user(void) {
|
||||
if (is_keyboard_master()) {
|
||||
oled_render_general_state();
|
||||
}
|
||||
}
|
||||
else {
|
||||
oled_render_layer_mod_state();
|
||||
}
|
||||
|
@@ -26,5 +26,4 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#define TAPPING_TERM 200
|
||||
|
||||
#define COMBO_PDL
|
||||
#define COMBO_COUNT 28
|
||||
#define COMBO_TERM 100
|
||||
|
@@ -98,7 +98,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#define TAPPING_TERM 140
|
||||
#define PERMISSIVE_HOLD
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
|
||||
#define TAPPING_TOGGLE 2
|
||||
|
||||
|
@@ -30,8 +30,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
//#define QUICK_TAP_TERM 0
|
||||
#define TAPPING_TERM 200
|
||||
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
#define RGBLIGHT_EFFECT_BREATHING
|
||||
#define RGBLIGHT_EFFECT_RAINBOW_MOOD
|
||||
|
@@ -31,7 +31,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#define QUICK_TAP_TERM 0
|
||||
#define TAPPING_TERM 200
|
||||
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
#undef PERMISSIVE_HOLD
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
@@ -55,8 +54,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#define OLED_FONT_H "keyboards/crkbd/lib/glcdfont.c"
|
||||
|
||||
// fix for me putting alt under A and being a fast typist
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
|
||||
#define LAYER_STATE_8BIT
|
||||
#define SPLIT_WPM_ENABLE
|
||||
|
@@ -31,7 +31,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
// #define QUICK_TAP_TERM 0
|
||||
#define TAPPING_TERM 150
|
||||
#define RETRO_TAPPING
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
#undef RGBLED_NUM
|
||||
|
@@ -8,7 +8,6 @@
|
||||
|
||||
// #define RGB_LAYER_ENABLE
|
||||
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
#define PERMISSIVE_HOLD
|
||||
|
||||
#if defined(TAPPING_TERM)
|
||||
|
@@ -68,110 +68,3 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
//`--------------------------' `--------------------------'
|
||||
)
|
||||
};
|
||||
|
||||
#ifdef OLED_ENABLE
|
||||
#include <stdio.h>
|
||||
|
||||
oled_rotation_t oled_init_user(oled_rotation_t rotation) {
|
||||
if (!is_keyboard_master()) {
|
||||
return OLED_ROTATION_180; // flips the display 180 degrees if offhand
|
||||
}
|
||||
return rotation;
|
||||
}
|
||||
|
||||
#define L_BASE 0
|
||||
#define L_LOWER 2
|
||||
#define L_RAISE 4
|
||||
#define L_ADJUST 8
|
||||
|
||||
void oled_render_layer_state(void) {
|
||||
oled_write_P(PSTR("Layer: "), false);
|
||||
switch (layer_state) {
|
||||
case L_BASE:
|
||||
oled_write_ln_P(PSTR("Default"), false);
|
||||
break;
|
||||
case L_LOWER:
|
||||
oled_write_ln_P(PSTR("Lower"), false);
|
||||
break;
|
||||
case L_RAISE:
|
||||
oled_write_ln_P(PSTR("Raise"), false);
|
||||
break;
|
||||
case L_ADJUST:
|
||||
case L_ADJUST|L_LOWER:
|
||||
case L_ADJUST|L_RAISE:
|
||||
case L_ADJUST|L_LOWER|L_RAISE:
|
||||
oled_write_ln_P(PSTR("Adjust"), false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
char keylog_str[24] = {};
|
||||
|
||||
const char code_to_name[60] = {
|
||||
' ', ' ', ' ', ' ', 'a', 'b', 'c', 'd', 'e', 'f',
|
||||
'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p',
|
||||
'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z',
|
||||
'1', '2', '3', '4', '5', '6', '7', '8', '9', '0',
|
||||
'R', 'E', 'B', 'T', '_', '-', '=', '[', ']', '\\',
|
||||
'#', ';', '\'', '`', ',', '.', '/', ' ', ' ', ' '};
|
||||
|
||||
void set_keylog(uint16_t keycode, keyrecord_t *record) {
|
||||
char name = ' ';
|
||||
if ((keycode >= QK_MOD_TAP && keycode <= QK_MOD_TAP_MAX) ||
|
||||
(keycode >= QK_LAYER_TAP && keycode <= QK_LAYER_TAP_MAX)) { keycode = keycode & 0xFF; }
|
||||
if (keycode < 60) {
|
||||
name = code_to_name[keycode];
|
||||
}
|
||||
|
||||
// update keylog
|
||||
snprintf(keylog_str, sizeof(keylog_str), "%dx%d, k%2d : %c",
|
||||
record->event.key.row, record->event.key.col,
|
||||
keycode, name);
|
||||
}
|
||||
|
||||
void oled_render_keylog(void) {
|
||||
oled_write(keylog_str, false);
|
||||
}
|
||||
|
||||
void render_bootmagic_status(bool status) {
|
||||
/* Show Ctrl-Gui Swap options */
|
||||
static const char PROGMEM logo[][2][3] = {
|
||||
{{0x97, 0x98, 0}, {0xb7, 0xb8, 0}},
|
||||
{{0x95, 0x96, 0}, {0xb5, 0xb6, 0}},
|
||||
};
|
||||
if (status) {
|
||||
oled_write_ln_P(logo[0][0], false);
|
||||
oled_write_ln_P(logo[0][1], false);
|
||||
} else {
|
||||
oled_write_ln_P(logo[1][0], false);
|
||||
oled_write_ln_P(logo[1][1], false);
|
||||
}
|
||||
}
|
||||
|
||||
void oled_render_logo(void) {
|
||||
static const char PROGMEM crkbd_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(crkbd_logo, false);
|
||||
}
|
||||
|
||||
bool oled_task_user(void) {
|
||||
if (is_keyboard_master()) {
|
||||
oled_render_layer_state();
|
||||
oled_render_keylog();
|
||||
} else {
|
||||
oled_render_logo();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
if (record->event.pressed) {
|
||||
set_keylog(keycode, record);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
#endif // OLED_ENABLE
|
||||
|
@@ -1,6 +1,3 @@
|
||||
MOUSEKEY_ENABLE = no # Mouse keys
|
||||
RGBLIGHT_ENABLE = yes # Enable WS2812 RGB underlight.
|
||||
VIA_ENABLE = yes # Enable VIA
|
||||
OLED_ENABLE = yes
|
||||
OLED_DRIVER = SSD1306
|
||||
LTO_ENABLE = yes
|
||||
|
@@ -38,5 +38,5 @@
|
||||
#define MATRIX_COL_PINS { F4, F5, F6, F7, B7, D5 }
|
||||
|
||||
/* ws2812 RGB LED */
|
||||
#undef RGB_DI_PIN
|
||||
#define RGB_DI_PIN B5
|
||||
#undef WS2812_DI_PIN
|
||||
#define WS2812_DI_PIN B5
|
||||
|
@@ -43,7 +43,7 @@ uint8_t readRegister(uint8_t address) {
|
||||
return data;
|
||||
}
|
||||
|
||||
void pointing_device_task(void){
|
||||
bool pointing_device_task(void){
|
||||
uint8_t motion = readRegister(0x02);
|
||||
|
||||
// Motion has occurred on the trackpad
|
||||
@@ -73,6 +73,6 @@ void pointing_device_task(void){
|
||||
}
|
||||
|
||||
pointing_device_set_report(currentReport);
|
||||
pointing_device_send();
|
||||
}
|
||||
return pointing_device_send();
|
||||
}
|
||||
|
@@ -31,7 +31,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#define QUICK_TAP_TERM 0
|
||||
#define TAPPING_TERM 300
|
||||
#define PERMISSIVE_HOLD
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
#define LEADER_PER_KEY_TIMING
|
||||
#define LEADER_TIMEOUT 300
|
||||
|
||||
|
@@ -1,5 +1,5 @@
|
||||
#include <stdio.h>
|
||||
#include "crkbd.h"
|
||||
#include "quantum.h"
|
||||
|
||||
char host_led_state_str[24];
|
||||
|
||||
|
@@ -1,5 +1,5 @@
|
||||
#include <stdio.h>
|
||||
#include "crkbd.h"
|
||||
#include "quantum.h"
|
||||
|
||||
char keylog_str[24] = {};
|
||||
char keylogs_str[21] = {};
|
||||
|
@@ -1,7 +1,5 @@
|
||||
|
||||
#include QMK_KEYBOARD_H
|
||||
#include "quantum.h"
|
||||
#include <stdio.h>
|
||||
#include "crkbd.h"
|
||||
|
||||
// in the future, should use (1U<<_LAYER_NAME) instead, but needs to be moved to keymap,c
|
||||
#define L_BASE 0
|
||||
|
@@ -1,4 +1,4 @@
|
||||
#include "crkbd.h"
|
||||
#include "quantum.h"
|
||||
|
||||
const char *read_logo(void) {
|
||||
static char logo[] = {
|
||||
|
@@ -1,5 +1,5 @@
|
||||
#include <stdio.h>
|
||||
#include "crkbd.h"
|
||||
#include "quantum.h"
|
||||
|
||||
char mode_icon[24];
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
|
||||
#include QMK_KEYBOARD_H
|
||||
#include <stdio.h>
|
||||
#include "quantum.h"
|
||||
|
||||
extern rgblight_config_t rgblight_config;
|
||||
char rbf_info_str[24];
|
||||
|
@@ -1,5 +1,5 @@
|
||||
#include <stdio.h>
|
||||
#include "crkbd.h"
|
||||
#include "quantum.h"
|
||||
|
||||
char timelog_str[24] = {};
|
||||
int last_time = 0;
|
||||
|
@@ -19,9 +19,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#pragma once
|
||||
|
||||
/* ws2812 RGB LED */
|
||||
#define RGB_DI_PIN D3
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
|
||||
# define RGBLIGHT_EFFECT_BREATHING
|
||||
@@ -69,7 +66,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
# define ENABLE_RGB_MATRIX_SOLID_SPLASH
|
||||
#endif
|
||||
|
||||
#define DIODE_DIRECTION COL2ROW
|
||||
|
||||
#define SPLIT_USB_DETECT
|
||||
|
||||
|
@@ -1,6 +1,175 @@
|
||||
{
|
||||
"features": {
|
||||
"rgb_matrix": true
|
||||
},
|
||||
"split": {
|
||||
"soft_serial_pin": "D2"
|
||||
},
|
||||
"bootloader": "atmel-dfu"
|
||||
"ws2812": {
|
||||
"pin": "D3"
|
||||
},
|
||||
"bootloader": "atmel-dfu",
|
||||
"layout_aliases": {
|
||||
"LAYOUT": "LAYOUT_split_3x6_3"
|
||||
},
|
||||
"layouts": {
|
||||
"LAYOUT_split_3x5_3": {
|
||||
"layout": [
|
||||
{"matrix": [0, 1], "x": 0, "y": 0.3},
|
||||
{"matrix": [0, 2], "x": 1, "y": 0.1},
|
||||
{"matrix": [0, 3], "x": 2, "y": 0},
|
||||
{"matrix": [0, 4], "x": 3, "y": 0.1},
|
||||
{"matrix": [0, 5], "x": 4, "y": 0.2},
|
||||
|
||||
{"matrix": [4, 5], "x": 8, "y": 0.2},
|
||||
{"matrix": [4, 4], "x": 9, "y": 0.1},
|
||||
{"matrix": [4, 3], "x": 10, "y": 0},
|
||||
{"matrix": [4, 2], "x": 11, "y": 0.1},
|
||||
{"matrix": [4, 1], "x": 12, "y": 0.3},
|
||||
|
||||
{"matrix": [1, 1], "x": 0, "y": 1.3},
|
||||
{"matrix": [1, 2], "x": 1, "y": 1.1},
|
||||
{"matrix": [1, 3], "x": 2, "y": 1},
|
||||
{"matrix": [1, 4], "x": 3, "y": 1.1},
|
||||
{"matrix": [1, 5], "x": 4, "y": 1.2},
|
||||
|
||||
{"matrix": [5, 5], "x": 8, "y": 1.2},
|
||||
{"matrix": [5, 4], "x": 9, "y": 1.1},
|
||||
{"matrix": [5, 3], "x": 10, "y": 1},
|
||||
{"matrix": [5, 2], "x": 11, "y": 1.1},
|
||||
{"matrix": [5, 1], "x": 12, "y": 1.3},
|
||||
|
||||
{"matrix": [2, 1], "x": 0, "y": 2.3},
|
||||
{"matrix": [2, 2], "x": 1, "y": 2.1},
|
||||
{"matrix": [2, 3], "x": 2, "y": 2},
|
||||
{"matrix": [2, 4], "x": 3, "y": 2.1},
|
||||
{"matrix": [2, 5], "x": 4, "y": 2.2},
|
||||
|
||||
{"matrix": [6, 5], "x": 8, "y": 2.2},
|
||||
{"matrix": [6, 4], "x": 9, "y": 2.1},
|
||||
{"matrix": [6, 3], "x": 10, "y": 2},
|
||||
{"matrix": [6, 2], "x": 11, "y": 2.1},
|
||||
{"matrix": [6, 1], "x": 12, "y": 2.3},
|
||||
|
||||
{"matrix": [3, 3], "x": 3, "y": 3.7},
|
||||
{"matrix": [3, 4], "x": 4, "y": 3.7},
|
||||
{"matrix": [3, 5], "x": 5, "y": 3.2, "h": 1.5},
|
||||
|
||||
{"matrix": [7, 5], "x": 7, "y": 3.2, "h": 1.5},
|
||||
{"matrix": [7, 4], "x": 8, "y": 3.7},
|
||||
{"matrix": [7, 3], "x": 9, "y": 3.7}
|
||||
]
|
||||
},
|
||||
"LAYOUT_split_3x6_3": {
|
||||
"layout": [
|
||||
{"matrix": [0, 0], "x": 0, "y": 0.3},
|
||||
{"matrix": [0, 1], "x": 1, "y": 0.3},
|
||||
{"matrix": [0, 2], "x": 2, "y": 0.1},
|
||||
{"matrix": [0, 3], "x": 3, "y": 0},
|
||||
{"matrix": [0, 4], "x": 4, "y": 0.1},
|
||||
{"matrix": [0, 5], "x": 5, "y": 0.2},
|
||||
|
||||
{"matrix": [4, 5], "x": 9, "y": 0.2},
|
||||
{"matrix": [4, 4], "x": 10, "y": 0.1},
|
||||
{"matrix": [4, 3], "x": 11, "y": 0},
|
||||
{"matrix": [4, 2], "x": 12, "y": 0.1},
|
||||
{"matrix": [4, 1], "x": 13, "y": 0.3},
|
||||
{"matrix": [4, 0], "x": 14, "y": 0.3},
|
||||
|
||||
{"matrix": [1, 0], "x": 0, "y": 1.3},
|
||||
{"matrix": [1, 1], "x": 1, "y": 1.3},
|
||||
{"matrix": [1, 2], "x": 2, "y": 1.1},
|
||||
{"matrix": [1, 3], "x": 3, "y": 1},
|
||||
{"matrix": [1, 4], "x": 4, "y": 1.1},
|
||||
{"matrix": [1, 5], "x": 5, "y": 1.2},
|
||||
|
||||
{"matrix": [5, 5], "x": 9, "y": 1.2},
|
||||
{"matrix": [5, 4], "x": 10, "y": 1.1},
|
||||
{"matrix": [5, 3], "x": 11, "y": 1},
|
||||
{"matrix": [5, 2], "x": 12, "y": 1.1},
|
||||
{"matrix": [5, 1], "x": 13, "y": 1.3},
|
||||
{"matrix": [5, 0], "x": 14, "y": 1.3},
|
||||
|
||||
{"matrix": [2, 0], "x": 0, "y": 2.3},
|
||||
{"matrix": [2, 1], "x": 1, "y": 2.3},
|
||||
{"matrix": [2, 2], "x": 2, "y": 2.1},
|
||||
{"matrix": [2, 3], "x": 3, "y": 2},
|
||||
{"matrix": [2, 4], "x": 4, "y": 2.1},
|
||||
{"matrix": [2, 5], "x": 5, "y": 2.2},
|
||||
|
||||
{"matrix": [6, 5], "x": 9, "y": 2.2},
|
||||
{"matrix": [6, 4], "x": 10, "y": 2.1},
|
||||
{"matrix": [6, 3], "x": 11, "y": 2},
|
||||
{"matrix": [6, 2], "x": 12, "y": 2.1},
|
||||
{"matrix": [6, 1], "x": 13, "y": 2.3},
|
||||
{"matrix": [6, 0], "x": 14, "y": 2.3},
|
||||
|
||||
{"matrix": [3, 3], "x": 4, "y": 3.7},
|
||||
{"matrix": [3, 4], "x": 5, "y": 3.7},
|
||||
{"matrix": [3, 5], "x": 6, "y": 3.2, "h": 1.5},
|
||||
|
||||
{"matrix": [7, 5], "x": 8, "y": 3.2, "h": 1.5},
|
||||
{"matrix": [7, 4], "x": 9, "y": 3.7},
|
||||
{"matrix": [7, 3], "x": 10, "y": 3.7}
|
||||
]
|
||||
}
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"layout": [
|
||||
{"x": 85, "y": 16, "flags": 2},
|
||||
{"x": 50, "y": 13, "flags": 2},
|
||||
{"x": 16, "y": 20, "flags": 2},
|
||||
{"x": 16, "y": 38, "flags": 2},
|
||||
{"x": 50, "y": 48, "flags": 2},
|
||||
{"x": 85, "y": 52, "flags": 2},
|
||||
{"matrix": [3, 5], "x": 95, "y": 63, "flags": 1},
|
||||
{"matrix": [2, 5], "x": 85, "y": 39, "flags": 4},
|
||||
{"matrix": [1, 5], "x": 85, "y": 21, "flags": 4},
|
||||
{"matrix": [0, 5], "x": 85, "y": 4, "flags": 4},
|
||||
{"matrix": [0, 4], "x": 68, "y": 2, "flags": 4},
|
||||
{"matrix": [1, 4], "x": 68, "y": 19, "flags": 4},
|
||||
{"matrix": [2, 4], "x": 68, "y": 37, "flags": 4},
|
||||
{"matrix": [3, 4], "x": 80, "y": 58, "flags": 1},
|
||||
{"matrix": [3, 3], "x": 60, "y": 55, "flags": 1},
|
||||
{"matrix": [2, 3], "x": 50, "y": 35, "flags": 4},
|
||||
{"matrix": [1, 3], "x": 50, "y": 13, "flags": 4},
|
||||
{"matrix": [0, 3], "x": 50, "y": 0, "flags": 4},
|
||||
{"matrix": [0, 2], "x": 33, "y": 3, "flags": 4},
|
||||
{"matrix": [1, 2], "x": 33, "y": 20, "flags": 4},
|
||||
{"matrix": [2, 2], "x": 33, "y": 37, "flags": 4},
|
||||
{"matrix": [2, 1], "x": 16, "y": 42, "flags": 4},
|
||||
{"matrix": [1, 1], "x": 16, "y": 24, "flags": 4},
|
||||
{"matrix": [0, 1], "x": 16, "y": 7, "flags": 4},
|
||||
{"matrix": [0, 0], "x": 0, "y": 7, "flags": 1},
|
||||
{"matrix": [1, 0], "x": 0, "y": 24, "flags": 1},
|
||||
{"matrix": [2, 0], "x": 0, "y": 41, "flags": 1},
|
||||
{"x": 139, "y": 16, "flags": 2},
|
||||
{"x": 174, "y": 13, "flags": 2},
|
||||
{"x": 208, "y": 20, "flags": 2},
|
||||
{"x": 208, "y": 38, "flags": 2},
|
||||
{"x": 174, "y": 48, "flags": 2},
|
||||
{"x": 139, "y": 52, "flags": 2},
|
||||
{"matrix": [7, 5], "x": 129, "y": 63, "flags": 1},
|
||||
{"matrix": [6, 5], "x": 139, "y": 39, "flags": 4},
|
||||
{"matrix": [5, 5], "x": 139, "y": 21, "flags": 4},
|
||||
{"matrix": [4, 5], "x": 139, "y": 4, "flags": 4},
|
||||
{"matrix": [4, 4], "x": 156, "y": 2, "flags": 4},
|
||||
{"matrix": [5, 4], "x": 156, "y": 19, "flags": 4},
|
||||
{"matrix": [6, 4], "x": 156, "y": 37, "flags": 4},
|
||||
{"matrix": [7, 4], "x": 144, "y": 58, "flags": 1},
|
||||
{"matrix": [7, 3], "x": 164, "y": 55, "flags": 1},
|
||||
{"matrix": [6, 3], "x": 174, "y": 35, "flags": 4},
|
||||
{"matrix": [5, 3], "x": 174, "y": 13, "flags": 4},
|
||||
{"matrix": [4, 3], "x": 174, "y": 0, "flags": 4},
|
||||
{"matrix": [4, 2], "x": 191, "y": 3, "flags": 4},
|
||||
{"matrix": [5, 2], "x": 191, "y": 20, "flags": 4},
|
||||
{"matrix": [6, 2], "x": 191, "y": 37, "flags": 4},
|
||||
{"matrix": [6, 1], "x": 208, "y": 42, "flags": 4},
|
||||
{"matrix": [5, 1], "x": 208, "y": 24, "flags": 4},
|
||||
{"matrix": [4, 1], "x": 208, "y": 7, "flags": 4},
|
||||
{"matrix": [4, 0], "x": 224, "y": 7, "flags": 1},
|
||||
{"matrix": [5, 0], "x": 224, "y": 24, "flags": 1},
|
||||
{"matrix": [6, 0], "x": 224, "y": 41, "flags": 1}
|
||||
]
|
||||
}
|
||||
}
|
||||
|
@@ -16,7 +16,7 @@ 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 "r2g.h"
|
||||
#include "quantum.h"
|
||||
|
||||
#ifdef RGB_MATRIX_ENABLE
|
||||
|
||||
@@ -88,98 +88,7 @@ led_config_t g_led_config = { {
|
||||
#endif
|
||||
|
||||
#ifdef OLED_ENABLE
|
||||
|
||||
oled_rotation_t oled_init_kb(oled_rotation_t rotation) {
|
||||
if (!is_keyboard_master()) {
|
||||
return OLED_ROTATION_180; // flips the display 180 degrees if offhand
|
||||
}
|
||||
return rotation;
|
||||
}
|
||||
|
||||
enum Layers{
|
||||
L_BASE, L_LOWER, L_RAISE, L_ADJUST
|
||||
};
|
||||
|
||||
void oled_render_layer_state_r2g(void) {
|
||||
oled_write_P(PSTR("Layer: "), false);
|
||||
switch (get_highest_layer(layer_state)) {
|
||||
case L_BASE:
|
||||
oled_write_ln_P(PSTR("Default"), false);
|
||||
break;
|
||||
case L_LOWER:
|
||||
oled_write_ln_P(PSTR("Lower"), false);
|
||||
break;
|
||||
case L_RAISE:
|
||||
oled_write_ln_P(PSTR("Raise"), false);
|
||||
break;
|
||||
case L_ADJUST:
|
||||
oled_write_ln_P(PSTR("Adjust"), false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
//char keylog_str_r2g[24] = {};
|
||||
|
||||
const char code_to_name_r2g[60] = {
|
||||
' ', ' ', ' ', ' ', 'a', 'b', 'c', 'd', 'e', 'f',
|
||||
'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p',
|
||||
'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z',
|
||||
'1', '2', '3', '4', '5', '6', '7', '8', '9', '0',
|
||||
'R', 'E', 'B', 'T', '_', '-', '=', '[', ']', '\\',
|
||||
'#', ';', '\'', '`', ',', '.', '/', ' ', ' ', ' '};
|
||||
|
||||
char key_name_r2g = ' ';
|
||||
uint16_t last_keycode_r2g;
|
||||
uint8_t last_row_r2g;
|
||||
uint8_t last_col_r2g;
|
||||
|
||||
void set_keylog_r2g(uint16_t keycode, keyrecord_t *record) {
|
||||
key_name_r2g = ' ';
|
||||
last_keycode_r2g = keycode;
|
||||
if ((keycode >= QK_MOD_TAP && keycode <= QK_MOD_TAP_MAX) ||
|
||||
(keycode >= QK_LAYER_TAP && keycode <= QK_LAYER_TAP_MAX)) { last_keycode_r2g = keycode & 0xFF; }
|
||||
if (keycode < 60) {
|
||||
key_name_r2g = code_to_name_r2g[keycode];
|
||||
}
|
||||
last_row_r2g = record->event.key.row;
|
||||
last_col_r2g = record->event.key.col;
|
||||
}
|
||||
|
||||
const char *depad_str(const char *depad_str, char depad_char) {
|
||||
while (*depad_str == depad_char) ++depad_str;
|
||||
return depad_str;
|
||||
}
|
||||
|
||||
void oled_render_keylog_r2g(void) {
|
||||
//oled_write(keylog_str_r2g, false);
|
||||
const char *last_row_r2g_str = get_u8_str(last_row_r2g, ' ');
|
||||
oled_write(depad_str(last_row_r2g_str, ' '), false);
|
||||
oled_write_P(PSTR("x"), false);
|
||||
const char *last_col_r2g_str = get_u8_str(last_col_r2g, ' ');
|
||||
oled_write(depad_str(last_col_r2g_str, ' '), false);
|
||||
oled_write_P(PSTR(", k"), false);
|
||||
const char *last_keycode_r2g_str = get_u16_str(last_keycode_r2g, ' ');
|
||||
oled_write(depad_str(last_keycode_r2g_str, ' '), false);
|
||||
oled_write_P(PSTR(":"), false);
|
||||
oled_write_char(key_name_r2g, false);
|
||||
}
|
||||
|
||||
void render_bootmagic_status_r2g(bool status) {
|
||||
/* Show Ctrl-Gui Swap options */
|
||||
static const char PROGMEM logo[][2][3] = {
|
||||
{{0x97, 0x98, 0}, {0xb7, 0xb8, 0}},
|
||||
{{0x95, 0x96, 0}, {0xb5, 0xb6, 0}},
|
||||
};
|
||||
if (status) {
|
||||
oled_write_ln_P(logo[0][0], false);
|
||||
oled_write_ln_P(logo[0][1], false);
|
||||
} else {
|
||||
oled_write_ln_P(logo[1][0], false);
|
||||
oled_write_ln_P(logo[1][1], false);
|
||||
}
|
||||
}
|
||||
|
||||
void oled_render_logo_r2g(void) {
|
||||
void oled_render_logo(void) {
|
||||
static const char PROGMEM mb_logo[] = {
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
|
||||
@@ -218,23 +127,4 @@ void oled_render_logo_r2g(void) {
|
||||
//oled_set_cursor(oled_max_chars()/2,oled_max_lines()/2);
|
||||
//oled_write_P(PSTR("R2G"), false);
|
||||
}
|
||||
|
||||
bool oled_task_kb(void) {
|
||||
if (!oled_task_user()) { return false; }
|
||||
if (is_keyboard_master()) {
|
||||
oled_render_layer_state_r2g();
|
||||
oled_render_keylog_r2g();
|
||||
} else {
|
||||
oled_render_logo_r2g();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
bool process_record_kb(uint16_t keycode, keyrecord_t *record) {
|
||||
if (record->event.pressed) {
|
||||
set_keylog_r2g(keycode, record);
|
||||
}
|
||||
return process_record_user(keycode, record);
|
||||
}
|
||||
#endif // OLED_ENABLE
|
||||
|
||||
#endif
|
||||
|
@@ -1,60 +0,0 @@
|
||||
/*
|
||||
Copyright 2019 @foostan
|
||||
Copyright 2020 Drashna Jaelre <@drashna>
|
||||
|
||||
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
|
||||
|
||||
#include "crkbd.h"
|
||||
#include "quantum.h"
|
||||
|
||||
// clang-format off
|
||||
#define LAYOUT_split_3x6_3( \
|
||||
L00, L01, L02, L03, L04, L05, R00, R01, R02, R03, R04, R05, \
|
||||
L10, L11, L12, L13, L14, L15, R10, R11, R12, R13, R14, R15, \
|
||||
L20, L21, L22, L23, L24, L25, R20, R21, R22, R23, R24, R25, \
|
||||
L30, L31, L32, R30, R31, R32 \
|
||||
) \
|
||||
{ \
|
||||
{ L00, L01, L02, L03, L04, L05 }, \
|
||||
{ L10, L11, L12, L13, L14, L15 }, \
|
||||
{ L20, L21, L22, L23, L24, L25 }, \
|
||||
{ KC_NO, KC_NO, KC_NO, L30, L31, L32 }, \
|
||||
{ R05, R04, R03, R02, R01, R00 }, \
|
||||
{ R15, R14, R13, R12, R11, R10 }, \
|
||||
{ R25, R24, R23, R22, R21, R20 }, \
|
||||
{ KC_NO, KC_NO, KC_NO, R32, R31, R30 } \
|
||||
}
|
||||
|
||||
#define LAYOUT_split_3x5_3( \
|
||||
L00, L01, L02, L03, L04, R00, R01, R02, R03, R04, \
|
||||
L10, L11, L12, L13, L14, R10, R11, R12, R13, R14, \
|
||||
L20, L21, L22, L23, L24, R20, R21, R22, R23, R24, \
|
||||
L30, L31, L32, R30, R31, R32 \
|
||||
) \
|
||||
{ \
|
||||
{ KC_NO, L00, L01, L02, L03, L04 }, \
|
||||
{ KC_NO, L10, L11, L12, L13, L14 }, \
|
||||
{ KC_NO, L20, L21, L22, L23, L24 }, \
|
||||
{ KC_NO, KC_NO, KC_NO, L30, L31, L32 }, \
|
||||
{ KC_NO, R04, R03, R02, R01, R00 }, \
|
||||
{ KC_NO, R14, R13, R12, R11, R10 }, \
|
||||
{ KC_NO, R24, R23, R22, R21, R20 }, \
|
||||
{ KC_NO, KC_NO, KC_NO, R32, R31, R30 } \
|
||||
}
|
||||
|
||||
|
||||
#define LAYOUT LAYOUT_split_3x6_3
|
@@ -1,6 +0,0 @@
|
||||
OLED_ENABLE = yes
|
||||
OLED_DRIVER = SSD1306
|
||||
LTO_ENABLE = yes
|
||||
RGBLIGHT_ENABLE = yes
|
||||
|
||||
SPLIT_KEYBOARD = yes
|
||||
|
@@ -1 +0,0 @@
|
||||
DEFAULT_FOLDER = crkbd/rev1
|
@@ -18,9 +18,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#pragma once
|
||||
|
||||
/* ws2812 RGB LED */
|
||||
#define RGB_DI_PIN D3
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
# define RGBLED_NUM 54 // Number of LEDs
|
||||
# define RGBLED_SPLIT \
|
||||
@@ -35,5 +32,3 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
{ 27, 27 }
|
||||
# define SPLIT_TRANSPORT_MIRROR
|
||||
#endif
|
||||
|
||||
#define DIODE_DIRECTION COL2ROW
|
||||
|
@@ -1,6 +1,175 @@
|
||||
{
|
||||
"features": {
|
||||
"rgblight": true
|
||||
},
|
||||
"split": {
|
||||
"soft_serial_pin": "D2"
|
||||
},
|
||||
"bootloader": "caterina"
|
||||
"ws2812": {
|
||||
"pin": "D3"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"layout": [
|
||||
{"x": 85, "y": 16, "flags": 2},
|
||||
{"x": 50, "y": 13, "flags": 2},
|
||||
{"x": 16, "y": 20, "flags": 2},
|
||||
{"x": 16, "y": 38, "flags": 2},
|
||||
{"x": 50, "y": 48, "flags": 2},
|
||||
{"x": 85, "y": 52, "flags": 2},
|
||||
{"matrix": [3, 5], "x": 95, "y": 63, "flags": 1},
|
||||
{"matrix": [2, 5], "x": 85, "y": 39, "flags": 4},
|
||||
{"matrix": [1, 5], "x": 85, "y": 21, "flags": 4},
|
||||
{"matrix": [0, 5], "x": 85, "y": 4, "flags": 4},
|
||||
{"matrix": [0, 4], "x": 68, "y": 2, "flags": 4},
|
||||
{"matrix": [1, 4], "x": 68, "y": 19, "flags": 4},
|
||||
{"matrix": [2, 4], "x": 68, "y": 37, "flags": 4},
|
||||
{"matrix": [3, 4], "x": 80, "y": 58, "flags": 1},
|
||||
{"matrix": [3, 3], "x": 60, "y": 55, "flags": 1},
|
||||
{"matrix": [2, 3], "x": 50, "y": 35, "flags": 4},
|
||||
{"matrix": [1, 3], "x": 50, "y": 13, "flags": 4},
|
||||
{"matrix": [0, 3], "x": 50, "y": 0, "flags": 4},
|
||||
{"matrix": [0, 2], "x": 33, "y": 3, "flags": 4},
|
||||
{"matrix": [1, 2], "x": 33, "y": 20, "flags": 4},
|
||||
{"matrix": [2, 2], "x": 33, "y": 37, "flags": 4},
|
||||
{"matrix": [2, 1], "x": 16, "y": 42, "flags": 4},
|
||||
{"matrix": [1, 1], "x": 16, "y": 24, "flags": 4},
|
||||
{"matrix": [0, 1], "x": 16, "y": 7, "flags": 4},
|
||||
{"matrix": [0, 0], "x": 0, "y": 7, "flags": 1},
|
||||
{"matrix": [1, 0], "x": 0, "y": 24, "flags": 1},
|
||||
{"matrix": [2, 0], "x": 0, "y": 41, "flags": 1},
|
||||
{"x": 139, "y": 16, "flags": 2},
|
||||
{"x": 174, "y": 13, "flags": 2},
|
||||
{"x": 208, "y": 20, "flags": 2},
|
||||
{"x": 208, "y": 38, "flags": 2},
|
||||
{"x": 174, "y": 48, "flags": 2},
|
||||
{"x": 139, "y": 52, "flags": 2},
|
||||
{"matrix": [7, 5], "x": 129, "y": 63, "flags": 1},
|
||||
{"matrix": [6, 5], "x": 139, "y": 39, "flags": 4},
|
||||
{"matrix": [5, 5], "x": 139, "y": 21, "flags": 4},
|
||||
{"matrix": [4, 5], "x": 139, "y": 4, "flags": 4},
|
||||
{"matrix": [4, 4], "x": 156, "y": 2, "flags": 4},
|
||||
{"matrix": [5, 4], "x": 156, "y": 19, "flags": 4},
|
||||
{"matrix": [6, 4], "x": 156, "y": 37, "flags": 4},
|
||||
{"matrix": [7, 4], "x": 144, "y": 58, "flags": 1},
|
||||
{"matrix": [7, 3], "x": 164, "y": 55, "flags": 1},
|
||||
{"matrix": [6, 3], "x": 174, "y": 35, "flags": 4},
|
||||
{"matrix": [5, 3], "x": 174, "y": 13, "flags": 4},
|
||||
{"matrix": [4, 3], "x": 174, "y": 0, "flags": 4},
|
||||
{"matrix": [4, 2], "x": 191, "y": 3, "flags": 4},
|
||||
{"matrix": [5, 2], "x": 191, "y": 20, "flags": 4},
|
||||
{"matrix": [6, 2], "x": 191, "y": 37, "flags": 4},
|
||||
{"matrix": [6, 1], "x": 208, "y": 42, "flags": 4},
|
||||
{"matrix": [5, 1], "x": 208, "y": 24, "flags": 4},
|
||||
{"matrix": [4, 1], "x": 208, "y": 7, "flags": 4},
|
||||
{"matrix": [4, 0], "x": 224, "y": 7, "flags": 1},
|
||||
{"matrix": [5, 0], "x": 224, "y": 24, "flags": 1},
|
||||
{"matrix": [6, 0], "x": 224, "y": 41, "flags": 1}
|
||||
]
|
||||
},
|
||||
"development_board": "promicro",
|
||||
"layout_aliases": {
|
||||
"LAYOUT": "LAYOUT_split_3x6_3"
|
||||
},
|
||||
"layouts": {
|
||||
"LAYOUT_split_3x5_3": {
|
||||
"layout": [
|
||||
{"matrix": [0, 1], "x": 0, "y": 0.3},
|
||||
{"matrix": [0, 2], "x": 1, "y": 0.1},
|
||||
{"matrix": [0, 3], "x": 2, "y": 0},
|
||||
{"matrix": [0, 4], "x": 3, "y": 0.1},
|
||||
{"matrix": [0, 5], "x": 4, "y": 0.2},
|
||||
|
||||
{"matrix": [4, 5], "x": 8, "y": 0.2},
|
||||
{"matrix": [4, 4], "x": 9, "y": 0.1},
|
||||
{"matrix": [4, 3], "x": 10, "y": 0},
|
||||
{"matrix": [4, 2], "x": 11, "y": 0.1},
|
||||
{"matrix": [4, 1], "x": 12, "y": 0.3},
|
||||
|
||||
{"matrix": [1, 1], "x": 0, "y": 1.3},
|
||||
{"matrix": [1, 2], "x": 1, "y": 1.1},
|
||||
{"matrix": [1, 3], "x": 2, "y": 1},
|
||||
{"matrix": [1, 4], "x": 3, "y": 1.1},
|
||||
{"matrix": [1, 5], "x": 4, "y": 1.2},
|
||||
|
||||
{"matrix": [5, 5], "x": 8, "y": 1.2},
|
||||
{"matrix": [5, 4], "x": 9, "y": 1.1},
|
||||
{"matrix": [5, 3], "x": 10, "y": 1},
|
||||
{"matrix": [5, 2], "x": 11, "y": 1.1},
|
||||
{"matrix": [5, 1], "x": 12, "y": 1.3},
|
||||
|
||||
{"matrix": [2, 1], "x": 0, "y": 2.3},
|
||||
{"matrix": [2, 2], "x": 1, "y": 2.1},
|
||||
{"matrix": [2, 3], "x": 2, "y": 2},
|
||||
{"matrix": [2, 4], "x": 3, "y": 2.1},
|
||||
{"matrix": [2, 5], "x": 4, "y": 2.2},
|
||||
|
||||
{"matrix": [6, 5], "x": 8, "y": 2.2},
|
||||
{"matrix": [6, 4], "x": 9, "y": 2.1},
|
||||
{"matrix": [6, 3], "x": 10, "y": 2},
|
||||
{"matrix": [6, 2], "x": 11, "y": 2.1},
|
||||
{"matrix": [6, 1], "x": 12, "y": 2.3},
|
||||
|
||||
{"matrix": [3, 3], "x": 3, "y": 3.7},
|
||||
{"matrix": [3, 4], "x": 4, "y": 3.7},
|
||||
{"matrix": [3, 5], "x": 5, "y": 3.2, "h": 1.5},
|
||||
|
||||
{"matrix": [7, 5], "x": 7, "y": 3.2, "h": 1.5},
|
||||
{"matrix": [7, 4], "x": 8, "y": 3.7},
|
||||
{"matrix": [7, 3], "x": 9, "y": 3.7}
|
||||
]
|
||||
},
|
||||
"LAYOUT_split_3x6_3": {
|
||||
"layout": [
|
||||
{"matrix": [0, 0], "x": 0, "y": 0.3},
|
||||
{"matrix": [0, 1], "x": 1, "y": 0.3},
|
||||
{"matrix": [0, 2], "x": 2, "y": 0.1},
|
||||
{"matrix": [0, 3], "x": 3, "y": 0},
|
||||
{"matrix": [0, 4], "x": 4, "y": 0.1},
|
||||
{"matrix": [0, 5], "x": 5, "y": 0.2},
|
||||
|
||||
{"matrix": [4, 5], "x": 9, "y": 0.2},
|
||||
{"matrix": [4, 4], "x": 10, "y": 0.1},
|
||||
{"matrix": [4, 3], "x": 11, "y": 0},
|
||||
{"matrix": [4, 2], "x": 12, "y": 0.1},
|
||||
{"matrix": [4, 1], "x": 13, "y": 0.3},
|
||||
{"matrix": [4, 0], "x": 14, "y": 0.3},
|
||||
|
||||
{"matrix": [1, 0], "x": 0, "y": 1.3},
|
||||
{"matrix": [1, 1], "x": 1, "y": 1.3},
|
||||
{"matrix": [1, 2], "x": 2, "y": 1.1},
|
||||
{"matrix": [1, 3], "x": 3, "y": 1},
|
||||
{"matrix": [1, 4], "x": 4, "y": 1.1},
|
||||
{"matrix": [1, 5], "x": 5, "y": 1.2},
|
||||
|
||||
{"matrix": [5, 5], "x": 9, "y": 1.2},
|
||||
{"matrix": [5, 4], "x": 10, "y": 1.1},
|
||||
{"matrix": [5, 3], "x": 11, "y": 1},
|
||||
{"matrix": [5, 2], "x": 12, "y": 1.1},
|
||||
{"matrix": [5, 1], "x": 13, "y": 1.3},
|
||||
{"matrix": [5, 0], "x": 14, "y": 1.3},
|
||||
|
||||
{"matrix": [2, 0], "x": 0, "y": 2.3},
|
||||
{"matrix": [2, 1], "x": 1, "y": 2.3},
|
||||
{"matrix": [2, 2], "x": 2, "y": 2.1},
|
||||
{"matrix": [2, 3], "x": 3, "y": 2},
|
||||
{"matrix": [2, 4], "x": 4, "y": 2.1},
|
||||
{"matrix": [2, 5], "x": 5, "y": 2.2},
|
||||
|
||||
{"matrix": [6, 5], "x": 9, "y": 2.2},
|
||||
{"matrix": [6, 4], "x": 10, "y": 2.1},
|
||||
{"matrix": [6, 3], "x": 11, "y": 2},
|
||||
{"matrix": [6, 2], "x": 12, "y": 2.1},
|
||||
{"matrix": [6, 1], "x": 13, "y": 2.3},
|
||||
{"matrix": [6, 0], "x": 14, "y": 2.3},
|
||||
|
||||
{"matrix": [3, 3], "x": 4, "y": 3.7},
|
||||
{"matrix": [3, 4], "x": 5, "y": 3.7},
|
||||
{"matrix": [3, 5], "x": 6, "y": 3.2, "h": 1.5},
|
||||
|
||||
{"matrix": [7, 5], "x": 8, "y": 3.2, "h": 1.5},
|
||||
{"matrix": [7, 4], "x": 9, "y": 3.7},
|
||||
{"matrix": [7, 3], "x": 10, "y": 3.7}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -1 +0,0 @@
|
||||
DEFAULT_FOLDER = crkbd/rev1
|
@@ -1,96 +0,0 @@
|
||||
/*
|
||||
Copyright 2019 @foostan
|
||||
Copyright 2020 Drashna Jaelre <@drashna>
|
||||
|
||||
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 "rev1.h"
|
||||
|
||||
#ifdef RGB_MATRIX_ENABLE
|
||||
|
||||
// Logical Layout
|
||||
// Columns
|
||||
// Left
|
||||
// 0 1 2 3 4 5
|
||||
// ROWS
|
||||
// 25 24 19 18 11 10 0
|
||||
// 03 02 01
|
||||
// 26 23 20 17 12 09 1
|
||||
// 04 05 06
|
||||
// 27 22 21 16 13 08 2
|
||||
//
|
||||
// 15 14 07 3
|
||||
//
|
||||
// Right
|
||||
// 0 1 2 3 4 5
|
||||
// ROWS
|
||||
// 25 24 19 18 11 10 4
|
||||
// 03 02 01
|
||||
// 26 23 20 17 12 09 5
|
||||
// 04 05 06
|
||||
// 27 22 21 16 13 08 6
|
||||
//
|
||||
// 15 14 07 7
|
||||
//
|
||||
// Physical Layout
|
||||
// Columns
|
||||
// 0 1 2 3 4 5 6 7 8 9 10 11 12 13
|
||||
// ROWS
|
||||
// 25 24 19 18 11 10 10 11 18 19 24 25 0
|
||||
// 03 02 01 01 02 03
|
||||
// 26 23 20 17 12 09 09 12 17 20 23 26 1
|
||||
// 04 04
|
||||
// 27 22 21 16 13 08 08 13 16 21 22 27 2
|
||||
// 05 06 06 05
|
||||
// 15 14 07 07 14 15 3
|
||||
|
||||
led_config_t g_led_config = { {
|
||||
{ 24, 23, 18, 17, 10, 9 },
|
||||
{ 25, 22, 19, 16, 11, 8 },
|
||||
{ 26, 21, 20, 15, 12, 7 },
|
||||
{ NO_LED, NO_LED, NO_LED, 14, 13, 6 },
|
||||
{ 51, 50, 45, 44, 37, 36 },
|
||||
{ 52, 49, 46, 43, 38, 35 },
|
||||
{ 53, 48, 47, 42, 39, 34 },
|
||||
{ NO_LED, NO_LED, NO_LED, 41, 40, 33 }
|
||||
}, {
|
||||
{ 85, 16 }, { 50, 13 }, { 16, 20 }, { 16, 38 }, { 50, 48 }, { 85, 52 }, { 95, 63 },
|
||||
{ 85, 39 }, { 85, 21 }, { 85, 4 }, { 68, 2 }, { 68, 19 }, { 68, 37 }, { 80, 58 },
|
||||
{ 60, 55 }, { 50, 35 }, { 50, 13 }, { 50, 0 }, { 33, 3 }, { 33, 20 }, { 33, 37 },
|
||||
{ 16, 42 }, { 16, 24 }, { 16, 7 }, { 0, 7 }, { 0, 24 }, { 0, 41 }, { 139, 16 },
|
||||
{ 174, 13 }, { 208, 20 }, { 208, 38 }, { 174, 48 }, { 139, 52 }, { 129, 63 }, { 139, 39 },
|
||||
{ 139, 21 }, { 139, 4 }, { 156, 2 }, { 156, 19 }, { 156, 37 }, { 144, 58 }, { 164, 55 },
|
||||
{ 174, 35 }, { 174, 13 }, { 174, 0 }, { 191, 3 }, { 191, 20 }, { 191, 37 }, { 208, 42 },
|
||||
{ 208, 24 }, { 208, 7 }, { 224, 7 }, { 224, 24 }, { 224, 41 }
|
||||
}, {
|
||||
2, 2, 2, 2, 2, 2, 1,
|
||||
4, 4, 4, 4, 4, 4, 1,
|
||||
1, 4, 4, 4, 4, 4, 4,
|
||||
4, 4, 4, 1, 1, 1, 2,
|
||||
2, 2, 2, 2, 2, 1, 4,
|
||||
4, 4, 4, 4, 4, 1, 1,
|
||||
4, 4, 4, 4, 4, 4, 4,
|
||||
4, 4, 1, 1, 1
|
||||
} };
|
||||
|
||||
void suspend_power_down_kb(void) {
|
||||
rgb_matrix_set_suspend_state(true);
|
||||
suspend_power_down_user();
|
||||
}
|
||||
|
||||
void suspend_wakeup_init_kb(void) {
|
||||
rgb_matrix_set_suspend_state(false);
|
||||
suspend_wakeup_init_user();
|
||||
}
|
||||
#endif
|
@@ -1,60 +0,0 @@
|
||||
/*
|
||||
Copyright 2019 @foostan
|
||||
Copyright 2020 Drashna Jaelre <@drashna>
|
||||
|
||||
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
|
||||
|
||||
#include "crkbd.h"
|
||||
#include "quantum.h"
|
||||
|
||||
// clang-format off
|
||||
#define LAYOUT_split_3x6_3( \
|
||||
L00, L01, L02, L03, L04, L05, R00, R01, R02, R03, R04, R05, \
|
||||
L10, L11, L12, L13, L14, L15, R10, R11, R12, R13, R14, R15, \
|
||||
L20, L21, L22, L23, L24, L25, R20, R21, R22, R23, R24, R25, \
|
||||
L30, L31, L32, R30, R31, R32 \
|
||||
) \
|
||||
{ \
|
||||
{ L00, L01, L02, L03, L04, L05 }, \
|
||||
{ L10, L11, L12, L13, L14, L15 }, \
|
||||
{ L20, L21, L22, L23, L24, L25 }, \
|
||||
{ KC_NO, KC_NO, KC_NO, L30, L31, L32 }, \
|
||||
{ R05, R04, R03, R02, R01, R00 }, \
|
||||
{ R15, R14, R13, R12, R11, R10 }, \
|
||||
{ R25, R24, R23, R22, R21, R20 }, \
|
||||
{ KC_NO, KC_NO, KC_NO, R32, R31, R30 } \
|
||||
}
|
||||
|
||||
#define LAYOUT_split_3x5_3( \
|
||||
L00, L01, L02, L03, L04, R00, R01, R02, R03, R04, \
|
||||
L10, L11, L12, L13, L14, R10, R11, R12, R13, R14, \
|
||||
L20, L21, L22, L23, L24, R20, R21, R22, R23, R24, \
|
||||
L30, L31, L32, R30, R31, R32 \
|
||||
) \
|
||||
{ \
|
||||
{ KC_NO, L00, L01, L02, L03, L04 }, \
|
||||
{ KC_NO, L10, L11, L12, L13, L14 }, \
|
||||
{ KC_NO, L20, L21, L22, L23, L24 }, \
|
||||
{ KC_NO, KC_NO, KC_NO, L30, L31, L32 }, \
|
||||
{ KC_NO, R04, R03, R02, R01, R00 }, \
|
||||
{ KC_NO, R14, R13, R12, R11, R10 }, \
|
||||
{ KC_NO, R24, R23, R22, R21, R20 }, \
|
||||
{ KC_NO, KC_NO, KC_NO, R32, R31, R30 } \
|
||||
}
|
||||
|
||||
|
||||
#define LAYOUT LAYOUT_split_3x6_3
|
@@ -1 +0,0 @@
|
||||
SPLIT_KEYBOARD = yes
|
||||
|
@@ -1,21 +1,6 @@
|
||||
# Build Options
|
||||
# change yes to no to disable
|
||||
#
|
||||
BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite
|
||||
MOUSEKEY_ENABLE = yes # Mouse keys
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control
|
||||
CONSOLE_ENABLE = no # Console for debug
|
||||
COMMAND_ENABLE = no # Commands for debug and configuration
|
||||
NKRO_ENABLE = yes # Enable N-Key Rollover
|
||||
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
|
||||
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
|
||||
AUDIO_ENABLE = no # Audio output
|
||||
RGB_MATRIX_ENABLE = no
|
||||
RGB_MATRIX_DRIVER = WS2812
|
||||
LTO_ENABLE = yes
|
||||
|
||||
# if firmware size over limit, try this option
|
||||
# LTO_ENABLE = yes
|
||||
|
||||
DEFAULT_FOLDER = crkbd/rev1
|
||||
|
||||
|
Reference in New Issue
Block a user