From ed1f2f80ce35ef7274eb1f44673057dd57e0acda Mon Sep 17 00:00:00 2001 From: Jonavin Date: Thu, 2 Sep 2021 12:51:55 -0400 Subject: [PATCH 01/24] fix NKRO - switch to get_mods() --- .../keebio/quefrency/keymaps/jonavin/keymap.c | 12 ++++++------ .../mechwild/mercutio/keymaps/jonavin/keymap.c | 14 +++++++------- .../mechwild/murphpad/keymaps/jonavin/keymap.c | 14 +++++++------- users/jonavin/jonavin.c | 16 ++++++++-------- users/jonavin/readme.md | 3 +-- 5 files changed, 29 insertions(+), 30 deletions(-) diff --git a/keyboards/keebio/quefrency/keymaps/jonavin/keymap.c b/keyboards/keebio/quefrency/keymaps/jonavin/keymap.c index 721148f4dc3e..e2ce8992f17d 100644 --- a/keyboards/keebio/quefrency/keymaps/jonavin/keymap.c +++ b/keyboards/keebio/quefrency/keymaps/jonavin/keymap.c @@ -69,25 +69,25 @@ bool encoder_update_user(uint8_t index, bool clockwise) { default: // other encoder (Top right) if ( clockwise ) { - if (keyboard_report->mods & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, Page up + if (get_mods() & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, Page up unregister_mods(MOD_BIT(KC_LSFT)); register_code(KC_PGDN); register_mods(MOD_BIT(KC_LSFT)); - } else if (keyboard_report->mods & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next word + } else if (get_mods() & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next word tap_code16(LCTL(KC_RGHT)); - } else if (keyboard_report->mods & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next track + } else if (get_mods() & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next track tap_code(KC_MEDIA_NEXT_TRACK); } else { tap_code(KC_VOLU); // Otherwise it just changes volume } } else { - if (keyboard_report->mods & MOD_BIT(KC_LSFT) ) { + if (get_mods() & MOD_BIT(KC_LSFT) ) { unregister_mods(MOD_BIT(KC_LSFT)); register_code(KC_PGUP); register_mods(MOD_BIT(KC_LSFT)); - } else if (keyboard_report->mods & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate previous word + } else if (get_mods() & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate previous word tap_code16(LCTL(KC_LEFT)); - } else if (keyboard_report->mods & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media previous track + } else if (get_mods() & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media previous track tap_code(KC_MEDIA_PREV_TRACK); } else { tap_code(KC_VOLD); diff --git a/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c b/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c index 74811cbc351b..92377fd5a567 100755 --- a/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c @@ -117,7 +117,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { case 0: // This is the only encoder right now, keeping for consistency switch(get_highest_layer(layer_state)){ // special handling per layer case _FN1: // on Fn layer select what the encoder does when pressed - if (!keyboard_report->mods) { + if (!get_mods()) { if ( clockwise ) { if ( selectedkey_idx < MAX_KEYSELECTION-1) { selectedkey_idx ++; @@ -138,27 +138,27 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { } default: // all other layers if ( clockwise ) { - if (keyboard_report->mods & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers + if (get_mods() & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers if(selected_layer < 3) { selected_layer ++; layer_move(selected_layer); } - } else if (keyboard_report->mods & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next word + } else if (get_mods() & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next word tap_code16(LCTL(KC_RGHT)); - } else if (keyboard_report->mods & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next track + } else if (get_mods() & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next track tap_code(KC_MEDIA_NEXT_TRACK); } else { tap_code(KC_VOLU); // Otherwise it just changes volume } } else if ( !clockwise ) { - if (keyboard_report->mods & MOD_BIT(KC_LSFT) ) { + if (get_mods() & MOD_BIT(KC_LSFT) ) { if (selected_layer > 0) { selected_layer --; layer_move(selected_layer); } - } else if (keyboard_report->mods & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate previous word + } else if (get_mods() & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate previous word tap_code16(LCTL(KC_LEFT)); - } else if (keyboard_report->mods & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media previous track + } else if (get_mods() & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media previous track tap_code(KC_MEDIA_PREV_TRACK); } else { tap_code(KC_VOLD); diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c index 001abc502723..8a57e6f3a4af 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c @@ -155,7 +155,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { case 0: // This is the only encoder right now, keeping for consistency switch(get_highest_layer(layer_state)){ // special handling per layer case _FN1: // on Fn layer select what the encoder does when pressed - if (!keyboard_report->mods) { + if (!get_mods()) { if ( clockwise ) { if ( selectedkey_idx < MAX_KEYSELECTION-1) { selectedkey_idx ++; @@ -176,27 +176,27 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { } default: // all other layers if ( clockwise ) { - if (keyboard_report->mods & MOD_BIT(KC_RSFT) ) { // If you are holding Right Shift, encoder changes layers + if (get_mods() & MOD_BIT(KC_RSFT) ) { // If you are holding Right Shift, encoder changes layers if(selected_layer < (DYNAMIC_KEYMAP_LAYER_COUNT-1)) { selected_layer ++; layer_move(selected_layer); } - } else if (keyboard_report->mods & MOD_BIT(KC_RCTL)) { // if holding Right Ctrl, navigate next word + } else if (get_mods() & MOD_BIT(KC_RCTL)) { // if holding Right Ctrl, navigate next word tap_code16(LCTL(KC_RGHT)); - } else if (keyboard_report->mods & MOD_BIT(KC_RALT)) { // if holding Right Alt, change media next track + } else if (get_mods() & MOD_BIT(KC_RALT)) { // if holding Right Alt, change media next track tap_code(KC_MEDIA_NEXT_TRACK); } else { tap_code(KC_VOLU); // Otherwise it just changes volume } } else if ( !clockwise ) { - if (keyboard_report->mods & MOD_BIT(KC_RSFT) ) { + if (get_mods() & MOD_BIT(KC_RSFT) ) { if (selected_layer > 0) { selected_layer --; layer_move(selected_layer); } - } else if (keyboard_report->mods & MOD_BIT(KC_RCTL)) { // if holding Right Ctrl, navigate previous word + } else if (get_mods() & MOD_BIT(KC_RCTL)) { // if holding Right Ctrl, navigate previous word tap_code16(LCTL(KC_LEFT)); - } else if (keyboard_report->mods & MOD_BIT(KC_RALT)) { // if holding Right Alt, change media previous track + } else if (get_mods() & MOD_BIT(KC_RALT)) { // if holding Right Alt, change media previous track tap_code(KC_MEDIA_PREV_TRACK); } else { tap_code(KC_VOLD); diff --git a/users/jonavin/jonavin.c b/users/jonavin/jonavin.c index bd6c55e9feda..e7baa6ec587f 100644 --- a/users/jonavin/jonavin.c +++ b/users/jonavin/jonavin.c @@ -120,18 +120,18 @@ bool encoder_update_user(uint8_t index, bool clockwise) { if (!encoder_update_keymap(index, clockwise)) { return false; } if (index != ENCODER_DEFAULTACTIONS_INDEX) {return true;} // exit if the index doesn't match if ( clockwise ) { - if (keyboard_report->mods & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers + if (get_mods() & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers if(selected_layer < (DYNAMIC_KEYMAP_LAYER_COUNT - 1)) { selected_layer ++; layer_move(selected_layer); } - } else if (keyboard_report->mods & MOD_BIT(KC_RSFT) ) { // If you are holding R shift, Page up + } else if (get_mods() & MOD_BIT(KC_RSFT) ) { // If you are holding R shift, Page up unregister_mods(MOD_BIT(KC_RSFT)); register_code(KC_PGDN); register_mods(MOD_BIT(KC_RSFT)); - } else if (keyboard_report->mods & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next word + } else if (get_mods() & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next word tap_code16(LCTL(KC_RGHT)); - } else if (keyboard_report->mods & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next track + } else if (get_mods() & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next track tap_code(KC_MEDIA_NEXT_TRACK); } else { switch (selected_layer) { @@ -146,18 +146,18 @@ bool encoder_update_user(uint8_t index, bool clockwise) { } } } else { - if (keyboard_report->mods & MOD_BIT(KC_LSFT) ) { + if (get_mods() & MOD_BIT(KC_LSFT) ) { if (selected_layer > 0) { selected_layer --; layer_move(selected_layer); } - } else if (keyboard_report->mods & MOD_BIT(KC_RSFT) ) { + } else if (get_mods() & MOD_BIT(KC_RSFT) ) { unregister_mods(MOD_BIT(KC_RSFT)); register_code(KC_PGUP); register_mods(MOD_BIT(KC_RSFT)); - } else if (keyboard_report->mods & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate previous word + } else if (get_mods() & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate previous word tap_code16(LCTL(KC_LEFT)); - } else if (keyboard_report->mods & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media previous track + } else if (get_mods() & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media previous track tap_code(KC_MEDIA_PREV_TRACK); } else { switch (selected_layer) { diff --git a/users/jonavin/readme.md b/users/jonavin/readme.md index 97fff6520cb6..c029796b4e59 100644 --- a/users/jonavin/readme.md +++ b/users/jonavin/readme.md @@ -65,11 +65,10 @@ KEYMAP LEVEL ADDITIONAL PROCESSING FUNCTIONS void keyboard_post_init_keymap(void) LIST OF COMPATIBLE KEYMAPS - - gmmk/pro - gmmk/pro/ansi - keebio/quefrency/rev3 - mechwild/mercutio - - mechwild/murphpad (*) + - mechwild/murphpad - mechwild/OBE (*) - nopunin10did/kastenwagen (*) From d90ba04a2c92e7272264ae17dadc93d08887ae7c Mon Sep 17 00:00:00 2001 From: Jonavin Date: Fri, 3 Sep 2021 14:31:42 -0400 Subject: [PATCH 02/24] refactor encoder action for better readability --- users/jonavin/jonavin.c | 126 ++++++++++++++++++++++------------------ users/jonavin/jonavin.h | 10 ++++ 2 files changed, 80 insertions(+), 56 deletions(-) diff --git a/users/jonavin/jonavin.c b/users/jonavin/jonavin.c index e7baa6ec587f..7393d9cd81de 100644 --- a/users/jonavin/jonavin.c +++ b/users/jonavin/jonavin.c @@ -104,7 +104,7 @@ along with this program. If not, see . #endif // IDLE_TIMEOUT_ENABLE -#if defined(ENCODER_ENABLE) && defined(ENCODER_DEFAULTACTIONS_ENABLE) // Encoder Functionality +#ifdef ENCODER_ENABLE #ifndef DYNAMIC_KEYMAP_LAYER_COUNT #define DYNAMIC_KEYMAP_LAYER_COUNT 4 //default in case this is not already defined elsewhere #endif @@ -112,69 +112,83 @@ along with this program. If not, see . #define ENCODER_DEFAULTACTIONS_INDEX 0 // can select encoder index if there are multiple encoders #endif -uint8_t selected_layer = 0; + uint8_t selected_layer = 0; -__attribute__((weak)) bool encoder_update_keymap(uint8_t index, bool clockwise) { return true; } + void encoder_action_volume(bool clockwise) { + if (clockwise) + tap_code(KC_VOLU); + else + tap_code(KC_VOLD); + } -bool encoder_update_user(uint8_t index, bool clockwise) { - if (!encoder_update_keymap(index, clockwise)) { return false; } - if (index != ENCODER_DEFAULTACTIONS_INDEX) {return true;} // exit if the index doesn't match - if ( clockwise ) { - if (get_mods() & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers - if(selected_layer < (DYNAMIC_KEYMAP_LAYER_COUNT - 1)) { - selected_layer ++; - layer_move(selected_layer); - } - } else if (get_mods() & MOD_BIT(KC_RSFT) ) { // If you are holding R shift, Page up - unregister_mods(MOD_BIT(KC_RSFT)); - register_code(KC_PGDN); - register_mods(MOD_BIT(KC_RSFT)); - } else if (get_mods() & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next word - tap_code16(LCTL(KC_RGHT)); - } else if (get_mods() & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next track - tap_code(KC_MEDIA_NEXT_TRACK); - } else { - switch (selected_layer) { - case _FN1: - #ifdef IDLE_TIMEOUT_ENABLE - timeout_update_threshold(true); - #endif - break; - default: - tap_code(KC_VOLU); // Otherwise it just changes volume - break; - } + void encoder_action_mediatrack(bool clockwise) { + if (clockwise) + tap_code(KC_MEDIA_NEXT_TRACK); + else + tap_code(KC_MEDIA_PREV_TRACK); + } + + void encoder_action_navword(bool clockwise) { + if (clockwise) + tap_code16(LCTL(KC_RGHT)); + else + tap_code16(LCTL(KC_LEFT)); + } + + void encoder_action_navpage(bool clockwise) { + if (clockwise) + tap_code16(KC_PGUP); + else + tap_code16(KC_PGDN); + } + + void encoder_action_layerchange(bool clockwise) { + if (clockwise) { + if(selected_layer < (DYNAMIC_KEYMAP_LAYER_COUNT - 1)) { + selected_layer ++; + layer_move(selected_layer); } } else { - if (get_mods() & MOD_BIT(KC_LSFT) ) { - if (selected_layer > 0) { - selected_layer --; - layer_move(selected_layer); - } - } else if (get_mods() & MOD_BIT(KC_RSFT) ) { - unregister_mods(MOD_BIT(KC_RSFT)); - register_code(KC_PGUP); - register_mods(MOD_BIT(KC_RSFT)); - } else if (get_mods() & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate previous word - tap_code16(LCTL(KC_LEFT)); - } else if (get_mods() & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media previous track - tap_code(KC_MEDIA_PREV_TRACK); - } else { - switch (selected_layer) { - case _FN1: - #ifdef IDLE_TIMEOUT_ENABLE - timeout_update_threshold(false); - #endif - break; - default: - tap_code(KC_VOLD); - break; - } + if (selected_layer > 0) { + selected_layer --; + layer_move(selected_layer); } } + } +#endif // ENCODER_ENABLE + +#if defined(ENCODER_ENABLE) && defined(ENCODER_DEFAULTACTIONS_ENABLE) // Encoder Functionality + +__attribute__((weak)) bool encoder_update_keymap(uint8_t index, bool clockwise) { return true; } - return true; +bool encoder_update_user(uint8_t index, bool clockwise) { + if (!encoder_update_keymap(index, clockwise)) { return false; } + if (index != ENCODER_DEFAULTACTIONS_INDEX) {return true;} // exit if the index doesn't match + uint8_t mods_state = get_mods(); + if (mods_state & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers + encoder_action_layerchange(clockwise); + } else if (mods_state & MOD_BIT(KC_RSFT) ) { // If you are holding R shift, Page up/dn + unregister_mods(MOD_BIT(KC_RSFT)); + encoder_action_navpage(clockwise); + register_mods(MOD_BIT(KC_RSFT)); + } else if (mods_state & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next/prev word + encoder_action_navword(clockwise); + } else if (mods_state & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next/prev track + encoder_action_mediatrack(clockwise); + } else { + switch(get_highest_layer(layer_state)) { + case _FN1: + #ifdef IDLE_TIMEOUT_ENABLE + timeout_update_threshold(clockwise); + #endif + break; + default: + encoder_action_volume(clockwise); // Otherwise it just changes volume + break; + } } + return true; +} #endif // ENCODER_ENABLE diff --git a/users/jonavin/jonavin.h b/users/jonavin/jonavin.h index 5f467bc845ff..f5c346708ae8 100644 --- a/users/jonavin/jonavin.h +++ b/users/jonavin/jonavin.h @@ -58,6 +58,16 @@ enum custom_user_keycodes { #endif // TD_LSFT_CAPSLOCK_ENABLE +// ENCODER ACTIONS +#ifdef ENCODER_ENABLE + void encoder_action_volume(bool clockwise); + void encoder_action_mediatrack(bool clockwise); + void encoder_action_navword(bool clockwise); + void encoder_action_navpage(bool clockwise); + void encoder_action_layerchange(bool clockwise); +#endif // ENCODER_ENABLE + + #ifdef RGB_MATRIX_ENABLE //RGB custom colours #define RGB_GODSPEED 0x00, 0xE4, 0xFF // colour for matching keycaps From 5b7abe30b23f521fbe14f04ec383c19b3d784fce Mon Sep 17 00:00:00 2001 From: Jonavin Date: Fri, 3 Sep 2021 15:13:13 -0400 Subject: [PATCH 03/24] refactor for better readability --- .../keebio/quefrency/keymaps/jonavin/keymap.c | 45 +++------ .../mercutio/keymaps/jonavin/keymap.c | 83 ++++++++-------- .../murphpad/keymaps/jonavin/keymap.c | 99 ++++++++++--------- users/jonavin/jonavin.c | 67 ++++++------- 4 files changed, 140 insertions(+), 154 deletions(-) diff --git a/keyboards/keebio/quefrency/keymaps/jonavin/keymap.c b/keyboards/keebio/quefrency/keymaps/jonavin/keymap.c index e2ce8992f17d..09a8f06d7c28 100644 --- a/keyboards/keebio/quefrency/keymaps/jonavin/keymap.c +++ b/keyboards/keebio/quefrency/keymaps/jonavin/keymap.c @@ -58,40 +58,23 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { #ifdef ENCODER_ENABLE // Encoder Functionality bool encoder_update_user(uint8_t index, bool clockwise) { - switch (index) - { + uint8_t mods_state = get_mods(); + switch (index) { case 0: // first encoder (Left Macro set) - if (clockwise) { - tap_code(KC_PGDN); - } else { - tap_code(KC_PGUP); - } + encoder_action_navpage(clockwise) + break; default: // other encoder (Top right) - if ( clockwise ) { - if (get_mods() & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, Page up - unregister_mods(MOD_BIT(KC_LSFT)); - register_code(KC_PGDN); - register_mods(MOD_BIT(KC_LSFT)); - } else if (get_mods() & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next word - tap_code16(LCTL(KC_RGHT)); - } else if (get_mods() & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next track - tap_code(KC_MEDIA_NEXT_TRACK); - } else { - tap_code(KC_VOLU); // Otherwise it just changes volume - } - } else { - if (get_mods() & MOD_BIT(KC_LSFT) ) { - unregister_mods(MOD_BIT(KC_LSFT)); - register_code(KC_PGUP); - register_mods(MOD_BIT(KC_LSFT)); - } else if (get_mods() & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate previous word - tap_code16(LCTL(KC_LEFT)); - } else if (get_mods() & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media previous track - tap_code(KC_MEDIA_PREV_TRACK); - } else { - tap_code(KC_VOLD); - } + if (mods_state & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, Page up + unregister_mods(MOD_BIT(KC_LSFT)); + encoder_action_navpage(clockwise); + register_mods(MOD_BIT(KC_LSFT)); + } else if (mods_state & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next/prev word + encoder_action_navword(clockwise); + } else if (mods_state & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next/prev track + encoder_action_mediatrack(clockwise); + } else { + encoder_action_volume(clockwise); // Otherwise it just changes volume } break; } diff --git a/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c b/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c index 92377fd5a567..d66a1ae67fb0 100755 --- a/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c @@ -108,61 +108,62 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { #ifdef ENCODER_ENABLE // Encoder Functionality uint8_t selected_layer = 0; + void encoder_action_layerchange(bool clockwise) { + if (clockwise) { + if(selected_layer < (DYNAMIC_KEYMAP_LAYER_COUNT - 1)) { + selected_layer ++; + layer_move(selected_layer); + } + } else { + if (selected_layer > 0) { + selected_layer --; + layer_move(selected_layer); + } + } + } + + void encoder_action_selectkey(bool clockwise) { + if ( clockwise ) { + if ( selectedkey_idx < MAX_KEYSELECTION-1) { + selectedkey_idx ++; + } else { + // do nothing + } + } else if ( !clockwise ) { + if ( selectedkey_idx > 0){ + selectedkey_idx --; + } else { + // do nothing + } + } + set_selectedkey(selectedkey_idx); + } + bool encoder_update_user(uint8_t index, bool clockwise) { #ifdef OLED_ENABLE oled_clear(); oled_render(); #endif + uint8_t mods_state = get_mods(); switch (index) { case 0: // This is the only encoder right now, keeping for consistency switch(get_highest_layer(layer_state)){ // special handling per layer case _FN1: // on Fn layer select what the encoder does when pressed - if (!get_mods()) { - if ( clockwise ) { - if ( selectedkey_idx < MAX_KEYSELECTION-1) { - selectedkey_idx ++; - } else { - // do nothing - } - } else if ( !clockwise ) { - if ( selectedkey_idx > 0){ - selectedkey_idx --; - } else { - // do nothing - } - } - set_selectedkey(selectedkey_idx); + if (!mods_state) { + encoder_action_selectkey(clockwise); break; } else { // continue to default } default: // all other layers - if ( clockwise ) { - if (get_mods() & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers - if(selected_layer < 3) { - selected_layer ++; - layer_move(selected_layer); - } - } else if (get_mods() & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next word - tap_code16(LCTL(KC_RGHT)); - } else if (get_mods() & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next track - tap_code(KC_MEDIA_NEXT_TRACK); - } else { - tap_code(KC_VOLU); // Otherwise it just changes volume - } - } else if ( !clockwise ) { - if (get_mods() & MOD_BIT(KC_LSFT) ) { - if (selected_layer > 0) { - selected_layer --; - layer_move(selected_layer); - } - } else if (get_mods() & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate previous word - tap_code16(LCTL(KC_LEFT)); - } else if (get_mods() & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media previous track - tap_code(KC_MEDIA_PREV_TRACK); - } else { - tap_code(KC_VOLD); - } + if (mods_state & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers + encoder_action_layerchange(clockwise); + } else if (mods_state & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next/prev word + encoder_action_navword(clockwise); + } else if (mods_state & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next/prev track + encoder_action_mediatrack(clockwise); + } else { + encoder_action_volume(clockwise); // Otherwise it just changes volume } break; } diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c index 8a57e6f3a4af..fddbbd7f43b3 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c @@ -146,65 +146,66 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { #ifdef ENCODER_ENABLE // Encoder Functionality uint8_t selected_layer = 0; + void encoder_action_layerchange(bool clockwise) { + if (clockwise) { + if(selected_layer < (DYNAMIC_KEYMAP_LAYER_COUNT - 1)) { + selected_layer ++; + layer_move(selected_layer); + } + } else { + if (selected_layer > 0) { + selected_layer --; + layer_move(selected_layer); + } + } + } + + void encoder_action_selectkey(bool clockwise) { + if ( clockwise ) { + if ( selectedkey_idx < MAX_KEYSELECTION-1) { + selectedkey_idx ++; + } else { + // do nothing + } + } else if ( !clockwise ) { + if ( selectedkey_idx > 0){ + selectedkey_idx --; + } else { + // do nothing + } + } + set_selectedkey(selectedkey_idx); + } + bool encoder_update_user(uint8_t index, bool clockwise) { #ifdef OLED_ENABLE oled_clear(); oled_render(); #endif + uint8_t mods_state = get_mods(); switch (index) { case 0: // This is the only encoder right now, keeping for consistency - switch(get_highest_layer(layer_state)){ // special handling per layer - case _FN1: // on Fn layer select what the encoder does when pressed - if (!get_mods()) { - if ( clockwise ) { - if ( selectedkey_idx < MAX_KEYSELECTION-1) { - selectedkey_idx ++; - } else { - // do nothing - } - } else if ( !clockwise ) { - if ( selectedkey_idx > 0){ - selectedkey_idx --; - } else { - // do nothing - } - } - set_selectedkey(selectedkey_idx); - break; - } else { - // continue to default - } - default: // all other layers - if ( clockwise ) { - if (get_mods() & MOD_BIT(KC_RSFT) ) { // If you are holding Right Shift, encoder changes layers - if(selected_layer < (DYNAMIC_KEYMAP_LAYER_COUNT-1)) { - selected_layer ++; - layer_move(selected_layer); - } - } else if (get_mods() & MOD_BIT(KC_RCTL)) { // if holding Right Ctrl, navigate next word - tap_code16(LCTL(KC_RGHT)); - } else if (get_mods() & MOD_BIT(KC_RALT)) { // if holding Right Alt, change media next track - tap_code(KC_MEDIA_NEXT_TRACK); - } else { - tap_code(KC_VOLU); // Otherwise it just changes volume - } - } else if ( !clockwise ) { - if (get_mods() & MOD_BIT(KC_RSFT) ) { - if (selected_layer > 0) { - selected_layer --; - layer_move(selected_layer); - } - } else if (get_mods() & MOD_BIT(KC_RCTL)) { // if holding Right Ctrl, navigate previous word - tap_code16(LCTL(KC_LEFT)); - } else if (get_mods() & MOD_BIT(KC_RALT)) { // if holding Right Alt, change media previous track - tap_code(KC_MEDIA_PREV_TRACK); - } else { - tap_code(KC_VOLD); - } - } + switch(get_highest_layer(layer_state)){ // special handling per layer + case _FN1: // on Fn layer select what the encoder does when pressed + if (!mods_state) { + encoder_action_selectkey(clockwise); break; + } else { + // continue to default + } + default: // all other layers + if (mods_state & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers + encoder_action_layerchange(clockwise); + } else if (mods_state & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next/prev word + encoder_action_navword(clockwise); + } else if (mods_state & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next/prev track + encoder_action_mediatrack(clockwise); + } else { + encoder_action_volume(clockwise); // Otherwise it just changes volume } break; + } + break; } return true; } diff --git a/users/jonavin/jonavin.c b/users/jonavin/jonavin.c index 7393d9cd81de..a17f8dbafae7 100644 --- a/users/jonavin/jonavin.c +++ b/users/jonavin/jonavin.c @@ -112,8 +112,6 @@ along with this program. If not, see . #define ENCODER_DEFAULTACTIONS_INDEX 0 // can select encoder index if there are multiple encoders #endif - uint8_t selected_layer = 0; - void encoder_action_volume(bool clockwise) { if (clockwise) tap_code(KC_VOLU); @@ -142,6 +140,14 @@ along with this program. If not, see . tap_code16(KC_PGDN); } +#endif // ENCODER_ENABLE + +#if defined(ENCODER_ENABLE) && defined(ENCODER_DEFAULTACTIONS_ENABLE) // Encoder Functionality + + __attribute__((weak)) bool encoder_update_keymap(uint8_t index, bool clockwise) { return true; } + + uint8_t selected_layer = 0; + void encoder_action_layerchange(bool clockwise) { if (clockwise) { if(selected_layer < (DYNAMIC_KEYMAP_LAYER_COUNT - 1)) { @@ -155,40 +161,35 @@ along with this program. If not, see . } } } -#endif // ENCODER_ENABLE - -#if defined(ENCODER_ENABLE) && defined(ENCODER_DEFAULTACTIONS_ENABLE) // Encoder Functionality -__attribute__((weak)) bool encoder_update_keymap(uint8_t index, bool clockwise) { return true; } - -bool encoder_update_user(uint8_t index, bool clockwise) { - if (!encoder_update_keymap(index, clockwise)) { return false; } - if (index != ENCODER_DEFAULTACTIONS_INDEX) {return true;} // exit if the index doesn't match - uint8_t mods_state = get_mods(); - if (mods_state & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers - encoder_action_layerchange(clockwise); - } else if (mods_state & MOD_BIT(KC_RSFT) ) { // If you are holding R shift, Page up/dn - unregister_mods(MOD_BIT(KC_RSFT)); - encoder_action_navpage(clockwise); - register_mods(MOD_BIT(KC_RSFT)); - } else if (mods_state & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next/prev word - encoder_action_navword(clockwise); - } else if (mods_state & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next/prev track - encoder_action_mediatrack(clockwise); - } else { - switch(get_highest_layer(layer_state)) { - case _FN1: - #ifdef IDLE_TIMEOUT_ENABLE - timeout_update_threshold(clockwise); - #endif - break; - default: - encoder_action_volume(clockwise); // Otherwise it just changes volume - break; + bool encoder_update_user(uint8_t index, bool clockwise) { + if (!encoder_update_keymap(index, clockwise)) { return false; } + if (index != ENCODER_DEFAULTACTIONS_INDEX) {return true;} // exit if the index doesn't match + uint8_t mods_state = get_mods(); + if (mods_state & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers + encoder_action_layerchange(clockwise); + } else if (mods_state & MOD_BIT(KC_RSFT) ) { // If you are holding R shift, Page up/dn + unregister_mods(MOD_BIT(KC_RSFT)); + encoder_action_navpage(clockwise); + register_mods(MOD_BIT(KC_RSFT)); + } else if (mods_state & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next/prev word + encoder_action_navword(clockwise); + } else if (mods_state & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next/prev track + encoder_action_mediatrack(clockwise); + } else { + switch(get_highest_layer(layer_state)) { + case _FN1: + #ifdef IDLE_TIMEOUT_ENABLE + timeout_update_threshold(clockwise); + #endif + break; + default: + encoder_action_volume(clockwise); // Otherwise it just changes volume + break; + } } + return true; } - return true; -} #endif // ENCODER_ENABLE From 950a232003761cfe81c74c5c3d3c7ceeeb55300e Mon Sep 17 00:00:00 2001 From: Jonavin Date: Fri, 3 Sep 2021 15:24:33 -0400 Subject: [PATCH 04/24] refactor fix - murphpad --- keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c index fddbbd7f43b3..179711de52af 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c @@ -194,11 +194,11 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { // continue to default } default: // all other layers - if (mods_state & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers + if (mods_state & MOD_BIT(KC_RSFT) ) { // If you are holding R shift, encoder changes layers encoder_action_layerchange(clockwise); - } else if (mods_state & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next/prev word + } else if (mods_state & MOD_BIT(KC_RCTL)) { // if holding Right Ctrl, navigate next/prev word encoder_action_navword(clockwise); - } else if (mods_state & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next/prev track + } else if (mods_state & MOD_BIT(KC_RALT)) { // if holding Right Alt, change media next/prev track encoder_action_mediatrack(clockwise); } else { encoder_action_volume(clockwise); // Otherwise it just changes volume From 5dab9430077b0bc19f27cbc4dae3df87888ab2f7 Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Fri, 3 Sep 2021 18:47:56 -0400 Subject: [PATCH 05/24] refactor - encoder layer switching --- .../keebio/quefrency/keymaps/jonavin/keymap.c | 42 ++++++++++--------- .../mercutio/keymaps/jonavin/keymap.c | 22 ++-------- .../murphpad/keymaps/jonavin/keymap.c | 20 +-------- users/jonavin/jonavin.c | 16 ++++--- users/jonavin/jonavin.h | 2 + 5 files changed, 39 insertions(+), 63 deletions(-) diff --git a/keyboards/keebio/quefrency/keymaps/jonavin/keymap.c b/keyboards/keebio/quefrency/keymaps/jonavin/keymap.c index 09a8f06d7c28..415f554e2693 100644 --- a/keyboards/keebio/quefrency/keymaps/jonavin/keymap.c +++ b/keyboards/keebio/quefrency/keymaps/jonavin/keymap.c @@ -57,29 +57,31 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { }; #ifdef ENCODER_ENABLE // Encoder Functionality -bool encoder_update_user(uint8_t index, bool clockwise) { - uint8_t mods_state = get_mods(); - switch (index) { - case 0: // first encoder (Left Macro set) - encoder_action_navpage(clockwise) - break; - - default: // other encoder (Top right) - if (mods_state & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, Page up - unregister_mods(MOD_BIT(KC_LSFT)); + bool encoder_update_user(uint8_t index, bool clockwise) { + uint8_t mods_state = get_mods(); + switch (index) { + case 0: // first encoder (Left Macro set) encoder_action_navpage(clockwise); - register_mods(MOD_BIT(KC_LSFT)); - } else if (mods_state & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next/prev word - encoder_action_navword(clockwise); - } else if (mods_state & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next/prev track - encoder_action_mediatrack(clockwise); - } else { - encoder_action_volume(clockwise); // Otherwise it just changes volume + break; + + default: // other encoder (Top right) + if (mods_state & MOD_BIT(KC_LSFT) ) { // If you are holding Left shift, change layers + encoder_action_layerchange(clockwise); + } else if (mods_state & MOD_BIT(KC_RSFT) ) { // If you are holding Right shift, Page up + unregister_mods(MOD_BIT(KC_RSFT)); + encoder_action_navpage(clockwise); + register_mods(MOD_BIT(KC_RSFT)); + } else if (mods_state & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next/prev word + encoder_action_navword(clockwise); + } else if (mods_state & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next/prev track + encoder_action_mediatrack(clockwise); + } else { + encoder_action_volume(clockwise); // Otherwise it just changes volume + } + break; } - break; + return true; } - return true; -} #endif #ifdef RGBLIGHT_ENABLE diff --git a/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c b/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c index d66a1ae67fb0..22d26db3c2ee 100755 --- a/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c @@ -106,22 +106,6 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { #ifdef ENCODER_ENABLE // Encoder Functionality - uint8_t selected_layer = 0; - - void encoder_action_layerchange(bool clockwise) { - if (clockwise) { - if(selected_layer < (DYNAMIC_KEYMAP_LAYER_COUNT - 1)) { - selected_layer ++; - layer_move(selected_layer); - } - } else { - if (selected_layer > 0) { - selected_layer --; - layer_move(selected_layer); - } - } - } - void encoder_action_selectkey(bool clockwise) { if ( clockwise ) { if ( selectedkey_idx < MAX_KEYSELECTION-1) { @@ -206,7 +190,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { void oled_task_user(void) { - if ( IS_HOST_LED_OFF(USB_LED_NUM_LOCK) && IS_HOST_LED_OFF(USB_LED_CAPS_LOCK) && selected_layer == 0 && get_highest_layer(layer_state) == 0 ) { + if ( IS_HOST_LED_OFF(USB_LED_NUM_LOCK) && IS_HOST_LED_OFF(USB_LED_CAPS_LOCK) && get_selected_layer() == 0 && get_highest_layer(layer_state) == 0 ) { render_name(); clear_screen = true; } else { @@ -218,7 +202,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { render_logo(); oled_set_cursor(8,2); char fn_str[12]; - switch(selected_layer){ + switch(get_selected_layer()){ case 0: oled_write_P(PSTR("BASE"), false); break; @@ -238,7 +222,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { } oled_write_P(keymap_config.no_gui ? PSTR(" WL") : PSTR(" "), false); oled_set_cursor(8,3); - if (get_highest_layer(layer_state) == selected_layer) { + if (get_highest_layer(layer_state) == get_selected_layer()) { oled_write_P(PSTR(" "), false); } else { switch (get_highest_layer(layer_state)) { diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c index 179711de52af..39e6ac87e4c7 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c @@ -144,22 +144,6 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { #ifdef ENCODER_ENABLE // Encoder Functionality - uint8_t selected_layer = 0; - - void encoder_action_layerchange(bool clockwise) { - if (clockwise) { - if(selected_layer < (DYNAMIC_KEYMAP_LAYER_COUNT - 1)) { - selected_layer ++; - layer_move(selected_layer); - } - } else { - if (selected_layer > 0) { - selected_layer --; - layer_move(selected_layer); - } - } - } - void encoder_action_selectkey(bool clockwise) { if ( clockwise ) { if ( selectedkey_idx < MAX_KEYSELECTION-1) { @@ -233,7 +217,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { render_logo(); oled_set_cursor(8,2); - switch(selected_layer){ + switch(get_selected_layer()){ case _BASE: oled_write_P(PSTR("BASE"), false); break; @@ -258,7 +242,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { } oled_write_P(keymap_config.no_gui ? PSTR(" WL") : PSTR(" "), false); oled_set_cursor(8,3); - if (get_highest_layer(layer_state) == selected_layer) { + if (get_highest_layer(layer_state) == get_selected_layer()) { oled_write_P(PSTR(" "), false); } else { switch (get_highest_layer(layer_state)) { diff --git a/users/jonavin/jonavin.c b/users/jonavin/jonavin.c index a17f8dbafae7..6ecadc7b475f 100644 --- a/users/jonavin/jonavin.c +++ b/users/jonavin/jonavin.c @@ -140,14 +140,13 @@ along with this program. If not, see . tap_code16(KC_PGDN); } -#endif // ENCODER_ENABLE - -#if defined(ENCODER_ENABLE) && defined(ENCODER_DEFAULTACTIONS_ENABLE) // Encoder Functionality - - __attribute__((weak)) bool encoder_update_keymap(uint8_t index, bool clockwise) { return true; } - + // LAYER HANDLING uint8_t selected_layer = 0; + uint8_t get_selected_layer(void) { + return selected_layer; + } + void encoder_action_layerchange(bool clockwise) { if (clockwise) { if(selected_layer < (DYNAMIC_KEYMAP_LAYER_COUNT - 1)) { @@ -161,6 +160,11 @@ along with this program. If not, see . } } } +#endif // ENCODER_ENABLE + +#if defined(ENCODER_ENABLE) && defined(ENCODER_DEFAULTACTIONS_ENABLE) // Encoder Functionality + + __attribute__((weak)) bool encoder_update_keymap(uint8_t index, bool clockwise) { return true; } bool encoder_update_user(uint8_t index, bool clockwise) { if (!encoder_update_keymap(index, clockwise)) { return false; } diff --git a/users/jonavin/jonavin.h b/users/jonavin/jonavin.h index f5c346708ae8..316483940ae6 100644 --- a/users/jonavin/jonavin.h +++ b/users/jonavin/jonavin.h @@ -64,6 +64,8 @@ enum custom_user_keycodes { void encoder_action_mediatrack(bool clockwise); void encoder_action_navword(bool clockwise); void encoder_action_navpage(bool clockwise); + + uint8_t get_selected_layer(void); void encoder_action_layerchange(bool clockwise); #endif // ENCODER_ENABLE From 8c517c0cfd68b53c0238c5c13c8e81411096a7c9 Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Fri, 3 Sep 2021 22:02:49 -0400 Subject: [PATCH 06/24] gmmk pro encoder override defaults --- users/jonavin/jonavin.c | 14 ++++++++++++++ users/jonavin/jonavin.h | 13 +++++++++++++ 2 files changed, 27 insertions(+) diff --git a/users/jonavin/jonavin.c b/users/jonavin/jonavin.c index 6ecadc7b475f..9a71d5939f6f 100644 --- a/users/jonavin/jonavin.c +++ b/users/jonavin/jonavin.c @@ -103,6 +103,20 @@ along with this program. If not, see . } #endif // IDLE_TIMEOUT_ENABLE +#ifdef ENCFUNC_ENABLE + static uint8_t selectedkey_idx = 0; + static keycodedescType selectedkey_rec; + + static uint8_t get_selectedkey_idx(void) { + return selectedkey_idx; + } + + static void set_selectedkey(uint8_t idx) { + // make a copy from PROGMEM + memcpy_P (&selectedkey_rec, &keyselection[idx], sizeof selectedkey_rec); + } +#endif // ENCFUNC_ENABLE + #ifdef ENCODER_ENABLE #ifndef DYNAMIC_KEYMAP_LAYER_COUNT diff --git a/users/jonavin/jonavin.h b/users/jonavin/jonavin.h index 316483940ae6..20b02aa60c1f 100644 --- a/users/jonavin/jonavin.h +++ b/users/jonavin/jonavin.h @@ -58,6 +58,19 @@ enum custom_user_keycodes { #endif // TD_LSFT_CAPSLOCK_ENABLE +// ENC FUNC +#ifdef ENCFUNC_ENABLE + typedef struct { + char keydesc[6]; // this will be displayed on OLED + uint16_t keycode; // this is the keycode that will be sent when activted + } keycodedescType; + + static uint8_t get_selectedkey_idx(void); + static void set_selectedkey(uint8_t idx); + +#endif // ENCFUNC_ENABLE + + // ENCODER ACTIONS #ifdef ENCODER_ENABLE void encoder_action_volume(bool clockwise); From 2db10c7762d9060fac129ec9094265ddb3c769fc Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Fri, 3 Sep 2021 22:11:18 -0400 Subject: [PATCH 07/24] gmmk pro override defaults --- .../gmmk/pro/ansi/keymaps/jonavin/keymap.c | 37 +++++++++++++++++++ .../gmmk/pro/ansi/keymaps/jonavin/rules.mk | 2 +- 2 files changed, 38 insertions(+), 1 deletion(-) diff --git a/keyboards/gmmk/pro/ansi/keymaps/jonavin/keymap.c b/keyboards/gmmk/pro/ansi/keymaps/jonavin/keymap.c index 20a786feb7ec..f37abfac30c3 100644 --- a/keyboards/gmmk/pro/ansi/keymaps/jonavin/keymap.c +++ b/keyboards/gmmk/pro/ansi/keymaps/jonavin/keymap.c @@ -78,6 +78,43 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { #endif // COLEMAK_LAYER_ENABLE }; +#if defined(ENCODER_ENABLE) && !defined(ENCODER_DEFAULTACTIONS_ENABLE) // Encoder Functionality when not using userspace defaults + void encoder_action_rgbhue(bool clockwise) { + if (clockwise) + rgblight_increase_hue_noeeprom(); + else + rgblight_decrease_hue_noeeprom(); + } + + bool encoder_update_user(uint8_t index, bool clockwise) { + uint8_t mods_state = get_mods(); + if (mods_state & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers + encoder_action_layerchange(clockwise); + } else if (mods_state & MOD_BIT(KC_RSFT) ) { // If you are holding R shift, Page up/dn + unregister_mods(MOD_BIT(KC_RSFT)); + encoder_action_navpage(clockwise); + register_mods(MOD_BIT(KC_RSFT)); + } else if (mods_state & MOD_BIT(KC_LCTL)) { // if holding Left Ctrl, navigate next/prev word + encoder_action_navword(clockwise); + } else if (mods_state & MOD_BIT(KC_RCTL)) { // if holding Right Ctrl, change rgb hue/colour + encoder_action_rgbhue(clockwise); + } else if (mods_state & MOD_BIT(KC_LALT)) { // if holding Left Alt, change media next/prev track + encoder_action_mediatrack(clockwise); + } else { + switch(get_highest_layer(layer_state)) { + case _FN1: + #ifdef IDLE_TIMEOUT_ENABLE + timeout_update_threshold(clockwise); + #endif + break; + default: + encoder_action_volume(clockwise); // Otherwise it just changes volume + break; + } + } + return true; + } +#endif // ENCODER_ENABLE && !ENCODER_DEFAULTACTIONS_ENABLE #ifdef RGB_MATRIX_ENABLE // Capslock, Scroll lock and Numlock indicator on Left side lights. diff --git a/keyboards/gmmk/pro/ansi/keymaps/jonavin/rules.mk b/keyboards/gmmk/pro/ansi/keymaps/jonavin/rules.mk index b06ae1b6ad53..81b84eea7ff0 100644 --- a/keyboards/gmmk/pro/ansi/keymaps/jonavin/rules.mk +++ b/keyboards/gmmk/pro/ansi/keymaps/jonavin/rules.mk @@ -6,6 +6,6 @@ BOOTMAGIC_ENABLE = lite # Enable Bootmagic Lite TD_LSFT_CAPSLOCK_ENABLE = yes IDLE_TIMEOUT_ENABLE = yes STARTUP_NUMLOCK_ON = yes -ENCODER_DEFAULTACTIONS_ENABLE = yes +ENCODER_DEFAULTACTIONS_ENABLE = no COLEMAK_LAYER_ENABLE = yes #Enable Colemak layer / set to no to disable From 94276442c86d33d17833c2e4fff81fe61553327d Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Fri, 3 Sep 2021 22:15:57 -0400 Subject: [PATCH 08/24] cleanup ENCFUNC --- users/jonavin/jonavin.c | 14 -------------- users/jonavin/jonavin.h | 13 ------------- 2 files changed, 27 deletions(-) diff --git a/users/jonavin/jonavin.c b/users/jonavin/jonavin.c index 9a71d5939f6f..6ecadc7b475f 100644 --- a/users/jonavin/jonavin.c +++ b/users/jonavin/jonavin.c @@ -103,20 +103,6 @@ along with this program. If not, see . } #endif // IDLE_TIMEOUT_ENABLE -#ifdef ENCFUNC_ENABLE - static uint8_t selectedkey_idx = 0; - static keycodedescType selectedkey_rec; - - static uint8_t get_selectedkey_idx(void) { - return selectedkey_idx; - } - - static void set_selectedkey(uint8_t idx) { - // make a copy from PROGMEM - memcpy_P (&selectedkey_rec, &keyselection[idx], sizeof selectedkey_rec); - } -#endif // ENCFUNC_ENABLE - #ifdef ENCODER_ENABLE #ifndef DYNAMIC_KEYMAP_LAYER_COUNT diff --git a/users/jonavin/jonavin.h b/users/jonavin/jonavin.h index 20b02aa60c1f..316483940ae6 100644 --- a/users/jonavin/jonavin.h +++ b/users/jonavin/jonavin.h @@ -58,19 +58,6 @@ enum custom_user_keycodes { #endif // TD_LSFT_CAPSLOCK_ENABLE -// ENC FUNC -#ifdef ENCFUNC_ENABLE - typedef struct { - char keydesc[6]; // this will be displayed on OLED - uint16_t keycode; // this is the keycode that will be sent when activted - } keycodedescType; - - static uint8_t get_selectedkey_idx(void); - static void set_selectedkey(uint8_t idx); - -#endif // ENCFUNC_ENABLE - - // ENCODER ACTIONS #ifdef ENCODER_ENABLE void encoder_action_volume(bool clockwise); From a561272f0fe14548cf67bfe21ba0f6efac48515b Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Fri, 3 Sep 2021 22:20:04 -0400 Subject: [PATCH 09/24] update readme --- keyboards/gmmk/pro/ansi/keymaps/jonavin/readme.md | 1 + 1 file changed, 1 insertion(+) diff --git a/keyboards/gmmk/pro/ansi/keymaps/jonavin/readme.md b/keyboards/gmmk/pro/ansi/keymaps/jonavin/readme.md index a6482baa5601..ef3d677477f8 100644 --- a/keyboards/gmmk/pro/ansi/keymaps/jonavin/readme.md +++ b/keyboards/gmmk/pro/ansi/keymaps/jonavin/readme.md @@ -12,6 +12,7 @@ - holding Left shift, change layers - holding right shift, Navigate page up/down - holding Left Ctrl, navigate prev/next word + - holding Rgiht Ctrl, changes RGB hue/colour - holding Left Alt, change media prev/next track - default is change volume From 366d7e3aea75dbd0fd0ec5a6340fb491d74cf574 Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Fri, 3 Sep 2021 22:21:33 -0400 Subject: [PATCH 10/24] fix readme typo --- keyboards/gmmk/pro/ansi/keymaps/jonavin/readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/keyboards/gmmk/pro/ansi/keymaps/jonavin/readme.md b/keyboards/gmmk/pro/ansi/keymaps/jonavin/readme.md index ef3d677477f8..2aa910e0c7a9 100644 --- a/keyboards/gmmk/pro/ansi/keymaps/jonavin/readme.md +++ b/keyboards/gmmk/pro/ansi/keymaps/jonavin/readme.md @@ -12,7 +12,7 @@ - holding Left shift, change layers - holding right shift, Navigate page up/down - holding Left Ctrl, navigate prev/next word - - holding Rgiht Ctrl, changes RGB hue/colour + - holding Right Ctrl, changes RGB hue/colour - holding Left Alt, change media prev/next track - default is change volume From 53ddde0ed0d3add85d15270d1d1cb0a8f4f30a76 Mon Sep 17 00:00:00 2001 From: Jonavin Date: Sat, 11 Sep 2021 13:49:04 -0400 Subject: [PATCH 11/24] update vert layout --- .../murphpad/keymaps/jonavin/keymap.c | 85 +++++++++++++++++-- 1 file changed, 80 insertions(+), 5 deletions(-) diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c index 39e6ac87e4c7..2ac6a586a236 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c @@ -18,7 +18,7 @@ #include "jonavin.h" #include "layout_landscape.h" -#define LANDSCAPE_MODE +//#define LANDSCAPE_MODE // Defines names for use in layer keycodes and the keymap enum layer_names { @@ -28,6 +28,7 @@ enum layer_names { _RGB }; +#ifdef LANDSCAPE_MODE const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [_BASE] = LAYOUT_landscape( @@ -91,6 +92,78 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { _______, _______, _______ ), }; +#endif // LANDSCAPE_MODE + +#ifndef LANDSCAPE_MODE +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* Base */ + [_BASE] = LAYOUT( + TT(_FN2), TT(_FN3), TT(_FN4), KC_PSCR, + KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, + KC_P7, KC_P8, KC_P9, KC_PPLS, + KC_MUTE, KC_P4, KC_P5, KC_P6, _______, + TT(_FN1), KC_P1, KC_P2, KC_P3, KC_PENT, + KC_RALT, KC_P0, _______, KC_PDOT, _______, + + KC_F5, KC_F6, KC_F7 + + ), + [_FN1] = LAYOUT( + _______, _______, _______, RESET, + KC_CALC, _______, _______, _______, + _______, _______, _______, _______, + ENCFUNC, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, KC_BSPC, _______, _______, _______, + + _______, _______, _______ + + ), + [_FN2] = LAYOUT( + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + + _______, _______, _______ + + ), + [_FN3] = LAYOUT( + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + + _______, _______, _______ + + ), + [_FN4] = LAYOUT( + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, + + _______, _______, _______ + + ), [_RGB] = LAYOUT( + _______, _______, _______, _______, + _______, _______, _______, _______, + RGB_HUD, RGB_SPI, RGB_HUI, _______, + _______, RGB_RMOD, RGB_TOG, RGB_MOD, _______, + _______, RGB_VAD, RGB_SPD, RGB_VAI, _______, + _______, RGB_SAD, _______, RGB_SAI, _______, + + _______, _______, _______ + + ), +}; +#endif // !LANDSCAPE_MODE typedef struct { char keydesc[6]; // this will be displayed on OLED @@ -289,14 +362,15 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { render_logo(); oled_set_cursor(0,6); - oled_write_ln_P(PSTR("Layer"), false); - + oled_write_ln_P(PSTR("JONAVIN"), false); + bool showSelectedKey = false; switch (get_highest_layer(layer_state)) { case _BASE: - oled_write_ln_P(PSTR("Base"), false); + oled_write_ln_P(PSTR("BASE"), false); break; case _FN1: oled_write_ln_P(PSTR("FN 1"), false); + showSelectedKey = true; break; case _FN2: oled_write_ln_P(PSTR("FN 2"), false); @@ -313,7 +387,8 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { default: oled_write_ln_P(PSTR("Undef"), false); } - oled_write_ln_P(PSTR(""), false); + if (showSelectedKey) oled_write_ln(selectedkey_rec.keydesc, false); + else oled_write_ln_P(PSTR(" "), false); // Host Keyboard LED Status led_t led_state = host_keyboard_led_state(); oled_write_ln_P(led_state.num_lock ? PSTR("NUM ") : PSTR(" "), false); From d0de37d3ac0fd5d58cbbde4ce758f266f2239f13 Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Sat, 11 Sep 2021 15:10:32 -0400 Subject: [PATCH 12/24] update vert oled display --- .../murphpad/keymaps/jonavin/config.h | 3 ++ .../murphpad/keymaps/jonavin/keymap.c | 33 ++++++++++--------- 2 files changed, 21 insertions(+), 15 deletions(-) diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/config.h b/keyboards/mechwild/murphpad/keymaps/jonavin/config.h index 7c1621515a6c..2636ea405160 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/config.h +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/config.h @@ -21,3 +21,6 @@ // Increase layers to 6 for VIA #define DYNAMIC_KEYMAP_LAYER_COUNT 6 + +// Remove line below for vertical layout +#define LANDSCAPE_MODE diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c index 2ac6a586a236..74c12b39bcac 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c @@ -18,7 +18,6 @@ #include "jonavin.h" #include "layout_landscape.h" -//#define LANDSCAPE_MODE // Defines names for use in layer keycodes and the keymap enum layer_names { @@ -98,7 +97,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { /* Base */ [_BASE] = LAYOUT( - TT(_FN2), TT(_FN3), TT(_FN4), KC_PSCR, + TT(_FN2),TT(_FN3),TT(_FN4),LT(_RGB,KC_PSCR), KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, KC_P7, KC_P8, KC_P9, KC_PPLS, KC_MUTE, KC_P4, KC_P5, KC_P6, _______, @@ -112,9 +111,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { _______, _______, _______, RESET, KC_CALC, _______, _______, _______, _______, _______, _______, _______, - ENCFUNC, _______, _______, _______, _______, + ENCFUNC, KC_TAB, _______, _______, _______, _______, _______, _______, _______, _______, - _______, KC_BSPC, _______, _______, _______, + _______, KC_BSPC, _______, KC_DEL, _______, _______, _______, _______ @@ -123,7 +122,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, - _______, _______, _______, _______, _______, + RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, @@ -172,15 +171,15 @@ typedef struct { static const keycodedescType PROGMEM keyselection[] = { // list of key codes that will be scrolled through by encoder and description - {"TASK", KC_TASK}, - {"INS", KC_INS}, - {"DEL", KC_DEL}, + {"TASK ", KC_TASK}, + {"INS ", KC_INS}, + {"DEL ", KC_DEL}, {"PrtSc", KC_PSCR}, {"ScrLk", KC_SCLN}, {"Break", KC_PAUS}, {"C-A-D", KC_CAD}, // Ctrl-Alt-Del {"AltF4", KC_AF4}, - {"PLAY", KC_MEDIA_PLAY_PAUSE}, + {"PLAY ", KC_MEDIA_PLAY_PAUSE}, {"RESET", RESET}, // firmware flash mode }; @@ -360,9 +359,11 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { void oled_task_user(void) { render_logo(); - oled_set_cursor(0,6); + oled_set_cursor(0,5); + + oled_write_ln_P(PSTR("-JV-"), false); + oled_write_ln_P(PSTR(" "), false); - oled_write_ln_P(PSTR("JONAVIN"), false); bool showSelectedKey = false; switch (get_highest_layer(layer_state)) { case _BASE: @@ -385,15 +386,17 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { oled_write_ln_P(PSTR("RGB "), false); break; default: - oled_write_ln_P(PSTR("Undef"), false); + oled_write_ln_P(PSTR(" ?? "), false); } if (showSelectedKey) oled_write_ln(selectedkey_rec.keydesc, false); else oled_write_ln_P(PSTR(" "), false); + // Host Keyboard LED Status led_t led_state = host_keyboard_led_state(); - oled_write_ln_P(led_state.num_lock ? PSTR("NUM ") : PSTR(" "), false); - oled_write_ln_P(led_state.caps_lock ? PSTR("CAP ") : PSTR(" "), false); - oled_write_ln_P(led_state.scroll_lock ? PSTR("SCR ") : PSTR(" "), false); + oled_set_cursor(0,11); + oled_write_ln_P(led_state.num_lock ? PSTR(" NUM") : PSTR(" "), false); + oled_write_ln_P(led_state.caps_lock ? PSTR(" CAP") : PSTR(" "), false); + oled_write_ln_P(led_state.scroll_lock ? PSTR(" SCR") : PSTR(" "), false); } #endif // !LANDSCAPE_MODE From 8a4cff99e54ebfe31a0744092fa15e9d5b688e83 Mon Sep 17 00:00:00 2001 From: jonavin <71780717+Jonavin@users.noreply.github.com> Date: Sat, 11 Sep 2021 15:30:53 -0400 Subject: [PATCH 13/24] Update readme.md --- .../mechwild/murphpad/keymaps/jonavin/readme.md | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md b/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md index 933157063699..845ea0bfbff6 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md @@ -1,6 +1,7 @@ Jonavin's Custom MurphPad Landscape Layout -This allows you to use Murphpad in a horizontal/landscape orientation with extra layers +This allows you to use Murphpad in a horizontal/landscape orientation with extra layers. +#define LANDSCAPE_MODE in config.h to use landscape mode, otherwise traditional vertical numpad layout also has similar featureset - OLED has been rotated for landscape mode - Keymap positions have been updated so it's easier to visualize the keymap in landscape @@ -25,9 +26,9 @@ Special Features static const keycodedescType PROGMEM keyselection[] = { // list of key codes that will be scrollled through by encoder and description - {"TASK", KC_TASK}, - {"INS", KC_INS}, - {"DEL", KC_DEL}, + {"TASK ", KC_TASK}, + {"INS ", KC_INS}, + {"DEL ", KC_DEL}, {"PrtSc", KC_PSCR}, {"ScrLk", KC_SCLN}, {"Break", KC_PAUS}, @@ -49,7 +50,7 @@ rules.mk OPTIONS - Active features from userspace - STARTUP_NUMLOCK_ON = yes - turns on NUMLOCK by default -DEFAULT MAPPING +DEFAULT MAPPING FOR LANDSCAPE ![image](https://user-images.githubusercontent.com/71780717/131718965-b20afef6-3bc5-49e4-952f-5755a9d6d539.png) @@ -63,3 +64,9 @@ RGB Layer 5 - Use Shift+Encoder to get to RGB layer 5 ![image](https://user-images.githubusercontent.com/71780717/131719492-e2d05a75-3a7a-48ca-94a3-faa3ff891914.png) + + +NORMAL NUMPAD / NON-LANDSCAPE MAPPING + +![image](https://user-images.githubusercontent.com/71780717/132959297-808c0fbf-444d-4836-bd31-2393e2847ef5.png) + From d049639295e9291ab618ac95a472447e06b5912c Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Sat, 11 Sep 2021 20:32:43 -0400 Subject: [PATCH 14/24] add media keys --- .../murphpad/keymaps/jonavin/keymap.c | 27 +++++++--------- .../murphpad/keymaps/jonavin/readme.md | 31 ++++++++++--------- 2 files changed, 27 insertions(+), 31 deletions(-) diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c index 74c12b39bcac..0d2e2ccb4971 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c @@ -53,7 +53,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [_FN2] = LAYOUT_landscape( _______, _______, RESET, - _______, _______, _______, _______, _______, _______, + _______, _______, KC_MPLY, KC_MPRV, KC_MNXT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, @@ -104,8 +104,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { TT(_FN1), KC_P1, KC_P2, KC_P3, KC_PENT, KC_RALT, KC_P0, _______, KC_PDOT, _______, - KC_F5, KC_F6, KC_F7 - + TT(_FN3), TT(_FN4), TT(_RGB) ), [_FN1] = LAYOUT( _______, _______, _______, RESET, @@ -116,18 +115,16 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { _______, KC_BSPC, _______, KC_DEL, _______, _______, _______, _______ - ), [_FN2] = LAYOUT( _______, _______, _______, _______, - _______, _______, _______, _______, - _______, _______, _______, _______, - RESET, _______, _______, _______, _______, + _______, _______, KC_MPLY, KC_MPRV, + _______, _______, _______, KC_MNXT, + RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ - ), [_FN3] = LAYOUT( _______, _______, _______, _______, @@ -138,7 +135,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { _______, _______, _______, _______, _______, _______, _______, _______ - ), [_FN4] = LAYOUT( _______, _______, _______, _______, @@ -149,8 +145,8 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { _______, _______, _______, _______, _______, _______, _______, _______ - - ), [_RGB] = LAYOUT( + ), + [_RGB] = LAYOUT( _______, _______, _______, _______, _______, _______, _______, _______, RGB_HUD, RGB_SPI, RGB_HUI, _______, @@ -159,7 +155,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { _______, RGB_SAD, _______, RGB_SAI, _______, _______, _______, _______ - ), }; #endif // !LANDSCAPE_MODE @@ -172,14 +167,14 @@ typedef struct { static const keycodedescType PROGMEM keyselection[] = { // list of key codes that will be scrolled through by encoder and description {"TASK ", KC_TASK}, - {"INS ", KC_INS}, - {"DEL ", KC_DEL}, - {"PrtSc", KC_PSCR}, + {"PREV ", KC_MEDIA_PREV_TRACK}, + {"NEXT ", KC_MEDIA_NEXT_TRACK}, + {"PLAY ", KC_MEDIA_PLAY_PAUSE}, + {"PrtScm", KC_PSCR}, {"ScrLk", KC_SCLN}, {"Break", KC_PAUS}, {"C-A-D", KC_CAD}, // Ctrl-Alt-Del {"AltF4", KC_AF4}, - {"PLAY ", KC_MEDIA_PLAY_PAUSE}, {"RESET", RESET}, // firmware flash mode }; diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md b/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md index 933157063699..31a6570ccf75 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md @@ -8,12 +8,12 @@ This allows you to use Murphpad in a horizontal/landscape orientation with extra [_BASE] = LAYOUT_landscape( TT(_FN1), TT(_FN2), KC_MUTE, - KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, KC_PPLS, KC_BSPC, - KC_TAB, KC_P7, KC_P8, KC_P9, KC_PDOT, KC_RGUI, - KC_RSFT, KC_P4, KC_P5, KC_P6, KC_COMMA, KC_RCTL, - KC_P0, KC_P1, KC_P2, KC_P3, KC_PENT, KC_RALT, + KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, KC_PPLS, KC_BSPC, + KC_TAB, KC_P7, KC_P8, KC_P9, KC_PDOT, KC_RGUI, + KC_RSFT, KC_P4, KC_P5, KC_P6, KC_COMMA, KC_RCTL, + KC_P0, KC_P1, KC_P2, KC_P3, KC_PENT, KC_RALT, - _______, _______, _______ + _______, _______, _______ ), NOTE: VIA is enabled, but it will show it in the normal orientation until I build a landscape layout version @@ -25,16 +25,17 @@ Special Features static const keycodedescType PROGMEM keyselection[] = { // list of key codes that will be scrollled through by encoder and description - {"TASK", KC_TASK}, - {"INS", KC_INS}, - {"DEL", KC_DEL}, - {"PrtSc", KC_PSCR}, - {"ScrLk", KC_SCLN}, - {"Break", KC_PAUS}, - {"C-A-D", KC_CAD}, // Ctrl-Alt-Del - {"AltF4", KC_AF4}, - {"PLAY", KC_MEDIA_PLAY_PAUSE}, - {"RESET", RESET}, // firmware flash mode + {"TASK ", KC_TASK}, + {"PREV ", KC_MEDIA_PREV_TRACK}, + {"NEXT ", KC_MEDIA_NEXT_TRACK}, + {"PLAY ", KC_MEDIA_PLAY_PAUSE}, + {"PrtScm", KC_PSCR}, + {"ScrLk", KC_SCLN}, + {"Break", KC_PAUS}, + {"C-A-D", KC_CAD}, // Ctrl-Alt-Del + {"AltF4", KC_AF4}, + {"RESET", RESET}, // firmware flash mode + }; - Additional encoder functionality From d1c5b752a3ec39914fbafbd39c4fe62f8f53ec55 Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Sat, 11 Sep 2021 20:36:15 -0400 Subject: [PATCH 15/24] update readme --- keyboards/mechwild/murphpad/keymaps/jonavin/readme.md | 1 - 1 file changed, 1 deletion(-) diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md b/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md index 31a6570ccf75..451f6ba6f8a1 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md @@ -35,7 +35,6 @@ Special Features {"C-A-D", KC_CAD}, // Ctrl-Alt-Del {"AltF4", KC_AF4}, {"RESET", RESET}, // firmware flash mode - }; - Additional encoder functionality From 70d8241829db8c3c0787a51a30e361e7fdc5ad3a Mon Sep 17 00:00:00 2001 From: jonavin <71780717+Jonavin@users.noreply.github.com> Date: Sat, 11 Sep 2021 20:42:10 -0400 Subject: [PATCH 16/24] Update readme.md --- .../mechwild/murphpad/keymaps/jonavin/readme.md | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md b/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md index 451f6ba6f8a1..0e389a5c3763 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/readme.md @@ -49,7 +49,7 @@ rules.mk OPTIONS - Active features from userspace - STARTUP_NUMLOCK_ON = yes - turns on NUMLOCK by default -DEFAULT MAPPING +DEFAULT LANDSCAPE MAPPING ![image](https://user-images.githubusercontent.com/71780717/131718965-b20afef6-3bc5-49e4-952f-5755a9d6d539.png) @@ -59,7 +59,18 @@ FN1 Layer 1 ![image](https://user-images.githubusercontent.com/71780717/131719025-d41cbcd9-80b1-4a0a-abb5-55d878752dc6.png) +FN2 Layer 2 + +![image](https://user-images.githubusercontent.com/71780717/132967003-63268514-2ac3-4069-bca1-6d92992ca403.png) + + RGB Layer 5 - Use Shift+Encoder to get to RGB layer 5 ![image](https://user-images.githubusercontent.com/71780717/131719492-e2d05a75-3a7a-48ca-94a3-faa3ff891914.png) +-------------- + +NORMAL / TRADITIONAL NON-LANDSCAPE NUMPAD LAYOUT + +![image](https://user-images.githubusercontent.com/71780717/132966975-3b463fb4-059f-42c5-b8b3-a3d35f4a0d6b.png) + From 3666099560ebf4966b60c8aa4387babd2222afbf Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Sun, 12 Sep 2021 15:14:06 -0400 Subject: [PATCH 17/24] add rgb encoder actions --- .../murphpad/keymaps/jonavin/keymap.c | 7 +- users/jonavin/jonavin.c | 64 +++++++++++++++++++ users/jonavin/jonavin.h | 23 ++++++- 3 files changed, 92 insertions(+), 2 deletions(-) diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c index 0d2e2ccb4971..6271d55d187e 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c @@ -235,7 +235,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { #endif uint8_t mods_state = get_mods(); switch (index) { - case 0: // This is the only encoder right now, keeping for consistency + case 0: // This is the only encoder right now, keeping for consistency switch(get_highest_layer(layer_state)){ // special handling per layer case _FN1: // on Fn layer select what the encoder does when pressed if (!mods_state) { @@ -244,6 +244,11 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { } else { // continue to default } + case _RGB: + if (!mods_state) { + encoder_action_rgb_hue(clockwise); + break; + } default: // all other layers if (mods_state & MOD_BIT(KC_RSFT) ) { // If you are holding R shift, encoder changes layers encoder_action_layerchange(clockwise); diff --git a/users/jonavin/jonavin.c b/users/jonavin/jonavin.c index 6ecadc7b475f..f53aa8664e5b 100644 --- a/users/jonavin/jonavin.c +++ b/users/jonavin/jonavin.c @@ -160,6 +160,70 @@ along with this program. If not, see . } } } + + #ifdef RGB_MATRIX_ENABLE + void encoder_action_rgb_speed(bool clockwise) { + if (clockwise) + rgb_matrix_increase_speed_noeeprom(); + else + rgb_matrix_decrease_speed_noeeprom(); + } + void encoder_action_rgb_hue(bool clockwise) { + if (clockwise) + rgb_matrix_increase_hue_noeeprom(); + else + rgb_matrix_decrease_hue_noeeprom(); + } + void encoder_action_rgb_saturation(bool clockwise) { + if (clockwise) + rgb_matrix_increase_sat_noeeprom(); + else + rgb_matrix_decrease_sat_noeeprom(); + } + void encoder_action_rgb_brightness(bool clockwise) { + if (clockwise) + rgb_matrix_increase_val_noeeprom(); + else + rgb_matrix_decrease_val_noeeprom(); + } + void encoder_action_rgb_mode(bool clockwise) { + if (clockwise) + rgb_matrix_step_noeeprom(); + else + rgb_matrix_step_reverse_noeeprom(); + } + #elif defined(RGBLIGHT_ENABLE) + void encoder_action_rgb_speed(bool clockwise) { + if (clockwise) + rgblight_increase_speed_noeeprom(); + else + rgblight_decrease_speed_noeeprom(); + } + void encoder_action_rgb_hue(bool clockwise) { + if (clockwise) + rgblight_increase_hue_noeeprom(); + else + rgblight_decrease_hue_noeeprom(); + } + void encoder_action_rgb_saturation(bool clockwise) { + if (clockwise) + rgblight_increase_sat_noeeprom(); + else + rgblight_decrease_sat_noeeprom(); + } + void encoder_action_rgb_brightness(bool clockwise) { + if (clockwise) + rgblight_increase_val_noeeprom(); + else + rgblight_decrease_val_noeeprom(); + } + void encoder_action_rgb_mode(bool clockwise) { + if (clockwise) + rgblight_step_noeeprom(); + else + rgblight_step_reverse_noeeprom(); + } + #endif // RGB_MATRIX_ENABLE || RGBLIGHT_ENABLE #endif // ENCODER_ENABLE #if defined(ENCODER_ENABLE) && defined(ENCODER_DEFAULTACTIONS_ENABLE) // Encoder Functionality diff --git a/users/jonavin/jonavin.h b/users/jonavin/jonavin.h index 316483940ae6..ece01335c22e 100644 --- a/users/jonavin/jonavin.h +++ b/users/jonavin/jonavin.h @@ -36,7 +36,9 @@ enum custom_user_keycodes { KC_WINLCK, //Toggles Win key on and off RGB_TOI, // Timeout idle time up RGB_TOD, // Timeout idle time down - RGB_NITE // Turns off all rgb but allow rgb indicators to work + RGB_NITE, // Turns off all rgb but allow rgb indicators to work + + NEW_SAFE_RANGE // new safe range for keymap level custom keycodes }; #define KC_CAD LALT(LCTL(KC_DEL)) @@ -93,5 +95,24 @@ enum custom_user_keycodes { #endif //IDLE_TIMEOUT_ENABLE +// ENCODER ACTIONS +#ifdef ENCODER_ENABLE + void encoder_action_volume(bool clockwise); + void encoder_action_mediatrack(bool clockwise); + void encoder_action_navword(bool clockwise); + void encoder_action_navpage(bool clockwise); + uint8_t get_selected_layer(void); + void encoder_action_layerchange(bool clockwise); + + #if defined(RGB_MATRIX_ENABLE) || defined(RGBLIGHT_ENABLE) + void encoder_action_rgb_speed(bool clockwise); + void encoder_action_rgb_hue(bool clockwise); + void encoder_action_rgb_saturation(bool clockwise); + void encoder_action_rgb_brightness(bool clockwise); + void encoder_action_rgb_mode(bool clockwise); + #endif // RGB_MATRIX_ENABLE / RGBLIGHT_ENABLE +#endif // ENCODER_ENABLE + + // OTHER FUNCTION PROTOTYPE void activate_numlock(bool turn_on); From fe36e9de3290637cdd1d813c577f6208238ef23d Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Sun, 12 Sep 2021 15:15:56 -0400 Subject: [PATCH 18/24] remove duplicate prototype declaration --- users/jonavin/jonavin.h | 27 ++++++++------------------- 1 file changed, 8 insertions(+), 19 deletions(-) diff --git a/users/jonavin/jonavin.h b/users/jonavin/jonavin.h index ece01335c22e..efe0301af377 100644 --- a/users/jonavin/jonavin.h +++ b/users/jonavin/jonavin.h @@ -69,6 +69,14 @@ enum custom_user_keycodes { uint8_t get_selected_layer(void); void encoder_action_layerchange(bool clockwise); + + #if defined(RGB_MATRIX_ENABLE) || defined(RGBLIGHT_ENABLE) + void encoder_action_rgb_speed(bool clockwise); + void encoder_action_rgb_hue(bool clockwise); + void encoder_action_rgb_saturation(bool clockwise); + void encoder_action_rgb_brightness(bool clockwise); + void encoder_action_rgb_mode(bool clockwise); + #endif // RGB_MATRIX_ENABLE / RGBLIGHT_ENABLE #endif // ENCODER_ENABLE @@ -95,24 +103,5 @@ enum custom_user_keycodes { #endif //IDLE_TIMEOUT_ENABLE -// ENCODER ACTIONS -#ifdef ENCODER_ENABLE - void encoder_action_volume(bool clockwise); - void encoder_action_mediatrack(bool clockwise); - void encoder_action_navword(bool clockwise); - void encoder_action_navpage(bool clockwise); - uint8_t get_selected_layer(void); - void encoder_action_layerchange(bool clockwise); - - #if defined(RGB_MATRIX_ENABLE) || defined(RGBLIGHT_ENABLE) - void encoder_action_rgb_speed(bool clockwise); - void encoder_action_rgb_hue(bool clockwise); - void encoder_action_rgb_saturation(bool clockwise); - void encoder_action_rgb_brightness(bool clockwise); - void encoder_action_rgb_mode(bool clockwise); - #endif // RGB_MATRIX_ENABLE / RGBLIGHT_ENABLE -#endif // ENCODER_ENABLE - - // OTHER FUNCTION PROTOTYPE void activate_numlock(bool turn_on); From 3b333464c2cbe7f1410a3b6a2acf1bb7b1c78355 Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Sun, 12 Sep 2021 19:42:33 -0400 Subject: [PATCH 19/24] update murphpad keymap --- keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c b/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c index 22d26db3c2ee..75e5444e4d51 100755 --- a/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c @@ -139,6 +139,11 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { } else { // continue to default } + case _RGB: + if (!mods_state) { + encoder_action_rgb_hue(clockwise); + break; + } default: // all other layers if (mods_state & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers encoder_action_layerchange(clockwise); From 0776ef4b0ad06af42c5082f3b68ce6af6e43e7a5 Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Sun, 12 Sep 2021 19:56:10 -0400 Subject: [PATCH 20/24] turn off rgb when oled when PC suspended --- keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c index 6271d55d187e..620bcd5a2b58 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c @@ -401,6 +401,11 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { #endif // !LANDSCAPE_MODE void suspend_power_down_user(void) { // shutdown oled when powered down to prevent OLED from showing Mercutio all the time - oled_off(); + oled_off(); + rgblight_disable_noeeprom(); + } + + void suspend_wakeup_init_user(void) { + rgblight_enable_noeeprom(); } #endif From 808d13877416dae0cb8c95b62a4a2eb664da0ff7 Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Sun, 12 Sep 2021 20:01:39 -0400 Subject: [PATCH 21/24] update murphpad keymap --- keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c b/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c index 75e5444e4d51..22d26db3c2ee 100755 --- a/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/mercutio/keymaps/jonavin/keymap.c @@ -139,11 +139,6 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { } else { // continue to default } - case _RGB: - if (!mods_state) { - encoder_action_rgb_hue(clockwise); - break; - } default: // all other layers if (mods_state & MOD_BIT(KC_LSFT) ) { // If you are holding L shift, encoder changes layers encoder_action_layerchange(clockwise); From 01448a38babf9e4328cb571f3021b388499a87d3 Mon Sep 17 00:00:00 2001 From: Jonavin Date: Mon, 13 Sep 2021 10:23:52 -0400 Subject: [PATCH 22/24] update enc 1 actions --- .../mechwild/murphpad/keymaps/jonavin/keymap.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c index 620bcd5a2b58..dc03e334bf69 100644 --- a/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c +++ b/keyboards/mechwild/murphpad/keymaps/jonavin/keymap.c @@ -235,7 +235,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { #endif uint8_t mods_state = get_mods(); switch (index) { - case 0: // This is the only encoder right now, keeping for consistency + case 0: // main primary encoder switch(get_highest_layer(layer_state)){ // special handling per layer case _FN1: // on Fn layer select what the encoder does when pressed if (!mods_state) { @@ -262,6 +262,17 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) { break; } break; + case 1: // optional secondary encoder + switch(get_highest_layer(layer_state)){ // special handling per layer + case _RGB: + if (!mods_state) { + encoder_action_rgb_mode(clockwise); + break; + } + default: // all other layers + encoder_action_mediatrack(clockwise); // Otherwise prev/next track + break; + } } return true; } From 1239c173baf69355c5aed2537cc91ee92b845398 Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Tue, 28 Sep 2021 16:43:20 -0400 Subject: [PATCH 23/24] Merge branch 'master' --- .../duckypad/keymaps/m4cs/sysinfo.py | 1 - keyboards/dztech/dz60rgb_ansi/readme.md | 4 +- keyboards/dztech/dz60rgb_ansi/v2_1/config.h | 77 ++ keyboards/dztech/dz60rgb_ansi/v2_1/rules.mk | 25 + keyboards/ergodox_ez/util/compile_keymap.py | 5 - .../keymap_beautifier/KeymapBeautifier.py | 1 - keyboards/kprepublic/bm80/bm80.c | 142 ++++ keyboards/kprepublic/bm80/bm80.h | 43 + keyboards/kprepublic/bm80/config.h | 99 +++ keyboards/kprepublic/bm80/info.json | 98 +++ .../kprepublic/bm80/keymaps/default/keymap.c | 51 ++ .../kprepublic/bm80/keymaps/default/readme.md | 1 + .../bm80/keymaps/peepeetee/config.h | 97 +++ .../bm80/keymaps/peepeetee/keymap.c | 51 ++ .../kprepublic/bm80/keymaps/via/keymap.c | 57 ++ .../kprepublic/bm80/keymaps/via/readme.md | 1 + .../kprepublic/bm80/keymaps/via/rules.mk | 1 + keyboards/kprepublic/bm80/readme.md | 30 + keyboards/kprepublic/bm80/rules.mk | 26 + keyboards/mechlovin/adelais/adelais.h | 28 +- keyboards/mechlovin/adelais/info.json | 167 +++- keyboards/owlab/suit80/ansi/ansi.c | 17 + keyboards/owlab/suit80/ansi/ansi.h | 36 + keyboards/owlab/suit80/ansi/config.h | 46 + keyboards/owlab/suit80/ansi/info.json | 98 +++ .../suit80/ansi/keymaps/default/keymap.c | 41 + .../owlab/suit80/ansi/keymaps/via/keymap.c | 57 ++ .../owlab/suit80/ansi/keymaps/via/rules.mk | 2 + keyboards/owlab/suit80/ansi/readme.md | 21 + keyboards/owlab/suit80/ansi/rules.mk | 21 + keyboards/owlab/suit80/iso/config.h | 46 + keyboards/owlab/suit80/iso/info.json | 192 +++++ keyboards/owlab/suit80/iso/iso.c | 19 + keyboards/owlab/suit80/iso/iso.h | 52 ++ .../owlab/suit80/iso/keymaps/default/keymap.c | 41 + .../owlab/suit80/iso/keymaps/via/keymap.c | 56 ++ .../owlab/suit80/iso/keymaps/via/rules.mk | 2 + keyboards/owlab/suit80/iso/readme.md | 21 + keyboards/owlab/suit80/iso/rules.mk | 21 + keyboards/preonic/keymaps/arkag/keymap.c | 4 +- keyboards/pteron36/config.h | 14 +- keyboards/pteron36/keymaps/default/keymap.c | 2 +- keyboards/pteron36/keymaps/via/keymap.c | 59 +- keyboards/pteron36/keymaps/via/readme.md | 2 +- keyboards/pteron36/keymaps/via/rules.mk | 2 +- keyboards/pteron36/pteron36.c | 51 +- keyboards/pteron36/readme.md | 13 +- keyboards/pteron36/rules.mk | 8 +- keyboards/ramonimbao/squishytkl/info.json | 802 +++++++++--------- keyboards/ramonimbao/squishytkl/squishytkl.h | 170 ++-- .../viktus/sp_mini/keymaps/peott-fr/keymap.c | 117 +++ keyboards/yampad/config.h | 2 +- keyboards/yampad/keymaps/via/keymap.c | 163 ++++ keyboards/yampad/keymaps/via/readme.md | 9 + keyboards/yampad/keymaps/via/rules.mk | 4 + keyboards/yampad/rules.mk | 21 +- keyboards/z12/config.h | 53 ++ keyboards/z12/info.json | 26 + keyboards/z12/keymaps/default/config.h | 26 + keyboards/z12/keymaps/default/keymap.c | 59 ++ keyboards/z12/keymaps/default/readme.md | 3 + keyboards/z12/keymaps/default/rules.mk | 2 + keyboards/z12/readme.md | 3 + keyboards/z12/rules.mk | 24 + keyboards/z12/z12.c | 39 + keyboards/z12/z12.h | 34 + keyboards/zinc/keymaps/default/rules.mk | 6 +- keyboards/zinc/keymaps/ginjake/rules.mk | 6 +- keyboards/zinc/keymaps/monks/rules.mk | 6 +- keyboards/zinc/keymaps/toshi0383/rules.mk | 6 +- .../ergodox/algernon/tools/log-to-heatmap.py | 4 +- .../ergodox/algernon/tools/text-to-log.py | 1 - .../ergodox/german-manuneo/compile_keymap.py | 5 - lib/python/qmk/cli/doctor/linux.py | 8 +- lib/python/qmk/cli/doctor/main.py | 9 +- lib/python/qmk/cli/generate/config_h.py | 2 +- lib/python/qmk/cli/generate/dfu_header.py | 2 +- lib/python/qmk/cli/generate/keyboard_h.py | 2 +- lib/python/qmk/cli/generate/layouts.py | 2 +- lib/python/qmk/info.py | 8 +- lib/python/qmk/keymap.py | 4 +- message.mk | 1 + tmk_core/rules.mk | 2 +- users/arkag/arkag.c | 4 + users/dennytom/chording_engine/chord.py | 3 +- util/stm32eeprom_parser.py | 1 - util/uf2conv.py | 8 +- 87 files changed, 3021 insertions(+), 575 deletions(-) create mode 100644 keyboards/dztech/dz60rgb_ansi/v2_1/config.h create mode 100644 keyboards/dztech/dz60rgb_ansi/v2_1/rules.mk create mode 100644 keyboards/kprepublic/bm80/bm80.c create mode 100644 keyboards/kprepublic/bm80/bm80.h create mode 100644 keyboards/kprepublic/bm80/config.h create mode 100644 keyboards/kprepublic/bm80/info.json create mode 100644 keyboards/kprepublic/bm80/keymaps/default/keymap.c create mode 100644 keyboards/kprepublic/bm80/keymaps/default/readme.md create mode 100644 keyboards/kprepublic/bm80/keymaps/peepeetee/config.h create mode 100644 keyboards/kprepublic/bm80/keymaps/peepeetee/keymap.c create mode 100644 keyboards/kprepublic/bm80/keymaps/via/keymap.c create mode 100644 keyboards/kprepublic/bm80/keymaps/via/readme.md create mode 100644 keyboards/kprepublic/bm80/keymaps/via/rules.mk create mode 100644 keyboards/kprepublic/bm80/readme.md create mode 100644 keyboards/kprepublic/bm80/rules.mk create mode 100644 keyboards/owlab/suit80/ansi/ansi.c create mode 100644 keyboards/owlab/suit80/ansi/ansi.h create mode 100644 keyboards/owlab/suit80/ansi/config.h create mode 100644 keyboards/owlab/suit80/ansi/info.json create mode 100644 keyboards/owlab/suit80/ansi/keymaps/default/keymap.c create mode 100644 keyboards/owlab/suit80/ansi/keymaps/via/keymap.c create mode 100644 keyboards/owlab/suit80/ansi/keymaps/via/rules.mk create mode 100644 keyboards/owlab/suit80/ansi/readme.md create mode 100644 keyboards/owlab/suit80/ansi/rules.mk create mode 100644 keyboards/owlab/suit80/iso/config.h create mode 100644 keyboards/owlab/suit80/iso/info.json create mode 100644 keyboards/owlab/suit80/iso/iso.c create mode 100644 keyboards/owlab/suit80/iso/iso.h create mode 100644 keyboards/owlab/suit80/iso/keymaps/default/keymap.c create mode 100644 keyboards/owlab/suit80/iso/keymaps/via/keymap.c create mode 100644 keyboards/owlab/suit80/iso/keymaps/via/rules.mk create mode 100644 keyboards/owlab/suit80/iso/readme.md create mode 100644 keyboards/owlab/suit80/iso/rules.mk create mode 100644 keyboards/viktus/sp_mini/keymaps/peott-fr/keymap.c create mode 100644 keyboards/yampad/keymaps/via/keymap.c create mode 100644 keyboards/yampad/keymaps/via/readme.md create mode 100644 keyboards/yampad/keymaps/via/rules.mk create mode 100644 keyboards/z12/config.h create mode 100644 keyboards/z12/info.json create mode 100644 keyboards/z12/keymaps/default/config.h create mode 100644 keyboards/z12/keymaps/default/keymap.c create mode 100644 keyboards/z12/keymaps/default/readme.md create mode 100644 keyboards/z12/keymaps/default/rules.mk create mode 100644 keyboards/z12/readme.md create mode 100644 keyboards/z12/rules.mk create mode 100644 keyboards/z12/z12.c create mode 100644 keyboards/z12/z12.h diff --git a/keyboards/dekunukem/duckypad/keymaps/m4cs/sysinfo.py b/keyboards/dekunukem/duckypad/keymaps/m4cs/sysinfo.py index 04cf343ea69e..4dfcd4d4d172 100644 --- a/keyboards/dekunukem/duckypad/keymaps/m4cs/sysinfo.py +++ b/keyboards/dekunukem/duckypad/keymaps/m4cs/sysinfo.py @@ -21,7 +21,6 @@ import hid import time -import string import psutil import GPUtil import datetime diff --git a/keyboards/dztech/dz60rgb_ansi/readme.md b/keyboards/dztech/dz60rgb_ansi/readme.md index aa15dda89019..1d0ca38f4d8c 100644 --- a/keyboards/dztech/dz60rgb_ansi/readme.md +++ b/keyboards/dztech/dz60rgb_ansi/readme.md @@ -8,14 +8,16 @@ A hotswap 60% RGB keyboard. * Hardware Supported: DZtech DZ60RGB-ANSI V1 and V2 * Hardware Availability: [KBDfans](https://kbdfans.com/) -There are two versions of the DZ60RGB-ANSI. Please use the appropriate firmware for your board. +There are three versions of the DZ60RGB-ANSI. Please use the appropriate firmware for your board. * V1: STM32F303 (Arm), takes .bin files * V2: ATmega32U4 (AVR), takes .hex files +* V2.1: ATmega32U4 (AVR), takes .bin files Make example for this keyboard (after setting up your build environment): make dztech/dz60rgb_ansi/v1:default # Arm (STM32F303) make dztech/dz60rgb_ansi/v2:default # AVR (ATmega32U4) + make dztech/dz60rgb_ansi/v2_1:default # AVR (ATmega32U4) See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs). diff --git a/keyboards/dztech/dz60rgb_ansi/v2_1/config.h b/keyboards/dztech/dz60rgb_ansi/v2_1/config.h new file mode 100644 index 000000000000..ad310664a850 --- /dev/null +++ b/keyboards/dztech/dz60rgb_ansi/v2_1/config.h @@ -0,0 +1,77 @@ +/* Copyright 2021 QMK + * + * 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 . + */ + +#pragma once + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x445A +#define PRODUCT_ID 0x1221 +#define DEVICE_VER 0x0002 +#define MANUFACTURER DZTECH +#define PRODUCT DZ60RGB_ANSI + +/* key matrix size */ +#define MATRIX_ROWS 5 +#define MATRIX_COLS 14 + +/* + * Keyboard Matrix Assignments + * + * Change this to how you wired your keyboard + * COLS: AVR pins used for columns, left to right + * ROWS: AVR pins used for rows, top to bottom + * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) + * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) + * + */ +#define MATRIX_ROW_PINS { F5, F4, F1, B3, B2 } +#define MATRIX_COL_PINS { C7, F7, F6, F0, B0, B1, B4, D7, D6, D4, D5, D3, D2, B7 } +#define UNUSED_PINS + +/* COL2ROW, ROW2COL*/ +#define DIODE_DIRECTION COL2ROW + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 3 + +/* disable these deprecated features by default */ +#define NO_ACTION_MACRO +#define NO_ACTION_FUNCTION + +#ifdef RGB_MATRIX_ENABLE +# define RGB_DISABLE_AFTER_TIMEOUT 0 // number of ticks to wait until disabling effects +# define RGB_DISABLE_WHEN_USB_SUSPENDED // turn off effects when suspended +# define RGB_MATRIX_KEYPRESSES +# define RGB_MATRIX_FRAMEBUFFER_EFFECTS +# define DISABLE_RGB_MATRIX_GRADIENT_UP_DOWN +# define DISABLE_RGB_MATRIX_BAND_SAT +# define DISABLE_RGB_MATRIX_BAND_PINWHEEL_SAT +# define DISABLE_RGB_MATRIX_BAND_SPIRAL_SAT +# define DISABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE +# define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE +# define DISABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS +# define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS +# define DISABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS +# define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS +# define DISABLE_RGB_MATRIX_SPLASH +# define DISABLE_RGB_MATRIX_MULTISPLASH +# define DISABLE_RGB_MATRIX_SOLID_SPLASH +# define DISABLE_RGB_MATRIX_SOLID_MULTISPLASH +# define DISABLE_RGB_MATRIX_DIGITAL_RAIN +# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_COUNT 1 +# define DRIVER_LED_TOTAL 61 +#endif diff --git a/keyboards/dztech/dz60rgb_ansi/v2_1/rules.mk b/keyboards/dztech/dz60rgb_ansi/v2_1/rules.mk new file mode 100644 index 000000000000..aa2092d4df86 --- /dev/null +++ b/keyboards/dztech/dz60rgb_ansi/v2_1/rules.mk @@ -0,0 +1,25 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = lufa-ms +BOOTLOADER_SIZE = 6144 + +# 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 +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = yes # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +AUDIO_ENABLE = no # Audio output +RGB_MATRIX_ENABLE = yes # Use RGB matrix +RGB_MATRIX_DRIVER = IS31FL3733 +LTO_ENABLE = yes diff --git a/keyboards/ergodox_ez/util/compile_keymap.py b/keyboards/ergodox_ez/util/compile_keymap.py index f427d6fd8020..b447ecaf5ce4 100755 --- a/keyboards/ergodox_ez/util/compile_keymap.py +++ b/keyboards/ergodox_ez/util/compile_keymap.py @@ -584,11 +584,6 @@ def unicode_macro_cases(config): for macro_id, uc_hex in config['unicode_macros'].items(): hi = int(uc_hex, 16) >> 8 lo = int(uc_hex, 16) & 0xFF - unimacro_keys = ", ".join( - "T({})".format( - "KP_" + digit if digit.isdigit() else digit - ) for digit in uc_hex - ) yield UNICODE_MACRO_TEMPLATE.format( macro_id=macro_id, hi=hi, lo=lo ) diff --git a/keyboards/ergodox_ez/util/keymap_beautifier/KeymapBeautifier.py b/keyboards/ergodox_ez/util/keymap_beautifier/KeymapBeautifier.py index f55bdaf2d7d5..9beee379610b 100755 --- a/keyboards/ergodox_ez/util/keymap_beautifier/KeymapBeautifier.py +++ b/keyboards/ergodox_ez/util/keymap_beautifier/KeymapBeautifier.py @@ -227,7 +227,6 @@ def grab_next_n_columns(self, n_columns, input_layout, layer_keys = None, from_b self.layer_keys_pointer = 0 begin = self.layer_keys_pointer - end = begin + n_columns return self.layer_keys[self.layer_keys_pointer-n_keys:self.layer_keys_pointer] key_coordinates_counter = 0 diff --git a/keyboards/kprepublic/bm80/bm80.c b/keyboards/kprepublic/bm80/bm80.c new file mode 100644 index 000000000000..8a0d26e87d9f --- /dev/null +++ b/keyboards/kprepublic/bm80/bm80.c @@ -0,0 +1,142 @@ +/* Copyright 2021 peepeetee + * + * 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 . + */ + +#include "bm80.h" + +#ifdef RGB_MATRIX_ENABLE +led_config_t g_led_config = { { + // Key Matrix to LED Index + { 0, NO_LED, 1, 2, 3, 4, NO_LED, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15 }, + { 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32 }, + { 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49 }, + { 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 11, 62, NO_LED, NO_LED, NO_LED }, + /* ^ this one is f11*/ + { 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, NO_LED, 74, NO_LED, NO_LED, 75, NO_LED }, + { 76, 77, 78, NO_LED, NO_LED, 79, NO_LED, NO_LED, NO_LED, 80, 81, 82, 83, 84, NO_LED, 85, 86 } + +// K0_0, K0_2, K0_3, K0_4, K0_5, K0_7, K0_8, K0_9, K0_A, K0_B, K0_C, K3_C, K0_D, K0_E, K0_F, K0_10, +// K1_0, K1_1, K1_2, K1_3, K1_4, K1_5, K1_6, K1_7, K1_8, K1_9, K1_A, K1_B, K1_C, K1_D, K1_E, K1_F, K1_10, +// K2_0, K2_1, K2_2, K2_3, K2_4, K2_5, K2_6, K2_7, K2_8, K2_9, K2_A, K2_B, K2_C, K2_D, K2_E, K2_F, K2_10, +// K3_0, K3_1, K3_2, K3_3, K3_4, K3_5, K3_6, K3_7, K3_8, K3_9, K3_A, K3_B, K3_D, +// K4_0, K4_1, K4_2, K4_3, K4_4, K4_5, K4_6, K4_7, K4_8, K4_9, K4_A, K4_C, K4_F, +// K5_0, K5_1, K5_2, K5_5, K5_9, K5_A, K5_B, K5_C, K5_D, K5_F, K5_10 + + +// K0_0, KC_NO, K0_2, K0_3, K0_4, K0_5, KC_NO, K0_7, K0_8, K0_9, K0_A, K0_B, K0_C, K0_D, K0_E, K0_F, K0_10 +// K1_0, K1_1, K1_2, K1_3, K1_4, K1_5, K1_6, K1_7, K1_8, K1_9, K1_A, K1_B, K1_C, K1_D, K1_E, K1_F, K1_10 +// K2_0, K2_1, K2_2, K2_3, K2_4, K2_5, K2_6, K2_7, K2_8, K2_9, K2_A, K2_B, K2_C, K2_D, K2_E, K2_F, K2_10 +// K3_0, K3_1, K3_2, K3_3, K3_4, K3_5, K3_6, K3_7, K3_8, K3_9, K3_A, K3_B, K3_C, K3_D, KC_NO, KC_NO, KC_NO +// K4_0, K4_1, K4_2, K4_3, K4_4, K4_5, K4_6, K4_7, K4_8, K4_9, K4_A, KC_NO, K4_C, KC_NO, KC_NO, K4_F, KC_NO +// K5_0, K5_1, K5_2, KC_NO, KC_NO, K5_5, KC_NO, KC_NO, KC_NO, K5_9, K5_A, K5_B, K5_C, K5_D, KC_NO, K5_F, K5_10 + + /* + * ┌───┐   ┌───┬───┬───┬───┐ ┌───┬───┬───┬───┐ ┌───┬───┬───┬───┐ ┌───┬───┬───┐ + * │ 0 │   │ 1 │ 2 │ 3 │ 4 │ │ 5 │ 6 │ 7 │ 8 │ │ 9 │ 10│ 11│ 12│ │ 13│ 14│ 15│ + * └───┘   └───┴───┴───┴───┘ └───┴───┴───┴───┘ └───┴───┴───┴───┘ └───┴───┴───┘ + * ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───────┐ ┌───┬───┬───┐ + * │ 16│ 17│ 18│ 19│ 20│ 21│ 22│ 23│ 24│ 25│ 26│ 27│ 28│  29 │ │ 30│ 31│ 32│ + * ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─────┤ ├───┼───┼───┤ + * │  33 │ 34│ 35│ 36│ 37│ 38│ 39│ 40│ 41│ 42│ 43│ 44│ 45│  46 │ │ 47│ 48│ 49│ + * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┤ └───┴───┴───┘ + * │ 50  │ 51│ 52│ 53│ 54│ 55│ 56│ 57│ 58│ 59│ 60│ 61│   62  │ + * ├──────┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────────┤     ┌───┐ + * │ 63   │ 64│ 65│ 66│ 67│ 68│ 69│ 70│ 71│ 72│ 73│    74  │     │ 75│ + * ├────┬───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┼───┴┬────┬────┤ ┌───┼───┼───┐ + * │ 76 │ 77 │ 78 │           79           │ 80 │ 81 │ 82 │ 83 │ │ 84│ 85│ 86│ + * └────┴────┴────┴────────────────────────┴────┴────┴────┴────┘ └───┴───┴───┘ + */ + +}, { + // LED Index to Physical Position + { 7, 5 }, { 31, 5 }, { 43, 5 }, { 55, 5 }, { 67, 5 }, { 85, 5 }, { 97, 5 }, { 109, 5 }, { 121, 5 }, { 139, 5 }, { 151, 5 }, { 163, 5 }, { 175, 5 }, { 193, 5 }, { 205, 5 }, { 217, 5 }, + /* + * ┌───┐   ┌───┬───┬───┬───┐ ┌───┬───┬───┬───┐ ┌───┬───┬───┬───┐ ┌───┬───┬───┐ + * │ 0 │   │ 1 │ 2 │ 3 │ 4 │ │ 5 │ 6 │ 7 │ 8 │ │ 9 │ 10│ 11│ 12│ │ 13│ 14│ 15│ + * └───┘   └───┴───┴───┴───┘ └───┴───┴───┴───┘ └───┴───┴───┴───┘ └───┴───┴───┘ + */ + { 7, 20 }, { 19, 20 }, { 31, 20 }, { 43, 20 }, { 55, 20 }, { 67, 20 }, { 79, 20 }, { 91, 20 }, { 103, 20 }, { 115, 20 }, { 127, 20 }, { 139, 20 }, { 151, 20 }, { 169, 20 }, { 193, 20 }, { 205, 20 }, { 217, 20 }, + /* + * ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───────┐ ┌───┬───┬───┐ + * │ 16│ 17│ 18│ 19│ 20│ 21│ 22│ 23│ 24│ 25│ 26│ 27│ 28│  29 │ │ 30│ 31│ 32│ + * └───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───────┘ └───┴───┴───┘ + */ + { 10, 30 }, { 25, 30 }, { 37, 30 }, { 49, 30 }, { 61, 30 }, { 73, 30 }, { 85, 30 }, { 97, 30 }, { 109, 30 }, { 121, 30 }, { 133, 30 }, { 145, 30 }, { 157, 30 }, { 172, 30 }, { 193, 30 }, { 205, 30 }, { 217, 30 }, + /* + * ┌─────┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬─────┐ ┌───┬───┬───┐ + * │  33 │ 34│ 35│ 36│ 37│ 38│ 39│ 40│ 41│ 42│ 43│ 44│ 45│  46 │ │ 47│ 48│ 49│ + * └─────┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴─────┘ └───┴───┴───┘ + */ + { 11, 39 }, { 28, 39 }, { 40, 39 }, { 52, 39 }, { 64, 39 }, { 76, 39 }, { 88, 39 }, { 100, 39 }, { 112, 39 }, { 124, 39 }, { 136, 39 }, { 148, 39 }, { 168, 39 }, + /* + * ┌──────┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬────────┐ + * │ 50  │ 51│ 52│ 53│ 54│ 55│ 56│ 57│ 58│ 59│ 60│ 61│   62  │ + * └──────┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴────────┘ + */ + { 14, 49 }, { 34, 49 }, { 46, 49 }, { 58, 49 }, { 70, 49 }, { 82, 49 }, { 94, 49 }, { 106, 49 }, { 118, 49 }, { 130, 49 }, { 142, 49 }, { 165, 49 }, { 205, 49 }, + /* + * ┌────────┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬──────────┐     ┌───┐ + * │ 63   │ 64│ 65│ 66│ 67│ 68│ 69│ 70│ 71│ 72│ 73│    74  │     │ 75│ + * └────────┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴──────────┘  └───┘ + */ + { 8, 59 }, { 23, 59 }, { 38, 59 }, { 83, 59 }, { 129, 59 }, { 144, 59 }, { 159, 59 }, { 174, 59 }, { 193, 59 }, { 205, 59 }, { 217, 59 } + /* + * ┌────┬────┬────┬────────────────────────┬────┬────┬────┬────┐ ┌───┬───┬───┐ + * │ 76 │ 77 │ 78 │           79           │ 80 │ 81 │ 82 │ 83 │ │ 84│ 85│ 86│ + * └────┴────┴────┴────────────────────────┴────┴────┴────┴────┘ └───┴───┴───┘ + */ +}, { + // LED Index to Flag + 1, 4, 4, 4, 4, 1, 1, 1, 1, 4, 4, 4, 4, 1, 9/*scroll lock*/, 1, + /* + * ┌───┐   ┌───┬───┬───┬───┐ ┌───┬───┬───┬───┐ ┌───┬───┬───┬───┐ ┌───┬───┬───┐ + * │ 0 │   │ 1 │ 2 │ 3 │ 4 │ │ 5 │ 6 │ 7 │ 8 │ │ 9 │ 10│ 11│ 12│ │ 13│ 14│ 15│ + * └───┘   └───┴───┴───┴───┘ └───┴───┴───┴───┘ └───┴───┴───┴───┘ └───┴───┴───┘ + */ + 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 1, 1, 1, + /* + * ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───────┐ ┌───┬───┬───┐ + * │ 16│ 17│ 18│ 19│ 20│ 21│ 22│ 23│ 24│ 25│ 26│ 27│ 28│  29 │ │ 30│ 31│ 32│ + * └───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───────┘ └───┴───┴───┘ + */ + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 1, 1, + /* + * ┌─────┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬─────┐ ┌───┬───┬───┐ + * │  33 │ 34│ 35│ 36│ 37│ 38│ 39│ 40│ 41│ 42│ 43│ 44│ 45│  46 │ │ 47│ 48│ 49│ + * └─────┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴─────┘ └───┴───┴───┘ + */ + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, + //caps lock is 1 instead of 1+8, this board has a dedicated led + /* + * ┌──────┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬────────┐ + * │ 50  │ 51│ 52│ 53│ 54│ 55│ 56│ 57│ 58│ 59│ 60│ 61│   62  │ + * └──────┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴────────┘ + */ + 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 1, + /* + * ┌────────┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬──────────┐     ┌───┐ + * │ 63   │ 64│ 65│ 66│ 67│ 68│ 69│ 70│ 71│ 72│ 73│    74  │     │ 75│ + * └────────┴───┴───┴───┴───┴───┴───┴───┴───┴───┴───┴──────────┘  └───┘ + */ + 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1 + /* + * ┌────┬────┬────┬────────────────────────┬────┬────┬────┬────┐ ┌───┬───┬───┐ + * │ 76 │ 77 │ 78 │           79           │ 80 │ 81 │ 82 │ 83 │ │ 84│ 85│ 86│ + * └────┴────┴────┴────────────────────────┴────┴────┴────┴────┘ └───┴───┴───┘ + */ +} }; + + +#endif diff --git a/keyboards/kprepublic/bm80/bm80.h b/keyboards/kprepublic/bm80/bm80.h new file mode 100644 index 000000000000..450befe882dd --- /dev/null +++ b/keyboards/kprepublic/bm80/bm80.h @@ -0,0 +1,43 @@ +/* Copyright 2021 peepeetee + * + * 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 . + */ + +#pragma once + +#include "quantum.h" + +/* This is a shortcut to help you visually see your layout. + * + * The first section contains all of the arguments representing the physical + * layout of the board and position of the keys. + * + * The second converts the arguments into a two-dimensional array which + * represents the switch matrix. + */ +#define LAYOUT_tkl_ansi( \ + K0_0, K0_2, K0_3, K0_4, K0_5, K0_7, K0_8, K0_9, K0_A, K0_B, K0_C, K3_C, K0_D, K0_E, K0_F, K0_10, \ + K1_0, K1_1, K1_2, K1_3, K1_4, K1_5, K1_6, K1_7, K1_8, K1_9, K1_A, K1_B, K1_C, K1_D, K1_E, K1_F, K1_10, \ + K2_0, K2_1, K2_2, K2_3, K2_4, K2_5, K2_6, K2_7, K2_8, K2_9, K2_A, K2_B, K2_C, K2_D, K2_E, K2_F, K2_10, \ + K3_0, K3_1, K3_2, K3_3, K3_4, K3_5, K3_6, K3_7, K3_8, K3_9, K3_A, K3_B, K3_D, \ + K4_0, K4_1, K4_2, K4_3, K4_4, K4_5, K4_6, K4_7, K4_8, K4_9, K4_A, K4_C, K4_F, \ + K5_0, K5_1, K5_2, K5_5, K5_9, K5_A, K5_B, K5_C, K5_D, K5_F, K5_10 \ +) { \ + { K0_0, KC_NO, K0_2, K0_3, K0_4, K0_5, KC_NO, K0_7, K0_8, K0_9, K0_A, K0_B, K0_C, K0_D, K0_E, K0_F, K0_10 }, \ + { K1_0, K1_1, K1_2, K1_3, K1_4, K1_5, K1_6, K1_7, K1_8, K1_9, K1_A, K1_B, K1_C, K1_D, K1_E, K1_F, K1_10 }, \ + { K2_0, K2_1, K2_2, K2_3, K2_4, K2_5, K2_6, K2_7, K2_8, K2_9, K2_A, K2_B, K2_C, K2_D, K2_E, K2_F, K2_10 }, \ + { K3_0, K3_1, K3_2, K3_3, K3_4, K3_5, K3_6, K3_7, K3_8, K3_9, K3_A, K3_B, K3_C, K3_D, KC_NO, KC_NO, KC_NO }, \ + { K4_0, K4_1, K4_2, K4_3, K4_4, K4_5, K4_6, K4_7, K4_8, K4_9, K4_A, KC_NO, K4_C, KC_NO, KC_NO, K4_F, KC_NO }, \ + { K5_0, K5_1, K5_2, KC_NO, KC_NO, K5_5, KC_NO, KC_NO, KC_NO, K5_9, K5_A, K5_B, K5_C, K5_D, KC_NO, K5_F, K5_10 } \ +} diff --git a/keyboards/kprepublic/bm80/config.h b/keyboards/kprepublic/bm80/config.h new file mode 100644 index 000000000000..584fdec98966 --- /dev/null +++ b/keyboards/kprepublic/bm80/config.h @@ -0,0 +1,99 @@ +/* +Copyright 2021 peepeetee + +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 . +*/ + +#pragma once + +#include "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x4B50 //KP +#define PRODUCT_ID 0xEF83 +#define DEVICE_VER 0x0001 +#define MANUFACTURER KPRepublic +#define PRODUCT BM80HSRGB + +/* key matrix size */ +#define MATRIX_ROWS 6 +#define MATRIX_COLS 17 + +/* + * Keyboard Matrix Assignments + * + * Change this to how you wired your keyboard + * COLS: AVR pins used for columns, left to right + * ROWS: AVR pins used for rows, top to bottom + * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) + * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) + * + */ +#define MATRIX_ROW_PINS { B3, B2, B1, B0, C6, C7 } +#define MATRIX_COL_PINS { F0, F1, F4, D7, D6, D4, D5, D3, D2, F5, F6, F7, D1, D0, B4, B5, B6 } +#define UNUSED_PINS + +/* COL2ROW, ROW2COL */ +#define DIODE_DIRECTION COL2ROW + + + + +#define LED_CAPS_LOCK_PIN E6 +#define LED_PIN_ON_STATE 0 + + +#define RGB_DI_PIN E2 +// The number of LEDs connected +#define DRIVER_LED_TOTAL 87 + +#ifdef RGB_DI_PIN +#define RGBLED_NUM 87 +#define RGB_MATRIX_KEYPRESSES // reacts to keypresses +//#define RGB_MATRIX_KEYRELEASES // reacts to keyreleases (instead of keypresses) +#define RGB_MATRIX_FRAMEBUFFER_EFFECTS +#define RGB_DISABLE_TIMEOUT 0 // number of milliseconds to wait until rgb automatically turns off +//#define RGB_MATRIX_LED_PROCESS_LIMIT (DRIVER_LED_TOTAL + 4) / 5 // limits the number of LEDs to process in an animation per task run (increases keyboard responsiveness) +#define RGB_MATRIX_LED_FLUSH_LIMIT 16 // limits in milliseconds how frequently an animation will update the LEDs. 16 (16ms) is equivalent to limiting to 60fps (increases keyboard responsiveness) +// #define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 // limits maximum brightness of LEDs to 200 out of 255. If not defined maximum brightness is set to 255 +#define RGB_MATRIX_STARTUP_MODE RGB_MATRIX_CYCLE_LEFT_RIGHT // Sets the default mode, if none has been set +#define RGB_MATRIX_STARTUP_HUE 0 // Sets the default hue value, if none has been set +#define RGB_MATRIX_STARTUP_SAT 255 // Sets the default saturation value, if none has been set +#define RGB_MATRIX_STARTUP_VAL RGB_MATRIX_MAXIMUM_BRIGHTNESS // Sets the default brightness value, if none has been set +#define RGB_MATRIX_STARTUP_SPD 127 // Sets the default animation speed, if none has been set +// #define RGB_MATRIX_DISABLE_KEYCODES // disables control of rgb matrix by keycodes (must use code functions to control the feature) + + + +// # define RGB_DISABLE_WHEN_USB_SUSPENDED // turn off effects when suspended +// does not work for some reason, might revisit + + + +#endif + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + +/* define if matrix has ghost (lacks anti-ghosting diodes) */ +//#define MATRIX_HAS_GHOST + +/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ +#define LOCKING_SUPPORT_ENABLE +/* Locking resynchronize hack */ +#define LOCKING_RESYNC_ENABLE + +/* disable these deprecated features by default */ +#define NO_ACTION_MACRO +#define NO_ACTION_FUNCTION diff --git a/keyboards/kprepublic/bm80/info.json b/keyboards/kprepublic/bm80/info.json new file mode 100644 index 000000000000..8c7a0056b3de --- /dev/null +++ b/keyboards/kprepublic/bm80/info.json @@ -0,0 +1,98 @@ +{ + "keyboard_name": "bm80", + "url": "", + "maintainer": "peepeetee", + "layouts": { + "LAYOUT_tkl_ansi": { + "layout": [ + {"label":"K0_0 (B3,F0)", "x":0, "y":0}, + {"label":"K0_2 (B3,F4)", "x":2, "y":0}, + {"label":"K0_3 (B3,D7)", "x":3, "y":0}, + {"label":"K0_4 (B3,D6)", "x":4, "y":0}, + {"label":"K0_5 (B3,D4)", "x":5, "y":0}, + {"label":"K0_7 (B3,D3)", "x":6.5, "y":0}, + {"label":"K0_8 (B3,D2)", "x":7.5, "y":0}, + {"label":"K0_9 (B3,F5)", "x":8.5, "y":0}, + {"label":"K0_A (B3,F6)", "x":9.5, "y":0}, + {"label":"K0_B (B3,F7)", "x":11, "y":0}, + {"label":"K0_C (B3,D1)", "x":12, "y":0}, + {"label":"K3_C (B0,D1)", "x":13, "y":0}, + {"label":"K0_D (B3,D0)", "x":14, "y":0}, + {"label":"K0_E (B3,B4)", "x":15.25, "y":0}, + {"label":"K0_F (B3,B5)", "x":16.25, "y":0}, + {"label":"K0_10 (B3,B6)", "x":17.25, "y":0}, + {"label":"K1_0 (B2,F0)", "x":0, "y":1.5}, + {"label":"K1_1 (B2,F1)", "x":1, "y":1.5}, + {"label":"K1_2 (B2,F4)", "x":2, "y":1.5}, + {"label":"K1_3 (B2,D7)", "x":3, "y":1.5}, + {"label":"K1_4 (B2,D6)", "x":4, "y":1.5}, + {"label":"K1_5 (B2,D4)", "x":5, "y":1.5}, + {"label":"K1_6 (B2,D5)", "x":6, "y":1.5}, + {"label":"K1_7 (B2,D3)", "x":7, "y":1.5}, + {"label":"K1_8 (B2,D2)", "x":8, "y":1.5}, + {"label":"K1_9 (B2,F5)", "x":9, "y":1.5}, + {"label":"K1_A (B2,F6)", "x":10, "y":1.5}, + {"label":"K1_B (B2,F7)", "x":11, "y":1.5}, + {"label":"K1_C (B2,D1)", "x":12, "y":1.5}, + {"label":"K1_D (B2,D0)", "x":13, "y":1.5, "w":2}, + {"label":"K1_E (B2,B4)", "x":15.25, "y":1.5}, + {"label":"K1_F (B2,B5)", "x":16.25, "y":1.5}, + {"label":"K1_10 (B2,B6)", "x":17.25, "y":1.5}, + {"label":"K2_0 (B1,F0)", "x":0, "y":2.5, "w":1.5}, + {"label":"K2_1 (B1,F1)", "x":1.5, "y":2.5}, + {"label":"K2_2 (B1,F4)", "x":2.5, "y":2.5}, + {"label":"K2_3 (B1,D7)", "x":3.5, "y":2.5}, + {"label":"K2_4 (B1,D6)", "x":4.5, "y":2.5}, + {"label":"K2_5 (B1,D4)", "x":5.5, "y":2.5}, + {"label":"K2_6 (B1,D5)", "x":6.5, "y":2.5}, + {"label":"K2_7 (B1,D3)", "x":7.5, "y":2.5}, + {"label":"K2_8 (B1,D2)", "x":8.5, "y":2.5}, + {"label":"K2_9 (B1,F5)", "x":9.5, "y":2.5}, + {"label":"K2_A (B1,F6)", "x":10.5, "y":2.5}, + {"label":"K2_B (B1,F7)", "x":11.5, "y":2.5}, + {"label":"K2_C (B1,D1)", "x":12.5, "y":2.5}, + {"label":"K2_D (B1,D0)", "x":13.5, "y":2.5, "w":1.5}, + {"label":"K2_E (B1,B4)", "x":15.25, "y":2.5}, + {"label":"K2_F (B1,B5)", "x":16.25, "y":2.5}, + {"label":"K2_10 (B1,B6)", "x":17.25, "y":2.5}, + {"label":"K3_0 (B0,F0)", "x":0, "y":3.5, "w":1.75}, + {"label":"K3_1 (B0,F1)", "x":1.75, "y":3.5}, + {"label":"K3_2 (B0,F4)", "x":2.75, "y":3.5}, + {"label":"K3_3 (B0,D7)", "x":3.75, "y":3.5}, + {"label":"K3_4 (B0,D6)", "x":4.75, "y":3.5}, + {"label":"K3_5 (B0,D4)", "x":5.75, "y":3.5}, + {"label":"K3_6 (B0,D5)", "x":6.75, "y":3.5}, + {"label":"K3_7 (B0,D3)", "x":7.75, "y":3.5}, + {"label":"K3_8 (B0,D2)", "x":8.75, "y":3.5}, + {"label":"K3_9 (B0,F5)", "x":9.75, "y":3.5}, + {"label":"K3_A (B0,F6)", "x":10.75, "y":3.5}, + {"label":"K3_B (B0,F7)", "x":11.75, "y":3.5}, + {"label":"K3_D (B0,D0)", "x":12.75, "y":3.5, "w":2.25}, + {"label":"K4_0 (C6,F0)", "x":0, "y":4.5, "w":2.25}, + {"label":"K4_1 (C6,F1)", "x":2.25, "y":4.5}, + {"label":"K4_2 (C6,F4)", "x":3.25, "y":4.5}, + {"label":"K4_3 (C6,D7)", "x":4.25, "y":4.5}, + {"label":"K4_4 (C6,D6)", "x":5.25, "y":4.5}, + {"label":"K4_5 (C6,D4)", "x":6.25, "y":4.5}, + {"label":"K4_6 (C6,D5)", "x":7.25, "y":4.5}, + {"label":"K4_7 (C6,D3)", "x":8.25, "y":4.5}, + {"label":"K4_8 (C6,D2)", "x":9.25, "y":4.5}, + {"label":"K4_9 (C6,F5)", "x":10.25, "y":4.5}, + {"label":"K4_A (C6,F6)", "x":11.25, "y":4.5}, + {"label":"K4_C (C6,D1)", "x":12.25, "y":4.5, "w":2.75}, + {"label":"K4_F (C6,B5)", "x":16.25, "y":4.5}, + {"label":"K5_0 (C7,F0)", "x":0, "y":5.5, "w":1.25}, + {"label":"K5_1 (C7,F1)", "x":1.25, "y":5.5, "w":1.25}, + {"label":"K5_2 (C7,F4)", "x":2.5, "y":5.5, "w":1.25}, + {"label":"K5_5 (C7,D4)", "x":3.75, "y":5.5, "w":6.25}, + {"label":"K5_9 (C7,F5)", "x":10, "y":5.5, "w":1.25}, + {"label":"K5_A (C7,F6)", "x":11.25, "y":5.5, "w":1.25}, + {"label":"K5_B (C7,F7)", "x":12.5, "y":5.5, "w":1.25}, + {"label":"K5_C (C7,D1)", "x":13.75, "y":5.5, "w":1.25}, + {"label":"K5_D (C7,D0)", "x":15.25, "y":5.5}, + {"label":"K5_F (C7,B5)", "x":16.25, "y":5.5}, + {"label":"K5_10 (C7,B6)", "x":17.25, "y":5.5} + ] + } + } +} \ No newline at end of file diff --git a/keyboards/kprepublic/bm80/keymaps/default/keymap.c b/keyboards/kprepublic/bm80/keymaps/default/keymap.c new file mode 100644 index 000000000000..d86c6f9ec8d8 --- /dev/null +++ b/keyboards/kprepublic/bm80/keymaps/default/keymap.c @@ -0,0 +1,51 @@ +/* Copyright 2021 peepeetee + * + * 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 . + */ +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT_tkl_ansi( + KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS, + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, + KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + + [1] = LAYOUT_tkl_ansi( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, RESET, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ) + +/* + [X] = LAYOUT_tkl_ansi( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), +*/ + + +}; + diff --git a/keyboards/kprepublic/bm80/keymaps/default/readme.md b/keyboards/kprepublic/bm80/keymaps/default/readme.md new file mode 100644 index 000000000000..8ad360ebda28 --- /dev/null +++ b/keyboards/kprepublic/bm80/keymaps/default/readme.md @@ -0,0 +1 @@ +# The default keymap for bm80 diff --git a/keyboards/kprepublic/bm80/keymaps/peepeetee/config.h b/keyboards/kprepublic/bm80/keymaps/peepeetee/config.h new file mode 100644 index 000000000000..b322afae9be4 --- /dev/null +++ b/keyboards/kprepublic/bm80/keymaps/peepeetee/config.h @@ -0,0 +1,97 @@ +/* Copyright 2021 peepeetee + * + * 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 . + */ +#pragma once + + + +// #define IS_COMMAND() (get_mods() == MOD_MASK_SHIFT) // Key combination that allows the use of magic commands (useful for debugging) + +// #define TERMINAL_HELP + +#define FORCE_NKRO // NKRO by default requires to be turned on, this forces it on during keyboard startup regardless of EEPROM setting. NKRO can still be turned off but will be turned on again if the keyboard reboots. +// #define QMK_KEYS_PER_SCAN 4 // Allows sending more than one key per scan. By default, only one key event gets sent via process_record() per scan. This has little impact on most typing, but if you're doing a lot of chords, or your scan rate is slow to begin with, you can have some delay in processing key events. Each press and release is a separate event. For a keyboard with 1ms or so scan times, even a very fast typist isn't going to produce the 500 keystrokes a second needed to actually get more than a few ms of delay from this. But if you're doing chording on something with 3-4ms scan times? You probably want this. +// #define STRICT_LAYER_RELEASE // Force a key release to be evaluated using the current layer stack instead of remembering which layer it came from (used for advanced cases) +// #define TAPPING_TERM 200 // How long before a tap becomes a hold, if set above 500, a key tapped during the tapping term will turn it into a hold too +// #define TAPPING_TERM_PER_KEY // Enables handling for per key TAPPING_TERM settings +// #define RETRO_TAPPING // Tap anyway, even after TAPPING_TERM, if there was no other key interruption between press and release +// #define TAPPING_TOGGLE 2 // How many taps before triggering the toggle +// #define PERMISSIVE_HOLD // Makes tap and hold keys trigger the hold if another key is pressed before releasing, even if it hasn't hit the TAPPING_TERM. See Permissive Hold for details +// #define IGNORE_MOD_TAP_INTERRUPT // Makes it possible to do rolling combos (zx) with keys that convert to other keys on hold, by enforcing the TAPPING_TERM for both keys. See Mod tap interrupt for details +// #define TAPPING_FORCE_HOLD // Makes it possible to use a dual role key as modifier shortly after having been tapped. See Hold after tap. Breaks any Tap Toggle functionality (TT or the One Shot Tap Toggle) +// #define LEADER_TIMEOUT 300 // How long before the leader key times out. If you're having issues finishing the sequence before it times out, you may need to increase the timeout setting. Or you may want to enable the LEADER_PER_KEY_TIMING option, which resets the timeout after each key is tapped. +// #define LEADER_PER_KEY_TIMING // Sets the timer for leader key chords to run on each key press rather than overall +// #define LEADER_KEY_STRICT_KEY_PROCESSING // Disables keycode filtering for Mod-Tap and Layer-Tap keycodes. Eg, if you enable this, you would need to specify MT(MOD_CTL, KC_A) if you want to use KC_A. +// #define ONESHOT_TIMEOUT 300 // How long before oneshot times out +// #define ONESHOT_TAP_TOGGLE 2 // How many taps before oneshot toggle is triggered +// #define COMBO_COUNT 2 // Set this to the number of combos that you're using in the Combo feature. +// #define COMBO_TERM 200 // How long for the Combo keys to be detected. Defaults to TAPPING_TERM if not defined. +// #define TAP_CODE_DELAY 100 // Sets the delay between register_code and unregister_code, if you're having issues with it registering properly (common on VUSB boards). The value is in milliseconds. +// #define TAP_HOLD_CAPS_DELAY 80 // Sets the delay for Tap Hold keys (LT, MT) when using KC_CAPSLOCK keycode, as this has some special handling on MacOS. The value is in milliseconds, and defaults to 80 ms if not defined. For macOS, you may want to set this to 200 or higher. + +// #define RGB_MATRIX_FRAMEBUFFER_EFFECTS +// #define RGB_MATRIX_KEYPRESSES // reacts to keypresses +// #define RGB_MATRIX_KEYRELEASES // reacts to keyreleases (instead of keypresses) +// #define RGB_MATRIX_STARTUP_MODE RGB_MATRIX_ALPHAS_MODS // Sets the default mode, if none has been set +// #define RGB_DISABLE_AFTER_TIMEOUT 0 // number of ticks to wait until disabling effects +// #define RGB_DISABLE_WHEN_USB_SUSPENDED false // turn off effects when suspended +// #define RGB_MATRIX_LED_PROCESS_LIMIT (DRIVER_LED_TOTAL + 4) / 5 // limits the number of LEDs to process in an animation per task run (increases keyboard responsiveness) +// #define RGB_MATRIX_LED_FLUSH_LIMIT 16 // limits in milliseconds how frequently an animation will update the LEDs. 16 (16ms) is equivalent to limiting to 60fps (increases keyboard responsiveness) + + +// This list in in the correct mode order. Next mode is the following line, previous mode is previous line. Loops around. +// #define DISABLE_RGB_MATRIX_SOLID_COLOR // Static single hue, no speed support +// #define DISABLE_RGB_MATRIX_ALPHAS_MODS // Static dual hue, speed is hue for secondary hue +#define DISABLE_RGB_MATRIX_GRADIENT_UP_DOWN // Static gradient top to bottom, speed controls how much gradient changes +#define DISABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT // Static gradient top to bottom, speed controls how much gradient changes +#define DISABLE_RGB_MATRIX_BREATHING // Single hue brightness cycling animation +#define DISABLE_RGB_MATRIX_BAND_SAT // Single hue band fading saturation scrolling left to right +#define DISABLE_RGB_MATRIX_BAND_VAL // Single hue band fading brightness scrolling left to right +#define DISABLE_RGB_MATRIX_BAND_PINWHEEL_SAT // Single hue 3 blade spinning pinwheel fades saturation +#define DISABLE_RGB_MATRIX_BAND_PINWHEEL_VAL // Single hue 3 blade spinning pinwheel fades brightness +#define DISABLE_RGB_MATRIX_BAND_SPIRAL_SAT // Single hue spinning spiral fades saturation +#define DISABLE_RGB_MATRIX_BAND_SPIRAL_VAL // Single hue spinning spiral fades brightness +#define DISABLE_RGB_MATRIX_CYCLE_ALL // Full keyboard solid hue cycling through full gradient +//#define DISABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT // Full gradient scrolling left to right +#define DISABLE_RGB_MATRIX_CYCLE_UP_DOWN // Full gradient scrolling top to bottom +#define DISABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON // Full gradent Chevron shapped scrolling left to right +#define DISABLE_RGB_MATRIX_CYCLE_OUT_IN // Full gradient scrolling out to in +#define DISABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL // Full dual gradients scrolling out to in +#define DISABLE_RGB_MATRIX_CYCLE_PINWHEEL // Full gradient spinning pinwheel around center of keyboard +#define DISABLE_RGB_MATRIX_CYCLE_SPIRAL // Full gradient spinning spiral around center of keyboard +#define DISABLE_RGB_MATRIX_DUAL_BEACON // Full gradient spinning around center of keyboard +#define DISABLE_RGB_MATRIX_RAINBOW_BEACON // Full tighter gradient spinning around center of keyboard +#define DISABLE_RGB_MATRIX_RAINBOW_PINWHEELS // Full dual gradients spinning two halfs of keyboard +#define DISABLE_RGB_MATRIX_RAINDROPS // Randomly changes a single key's hue +#define DISABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS // Randomly changes a single key's hue and saturation +#define DISABLE_RGB_MATRIX_HUE_BREATHING // Hue shifts up a slight ammount at the same time, then shifts back +#define DISABLE_RGB_MATRIX_HUE_PENDULUM // Hue shifts up a slight ammount in a wave to the right, then back to the left +#define DISABLE_RGB_MATRIX_HUE_WAVE // Hue shifts up a slight ammount and then back down in a wave to the right +// =================================================== Requires RGB_MATRIX_FRAMEBUFFER_EFFECTS ============================================================= +// #define DISABLE_RGB_MATRIX_TYPING_HEATMAP // How hot is your WPM! +#define DISABLE_RGB_MATRIX_DIGITAL_RAIN // That famous computer simulation +// =================================================== RGB_MATRIX_KEYPRESSES OR RGB_MATRIX_KEYRELEASES ===================================================== +#define DISABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE // Pulses keys hit to hue & value then fades value out +#define DISABLE_RGB_MATRIX_SOLID_REACTIVE // Static single hue, pulses keys hit to shifted hue then fades to current hue +#define DISABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE // Hue & value pulse near a single key hit then fades value out +#define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE // Hue & value pulse near multiple key hits then fades value out +#define DISABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS // Hue & value pulse the same column and row of a single key hit then fades value out +#define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS // Hue & value pulse the same column and row of multiple key hits then fades value out +#define DISABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS // Hue & value pulse away on the same column and row of a single key hit then fades value out +#define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS // Hue & value pulse away on the same column and row of multiple key hits then fades value out +#define DISABLE_RGB_MATRIX_SPLASH // Full gradient & value pulse away from a single key hit then fades value out +//#define DISABLE_RGB_MATRIX_MULTISPLASH // Full gradient & value pulse away from multiple key hits then fades value out +#define DISABLE_RGB_MATRIX_SOLID_SPLASH // Hue & value pulse away from a single key hit then fades value out +#define DISABLE_RGB_MATRIX_SOLID_MULTISPLASH // Hue & value pulse away from multiple key hits then fades value out diff --git a/keyboards/kprepublic/bm80/keymaps/peepeetee/keymap.c b/keyboards/kprepublic/bm80/keymaps/peepeetee/keymap.c new file mode 100644 index 000000000000..d4a188089bc9 --- /dev/null +++ b/keyboards/kprepublic/bm80/keymaps/peepeetee/keymap.c @@ -0,0 +1,51 @@ +/* Copyright 2021 peepeetee + * + * 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 . + */ +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT_tkl_ansi( + KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS, + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, + KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + + [1] = LAYOUT_tkl_ansi( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + RGB_MOD, RGB_HUI, RGB_VAI, RGB_SAI, RGB_SPI, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + RGB_TOG, RGB_HUD, RGB_VAD, RGB_SAD, RGB_SPD, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, RESET, _______, _______, _______, _______, _______, _______, KC_AUDIO_VOL_UP, + _______, _______, _______, _______, _______, _______, _______, _______, KC_BRIGHTNESS_DOWN, KC_AUDIO_VOL_DOWN, KC_BRIGHTNESS_UP + ) + +/* + [X] = LAYOUT_tkl_ansi( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), +*/ + + +}; + diff --git a/keyboards/kprepublic/bm80/keymaps/via/keymap.c b/keyboards/kprepublic/bm80/keymaps/via/keymap.c new file mode 100644 index 000000000000..53b2981c5eed --- /dev/null +++ b/keyboards/kprepublic/bm80/keymaps/via/keymap.c @@ -0,0 +1,57 @@ +/* Copyright 2021 peepeetee + * + * 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 . + */ +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT_tkl_ansi( + KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS, + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, + KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + + [1] = LAYOUT_tkl_ansi( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, RESET, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), + + [2] = LAYOUT_tkl_ansi( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), + + [3] = LAYOUT_tkl_ansi( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ) + +}; + diff --git a/keyboards/kprepublic/bm80/keymaps/via/readme.md b/keyboards/kprepublic/bm80/keymaps/via/readme.md new file mode 100644 index 000000000000..9fb42c24d867 --- /dev/null +++ b/keyboards/kprepublic/bm80/keymaps/via/readme.md @@ -0,0 +1 @@ +# The default VIA keymap for bm80 diff --git a/keyboards/kprepublic/bm80/keymaps/via/rules.mk b/keyboards/kprepublic/bm80/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/kprepublic/bm80/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/kprepublic/bm80/readme.md b/keyboards/kprepublic/bm80/readme.md new file mode 100644 index 000000000000..a0d8e8cf9a4c --- /dev/null +++ b/keyboards/kprepublic/bm80/readme.md @@ -0,0 +1,30 @@ +# bm80 + +![bm80](https://i.imgur.com/AqjEjOi.jpeg) + +A tkl, hotswap, in switch RGB keyboard from KPRepublic. + +* Keyboard Maintainer: [peepeetee](https://github.com/peepeetee) +* Hardware Supported: BM80 +* Hardware Availability: [KP Republic](https://kprepublic.com/collections/new-arrival/products/bm80rgb-bm80-rgb-80-hot-swappable-custom-mechanical-keyboard-pcb-programmed-qmk-via-firmware-full-rgb-switch-underglow-type-c) + +Make example for this keyboard (after setting up your build environment): + + make kprepublic/bm80:default + +Flashing example for this keyboard: + + make kprepublic/bm80:default:flash + +To reset the board into bootloader mode, do one of the following: + +* Short the two-pad footprint between the "delete" key and the "end" key while the board is plugged in +* Press the switch labled RST on the back of the PCB, near the MCU, while the board is plugged in +* Hold the Esc key while connecting the USB cable (also erases persistent settings) + +All of the RGB matrix effects are enabled by default. To disable specific ones, see [this section](https://docs.qmk.fm/#/feature_rgb_matrix?id=rgb-matrix-effects) for more information. + + +See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs). + + diff --git a/keyboards/kprepublic/bm80/rules.mk b/keyboards/kprepublic/bm80/rules.mk new file mode 100644 index 000000000000..0db27598972a --- /dev/null +++ b/keyboards/kprepublic/bm80/rules.mk @@ -0,0 +1,26 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = atmel-dfu + +# 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 +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = yes # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +AUDIO_ENABLE = no # Audio output +RGB_MATRIX_ENABLE = yes +RGB_MATRIX_DRIVER = WS2812 +LTO_ENABLE = yes + +LAYOUTS = tkl_ansi diff --git a/keyboards/mechlovin/adelais/adelais.h b/keyboards/mechlovin/adelais/adelais.h index 5a5673abc7b7..a6bd2477a3e7 100644 --- a/keyboards/mechlovin/adelais/adelais.h +++ b/keyboards/mechlovin/adelais/adelais.h @@ -46,4 +46,30 @@ { K40, KC_NO, K42, KC_NO, K44, KC_NO, K46, KC_NO, K48, KC_NO, K4A, KC_NO, KC_NO, K4D, K4E }, \ } -#define LAYOUT_all LAYOUT_alice_split_bs +#define LAYOUT_alice_split_bs_full_rshift( \ + K1E, K00, K01, K02, K03, K04, K05, K06, K07,K08,K09, K0A, K0B, K0C, K0D, K0E,\ + K2E, K10, K11, K12, K13, K14, K15, K16,K17,K18, K19, K1A, K1B, K1C, K1D,\ + K3E, K20, K21, K22, K23, K24, K25, K26,K27,K28, K29, K2A, K2B, K2D,\ + K30, K32, K33, K34, K35, K36, K37,K38,K39, K3A, K3B, K3D, K3C, \ + K40, K42, K44, K46, K48, K4A, K4E \ +) { \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E }, \ + { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E }, \ + { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, KC_NO, K2D, K2E }, \ + { K30, KC_NO, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, K3E }, \ + { K40, KC_NO, K42, KC_NO, K44, KC_NO, K46, KC_NO, K48, KC_NO, K4A, KC_NO, KC_NO, KC_NO, K4E }, \ +} + +#define LAYOUT_alice_full_rshift( \ + K1E, K00, K01, K02, K03, K04, K05, K06, K07,K08,K09, K0A, K0B, K0C, K0D, \ + K2E, K10, K11, K12, K13, K14, K15, K16,K17,K18, K19, K1A, K1B, K1C, K1D,\ + K3E, K20, K21, K22, K23, K24, K25, K26,K27,K28, K29, K2A, K2B, K2D,\ + K30, K32, K33, K34, K35, K36, K37,K38,K39, K3A, K3B, K3D, K3C, \ + K40, K42, K44, K46, K48, K4A, K4E \ +) { \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, KC_NO }, \ + { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E }, \ + { K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, KC_NO, K2D, K2E }, \ + { K30, KC_NO, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, K3E }, \ + { K40, KC_NO, K42, KC_NO, K44, KC_NO, K46, KC_NO, K48, KC_NO, K4A, KC_NO, KC_NO, KC_NO, K4E }, \ +} diff --git a/keyboards/mechlovin/adelais/info.json b/keyboards/mechlovin/adelais/info.json index 3ff03c2b6282..7a858277e7d3 100644 --- a/keyboards/mechlovin/adelais/info.json +++ b/keyboards/mechlovin/adelais/info.json @@ -1,7 +1,10 @@ { "keyboard_name": "Adelais", "url": "", - "maintainer": "Team Mechlovin'", + "maintainer": "mechlovin", + "layout_aliases": { + "LAYOUT_all": "LAYOUT_alice_split_bs" + }, "layouts": { "LAYOUT_alice_split_bs": { "layout": [ @@ -21,6 +24,7 @@ {"label":"K0C", "x":15.5, "y":0}, {"label":"K0D", "x":16.5, "y":0}, {"label":"K0E", "x":17.5, "y":0}, + {"label":"K2E", "x":0, "y":1}, {"label":"K10", "x":1.5, "y":1, "w":1.5}, {"label":"K11", "x":3, "y":1}, @@ -36,6 +40,7 @@ {"label":"K1B", "x":15, "y":1}, {"label":"K1C", "x":16, "y":1}, {"label":"K1D", "x":17, "y":1, "w":1.5}, + {"label":"K3E", "x":0, "y":2}, {"label":"K20", "x":1.5, "y":2, "w":1.75}, {"label":"K21", "x":3.25, "y":2}, @@ -50,6 +55,7 @@ {"label":"K2A", "x":14.25, "y":2}, {"label":"K2B", "x":15.25, "y":2}, {"label":"K2D", "x":16.25, "y":2, "w":2.25}, + {"label":"K30", "x":1.5, "y":3, "w":2.25}, {"label":"K32", "x":3.75, "y":3}, {"label":"K33", "x":4.75, "y":3}, @@ -61,9 +67,10 @@ {"label":"K39", "x":11.75, "y":3}, {"label":"K3A", "x":12.75, "y":3}, {"label":"K3B", "x":13.75, "y":3}, - {"label":"K4D", "x":14.75, "y":3}, + {"label":"K3D", "x":14.75, "y":3}, {"label":"K3C", "x":15.75, "y":3, "w":1.75}, - {"label":"K3D", "x":17.5, "y":3}, + {"label":"K4D", "x":17.5, "y":3}, + {"label":"K40", "x":1.5, "y":4, "w":1.5}, {"label":"K42", "x":4.5, "y":4, "w":1.25}, {"label":"K44", "x":5.75, "y":4, "w":2.25}, @@ -90,6 +97,7 @@ {"label":"K0B", "x":14.5, "y":0}, {"label":"K0C", "x":15.5, "y":0}, {"label":"K0D", "x":16.5, "y":0, "w":2}, + {"label":"K2E", "x":0, "y":1}, {"label":"K10", "x":1.5, "y":1, "w":1.5}, {"label":"K11", "x":3, "y":1}, @@ -105,6 +113,7 @@ {"label":"K1B", "x":15, "y":1}, {"label":"K1C", "x":16, "y":1}, {"label":"K1D", "x":17, "y":1, "w":1.5}, + {"label":"K3E", "x":0, "y":2}, {"label":"K20", "x":1.5, "y":2, "w":1.75}, {"label":"K21", "x":3.25, "y":2}, @@ -119,6 +128,7 @@ {"label":"K2A", "x":14.25, "y":2}, {"label":"K2B", "x":15.25, "y":2}, {"label":"K2D", "x":16.25, "y":2, "w":2.25}, + {"label":"K30", "x":1.5, "y":3, "w":2.25}, {"label":"K32", "x":3.75, "y":3}, {"label":"K33", "x":4.75, "y":3}, @@ -130,9 +140,155 @@ {"label":"K39", "x":11.75, "y":3}, {"label":"K3A", "x":12.75, "y":3}, {"label":"K3B", "x":13.75, "y":3}, - {"label":"K4D", "x":14.75, "y":3}, + {"label":"K3D", "x":14.75, "y":3}, {"label":"K3C", "x":15.75, "y":3, "w":1.75}, - {"label":"K3D", "x":17.5, "y":3}, + {"label":"K4D", "x":17.5, "y":3}, + + {"label":"K40", "x":1.5, "y":4, "w":1.5}, + {"label":"K42", "x":4.5, "y":4, "w":1.25}, + {"label":"K44", "x":5.75, "y":4, "w":2.25}, + {"label":"K46", "x":8, "y":4, "w":1.25}, + {"label":"K48", "x":9.75, "y":4, "w":2.75}, + {"label":"K4A", "x":12.5, "y":4, "w":1.25}, + {"label":"K4E", "x":17, "y":4, "w":1.5} + ] + }, + "LAYOUT_alice_split_bs_full_rshift": { + "layout": [ + {"label":"K1E", "x":0, "y":0}, + {"label":"K00", "x":1.5, "y":0}, + {"label":"K01", "x":2.5, "y":0}, + {"label":"K02", "x":3.5, "y":0}, + {"label":"K03", "x":4.5, "y":0}, + {"label":"K04", "x":5.5, "y":0}, + {"label":"K05", "x":6.5, "y":0}, + {"label":"K06", "x":7.5, "y":0}, + {"label":"K07", "x":10.5, "y":0}, + {"label":"K08", "x":11.5, "y":0}, + {"label":"K09", "x":12.5, "y":0}, + {"label":"K0A", "x":13.5, "y":0}, + {"label":"K0B", "x":14.5, "y":0}, + {"label":"K0C", "x":15.5, "y":0}, + {"label":"K0D", "x":16.5, "y":0}, + {"label":"K0E", "x":17.5, "y":0}, + + {"label":"K2E", "x":0, "y":1}, + {"label":"K10", "x":1.5, "y":1, "w":1.5}, + {"label":"K11", "x":3, "y":1}, + {"label":"K12", "x":4, "y":1}, + {"label":"K13", "x":5, "y":1}, + {"label":"K14", "x":6, "y":1}, + {"label":"K15", "x":7, "y":1}, + {"label":"K16", "x":10, "y":1}, + {"label":"K17", "x":11, "y":1}, + {"label":"K18", "x":12, "y":1}, + {"label":"K19", "x":13, "y":1}, + {"label":"K1A", "x":14, "y":1}, + {"label":"K1B", "x":15, "y":1}, + {"label":"K1C", "x":16, "y":1}, + {"label":"K1D", "x":17, "y":1, "w":1.5}, + + {"label":"K3E", "x":0, "y":2}, + {"label":"K20", "x":1.5, "y":2, "w":1.75}, + {"label":"K21", "x":3.25, "y":2}, + {"label":"K22", "x":4.25, "y":2}, + {"label":"K23", "x":5.25, "y":2}, + {"label":"K24", "x":6.25, "y":2}, + {"label":"K25", "x":7.25, "y":2}, + {"label":"K26", "x":10.25, "y":2}, + {"label":"K27", "x":11.25, "y":2}, + {"label":"K28", "x":12.25, "y":2}, + {"label":"K29", "x":13.25, "y":2}, + {"label":"K2A", "x":14.25, "y":2}, + {"label":"K2B", "x":15.25, "y":2}, + {"label":"K2D", "x":16.25, "y":2, "w":2.25}, + + {"label":"K30", "x":1.5, "y":3, "w":2.25}, + {"label":"K32", "x":3.75, "y":3}, + {"label":"K33", "x":4.75, "y":3}, + {"label":"K34", "x":5.75, "y":3}, + {"label":"K35", "x":6.75, "y":3}, + {"label":"K36", "x":7.75, "y":3}, + {"label":"K37", "x":9.75, "y":3}, + {"label":"K38", "x":10.75, "y":3}, + {"label":"K39", "x":11.75, "y":3}, + {"label":"K3A", "x":12.75, "y":3}, + {"label":"K3B", "x":13.75, "y":3}, + {"label":"K3D", "x":14.75, "y":3}, + {"label":"K3C", "x":15.75, "y":3, "w":2.75}, + + {"label":"K40", "x":1.5, "y":4, "w":1.5}, + {"label":"K42", "x":4.5, "y":4, "w":1.25}, + {"label":"K44", "x":5.75, "y":4, "w":2.25}, + {"label":"K46", "x":8, "y":4, "w":1.25}, + {"label":"K48", "x":9.75, "y":4, "w":2.75}, + {"label":"K4A", "x":12.5, "y":4, "w":1.25}, + {"label":"K4E", "x":17, "y":4, "w":1.5} + ] + }, + "LAYOUT_alice_full_rshift": { + "layout": [ + {"label":"K1E", "x":0, "y":0}, + {"label":"K00", "x":1.5, "y":0}, + {"label":"K01", "x":2.5, "y":0}, + {"label":"K02", "x":3.5, "y":0}, + {"label":"K03", "x":4.5, "y":0}, + {"label":"K04", "x":5.5, "y":0}, + {"label":"K05", "x":6.5, "y":0}, + {"label":"K06", "x":7.5, "y":0}, + {"label":"K07", "x":10.5, "y":0}, + {"label":"K08", "x":11.5, "y":0}, + {"label":"K09", "x":12.5, "y":0}, + {"label":"K0A", "x":13.5, "y":0}, + {"label":"K0B", "x":14.5, "y":0}, + {"label":"K0C", "x":15.5, "y":0}, + {"label":"K0D", "x":16.5, "y":0, "w":2}, + + {"label":"K2E", "x":0, "y":1}, + {"label":"K10", "x":1.5, "y":1, "w":1.5}, + {"label":"K11", "x":3, "y":1}, + {"label":"K12", "x":4, "y":1}, + {"label":"K13", "x":5, "y":1}, + {"label":"K14", "x":6, "y":1}, + {"label":"K15", "x":7, "y":1}, + {"label":"K16", "x":10, "y":1}, + {"label":"K17", "x":11, "y":1}, + {"label":"K18", "x":12, "y":1}, + {"label":"K19", "x":13, "y":1}, + {"label":"K1A", "x":14, "y":1}, + {"label":"K1B", "x":15, "y":1}, + {"label":"K1C", "x":16, "y":1}, + {"label":"K1D", "x":17, "y":1, "w":1.5}, + + {"label":"K3E", "x":0, "y":2}, + {"label":"K20", "x":1.5, "y":2, "w":1.75}, + {"label":"K21", "x":3.25, "y":2}, + {"label":"K22", "x":4.25, "y":2}, + {"label":"K23", "x":5.25, "y":2}, + {"label":"K24", "x":6.25, "y":2}, + {"label":"K25", "x":7.25, "y":2}, + {"label":"K26", "x":10.25, "y":2}, + {"label":"K27", "x":11.25, "y":2}, + {"label":"K28", "x":12.25, "y":2}, + {"label":"K29", "x":13.25, "y":2}, + {"label":"K2A", "x":14.25, "y":2}, + {"label":"K2B", "x":15.25, "y":2}, + {"label":"K2D", "x":16.25, "y":2, "w":2.25}, + + {"label":"K30", "x":1.5, "y":3, "w":2.25}, + {"label":"K32", "x":3.75, "y":3}, + {"label":"K33", "x":4.75, "y":3}, + {"label":"K34", "x":5.75, "y":3}, + {"label":"K35", "x":6.75, "y":3}, + {"label":"K36", "x":7.75, "y":3}, + {"label":"K37", "x":9.75, "y":3}, + {"label":"K38", "x":10.75, "y":3}, + {"label":"K39", "x":11.75, "y":3}, + {"label":"K3A", "x":12.75, "y":3}, + {"label":"K3B", "x":13.75, "y":3}, + {"label":"K3D", "x":14.75, "y":3}, + {"label":"K3C", "x":15.75, "y":3, "w":2.75}, + {"label":"K40", "x":1.5, "y":4, "w":1.5}, {"label":"K42", "x":4.5, "y":4, "w":1.25}, {"label":"K44", "x":5.75, "y":4, "w":2.25}, @@ -143,5 +299,4 @@ ] } } - ,"meta": "https://noroadsleft.github.io/kbf_qmk_converter/" } diff --git a/keyboards/owlab/suit80/ansi/ansi.c b/keyboards/owlab/suit80/ansi/ansi.c new file mode 100644 index 000000000000..7e75773f1dcb --- /dev/null +++ b/keyboards/owlab/suit80/ansi/ansi.c @@ -0,0 +1,17 @@ +/* +Copyright 2021 owlab + +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 . +*/ +#include "ansi.h" diff --git a/keyboards/owlab/suit80/ansi/ansi.h b/keyboards/owlab/suit80/ansi/ansi.h new file mode 100644 index 000000000000..d01296f2c1d4 --- /dev/null +++ b/keyboards/owlab/suit80/ansi/ansi.h @@ -0,0 +1,36 @@ +/* +Copyright 2021 owlab + +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 . +*/ + +#pragma once + +#include "quantum.h" + +#define LAYOUT_ansi( \ + K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014, K114, K214, \ + K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, K313, K314, K412, \ + K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212, K213, K413, K414, K510, \ + K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, K312, \ + K400, K401, K402, K403, K404, K405, K406, K407, K408, K409, K410, K411, K511, \ + K500, K501, K502, K504, K507, K508, K509, K512, K513, K514 \ +) { \ + { K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014 }, \ + { K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, K114 }, \ + { K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212, K213, K214 }, \ + { K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, K312, K313, K314 }, \ + { K400, K401, K402, K403, K404, K405, K406, K407, K408, K409, K410, K411, K412, K413, K414 }, \ + { K500, K501, K502, KC_NO, K504, KC_NO, KC_NO, K507, K508, K509, K510, K511, K512, K513, K514 } \ +} diff --git a/keyboards/owlab/suit80/ansi/config.h b/keyboards/owlab/suit80/ansi/config.h new file mode 100644 index 000000000000..02c44da2126e --- /dev/null +++ b/keyboards/owlab/suit80/ansi/config.h @@ -0,0 +1,46 @@ +/* +Copyright 2021 owlab + +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 . +*/ + +#pragma once + +#include "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x4F53 //0x4F53 OS for owl studio +#define PRODUCT_ID 0x5355 //0x5355 SU for SUIT +#define DEVICE_VER 0x0001 +#define MANUFACTURER OwLab +#define PRODUCT SUIT80 + +/* key matrix size */ +#define MATRIX_ROWS 6 +#define MATRIX_COLS 15 + +/* Keyboard Matrix Assignments */ +#define MATRIX_ROW_PINS { E6, B0, B7, D0, D1, D2 } +#define MATRIX_COL_PINS { D5, D4, D6, D7, B4, B5, B6, C6, C7, F4, F7, F6, F5, F1, F0 } + +/* COL2ROW, ROW2COL */ +#define DIODE_DIRECTION COL2ROW + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + +/* NKRO */ +#ifdef NKRO_ENABLE +# define FORCE_NKRO +#endif \ No newline at end of file diff --git a/keyboards/owlab/suit80/ansi/info.json b/keyboards/owlab/suit80/ansi/info.json new file mode 100644 index 000000000000..b5833c6a600a --- /dev/null +++ b/keyboards/owlab/suit80/ansi/info.json @@ -0,0 +1,98 @@ +{ + "keyboard_name": "suit80", + "url": "", + "maintainer": "Owlab", + "layouts": { + "LAYOUT_ansi": { + "layout": [ + {"x":0, "y":0}, + {"x":1.25, "y":0}, + {"x":2.25, "y":0}, + {"x":3.25, "y":0}, + {"x":4.25, "y":0}, + {"x":5.5, "y":0}, + {"x":6.5, "y":0}, + {"x":7.5, "y":0}, + {"x":8.5, "y":0}, + {"x":9.75, "y":0}, + {"x":10.75, "y":0}, + {"x":11.75, "y":0}, + {"x":12.75, "y":0}, + {"x":14, "y":0}, + {"x":15.25, "y":0}, + {"x":16.25, "y":0}, + {"x":17.25, "y":0}, + {"x":0, "y":1.25}, + {"x":1, "y":1.25}, + {"x":2, "y":1.25}, + {"x":3, "y":1.25}, + {"x":4, "y":1.25}, + {"x":5, "y":1.25}, + {"x":6, "y":1.25}, + {"x":7, "y":1.25}, + {"x":8, "y":1.25}, + {"x":9, "y":1.25}, + {"x":10, "y":1.25}, + {"x":11, "y":1.25}, + {"x":12, "y":1.25}, + {"x":13, "y":1.25, "w":2}, + {"x":15.25, "y":1.25}, + {"x":16.25, "y":1.25}, + {"x":17.25, "y":1.25}, + {"x":0, "y":2.25, "w":1.5}, + {"x":1.5, "y":2.25}, + {"x":2.5, "y":2.25}, + {"x":3.5, "y":2.25}, + {"x":4.5, "y":2.25}, + {"x":5.5, "y":2.25}, + {"x":6.5, "y":2.25}, + {"x":7.5, "y":2.25}, + {"x":8.5, "y":2.25}, + {"x":9.5, "y":2.25}, + {"x":10.5, "y":2.25}, + {"x":11.5, "y":2.25}, + {"x":12.5, "y":2.25}, + {"x":13.5, "y":2.25, "w":1.5}, + {"x":15.25, "y":2.25}, + {"x":16.25, "y":2.25}, + {"x":17.25, "y":2.25}, + {"x":0, "y":3.25, "w":1.75}, + {"x":1.75, "y":3.25}, + {"x":2.75, "y":3.25}, + {"x":3.75, "y":3.25}, + {"x":4.75, "y":3.25}, + {"x":5.75, "y":3.25}, + {"x":6.75, "y":3.25}, + {"x":7.75, "y":3.25}, + {"x":8.75, "y":3.25}, + {"x":9.75, "y":3.25}, + {"x":10.75, "y":3.25}, + {"x":11.75, "y":3.25}, + {"x":12.75, "y":3.25, "w":2.25}, + {"x":0, "y":4.25, "w":2.25}, + {"x":2.25, "y":4.25}, + {"x":3.25, "y":4.25}, + {"x":4.25, "y":4.25}, + {"x":5.25, "y":4.25}, + {"x":6.25, "y":4.25}, + {"x":7.25, "y":4.25}, + {"x":8.25, "y":4.25}, + {"x":9.25, "y":4.25}, + {"x":10.25, "y":4.25}, + {"x":11.25, "y":4.25}, + {"x":12.25, "y":4.25, "w":2.75}, + {"x":16.25, "y":4.25}, + {"x":0, "y":5.25, "w":1.5}, + {"x":1.5, "y":5.25}, + {"x":2.5, "y":5.25, "w":1.5}, + {"x":4, "y":5.25, "w":7}, + {"x":11, "y":5.25, "w":1.5}, + {"x":12.5, "y":5.25}, + {"x":13.5, "y":5.25, "w":1.5}, + {"x":15.25, "y":5.25}, + {"x":16.25, "y":5.25}, + {"x":17.25, "y":5.25} + ] + } + } +} \ No newline at end of file diff --git a/keyboards/owlab/suit80/ansi/keymaps/default/keymap.c b/keyboards/owlab/suit80/ansi/keymaps/default/keymap.c new file mode 100644 index 000000000000..e9ab5f323f47 --- /dev/null +++ b/keyboards/owlab/suit80/ansi/keymaps/default/keymap.c @@ -0,0 +1,41 @@ +/* +Copyright 2021 owlab + +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 . +*/ +#include QMK_KEYBOARD_H + + + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + + + [0] = LAYOUT_ansi( + KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_F13, KC_PSCR, KC_SLCK, KC_PAUS, + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, + KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, MO(1), KC_LEFT, KC_DOWN, KC_RIGHT + ), + [1] = LAYOUT_ansi( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RESET, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ) +}; diff --git a/keyboards/owlab/suit80/ansi/keymaps/via/keymap.c b/keyboards/owlab/suit80/ansi/keymaps/via/keymap.c new file mode 100644 index 000000000000..d438aea40965 --- /dev/null +++ b/keyboards/owlab/suit80/ansi/keymaps/via/keymap.c @@ -0,0 +1,57 @@ +/* +Copyright 2021 owlab + +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 . +*/ + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + + [0] = LAYOUT_ansi( + KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_F13, KC_PSCR, KC_SLCK, KC_PAUS, + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, + KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, MO(1), KC_LEFT, KC_DOWN, KC_RIGHT + ), + [1] = LAYOUT_ansi( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RESET, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + + [2] = LAYOUT_ansi( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + + [3] = LAYOUT_ansi( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ) +}; \ No newline at end of file diff --git a/keyboards/owlab/suit80/ansi/keymaps/via/rules.mk b/keyboards/owlab/suit80/ansi/keymaps/via/rules.mk new file mode 100644 index 000000000000..36b7ba9cbc98 --- /dev/null +++ b/keyboards/owlab/suit80/ansi/keymaps/via/rules.mk @@ -0,0 +1,2 @@ +VIA_ENABLE = yes +LTO_ENABLE = yes diff --git a/keyboards/owlab/suit80/ansi/readme.md b/keyboards/owlab/suit80/ansi/readme.md new file mode 100644 index 000000000000..7d10fe1a57d0 --- /dev/null +++ b/keyboards/owlab/suit80/ansi/readme.md @@ -0,0 +1,21 @@ +# Suit80 - ANSI PCB + +![suit80](https://i.imgur.com/0QN23oc.png) + +A 80% made by Owlab. + +* Keyboard Maintainer: [owlab](https://github.com/owlab-git) +* Hardware Supported: Suit80 ANSI PCB +* Hardware Availability: Ended groupbuy: https://www.zfrontier.com/app/flow/2Q1YEKykXmYZ + +Make example for this keyboard (after setting up your build environment): + + make owlab/suit80/ansi:default + +Flashing example for this keyboard: + + make owlab/suit80/ansi:default:flash + +**Bootloader:** Press the physical reset button on the bottom side of the PCB (labeled SW1) or hold down ESC while plugging in the board. + +See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs). diff --git a/keyboards/owlab/suit80/ansi/rules.mk b/keyboards/owlab/suit80/ansi/rules.mk new file mode 100644 index 000000000000..001898bf4c73 --- /dev/null +++ b/keyboards/owlab/suit80/ansi/rules.mk @@ -0,0 +1,21 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = atmel-dfu + +# 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 +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = yes # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +AUDIO_ENABLE = no # Audio output \ No newline at end of file diff --git a/keyboards/owlab/suit80/iso/config.h b/keyboards/owlab/suit80/iso/config.h new file mode 100644 index 000000000000..22968bac1585 --- /dev/null +++ b/keyboards/owlab/suit80/iso/config.h @@ -0,0 +1,46 @@ +/* +Copyright 2021 owlab + +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 . +*/ + +#pragma once + +#include "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x4F53 // 0x4F53 OS for owl studio +#define PRODUCT_ID 0x5349 //0x5355 SI for SUIT ISO +#define DEVICE_VER 0x0001 +#define MANUFACTURER OwLab +#define PRODUCT SUIT80 ISO + +/* key matrix size */ +#define MATRIX_ROWS 6 +#define MATRIX_COLS 15 + +/* key matrix pins */ +#define MATRIX_ROW_PINS { E6, B0, B7, D0, D1, D2 } +#define MATRIX_COL_PINS { D5, D4, D6, D7, B4, B5, B6, C6, C7, F4, F7, F6, F5, F1, F0 } + +/* COL2ROW, ROW2COL */ +#define DIODE_DIRECTION COL2ROW + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + +/* NKRO */ +#ifdef NKRO_ENABLE +# define FORCE_NKRO +#endif diff --git a/keyboards/owlab/suit80/iso/info.json b/keyboards/owlab/suit80/iso/info.json new file mode 100644 index 000000000000..7c911fe361ac --- /dev/null +++ b/keyboards/owlab/suit80/iso/info.json @@ -0,0 +1,192 @@ +{ + "keyboard_name": "suit80", + "url": "", + "maintainer": "Owlab", + "layouts": { + "LAYOUT_all": { + "layout": [ + {"x":0, "y":0}, + {"x":1.25, "y":0}, + {"x":2.25, "y":0}, + {"x":3.25, "y":0}, + {"x":4.25, "y":0}, + {"x":5.5, "y":0}, + {"x":6.5, "y":0}, + {"x":7.5, "y":0}, + {"x":8.5, "y":0}, + {"x":9.75, "y":0}, + {"x":10.75, "y":0}, + {"x":11.75, "y":0}, + {"x":12.75, "y":0}, + {"x":14, "y":0}, + {"x":15.25, "y":0}, + {"x":16.25, "y":0}, + {"x":17.25, "y":0}, + {"x":0, "y":1.25}, + {"x":1, "y":1.25}, + {"x":2, "y":1.25}, + {"x":3, "y":1.25}, + {"x":4, "y":1.25}, + {"x":5, "y":1.25}, + {"x":6, "y":1.25}, + {"x":7, "y":1.25}, + {"x":8, "y":1.25}, + {"x":9, "y":1.25}, + {"x":10, "y":1.25}, + {"x":11, "y":1.25}, + {"x":12, "y":1.25}, + {"x":13, "y":1.25}, + {"x":14, "y":1.25}, + {"x":15.25, "y":1.25}, + {"x":16.25, "y":1.25}, + {"x":17.25, "y":1.25}, + {"x":0, "y":2.25, "w":1.5}, + {"x":1.5, "y":2.25}, + {"x":2.5, "y":2.25}, + {"x":3.5, "y":2.25}, + {"x":4.5, "y":2.25}, + {"x":5.5, "y":2.25}, + {"x":6.5, "y":2.25}, + {"x":7.5, "y":2.25}, + {"x":8.5, "y":2.25}, + {"x":9.5, "y":2.25}, + {"x":10.5, "y":2.25}, + {"x":11.5, "y":2.25}, + {"x":12.5, "y":2.25}, + {"x":15.25, "y":2.25}, + {"x":16.25, "y":2.25}, + {"x":17.25, "y":2.25}, + {"x":0, "y":3.25, "w":1.75}, + {"x":1.75, "y":3.25}, + {"x":2.75, "y":3.25}, + {"x":3.75, "y":3.25}, + {"x":4.75, "y":3.25}, + {"x":5.75, "y":3.25}, + {"x":6.75, "y":3.25}, + {"x":7.75, "y":3.25}, + {"x":8.75, "y":3.25}, + {"x":9.75, "y":3.25}, + {"x":10.75, "y":3.25}, + {"x":11.75, "y":3.25}, + {"x":12.75, "y":3.25}, + {"x":13.75, "y":2.25, "w":1.25, "h":2}, + {"x":0, "y":4.25, "w":1.25}, + {"x":1.25, "y":4.25}, + {"x":2.25, "y":4.25}, + {"x":3.25, "y":4.25}, + {"x":4.25, "y":4.25}, + {"x":5.25, "y":4.25}, + {"x":6.25, "y":4.25}, + {"x":7.25, "y":4.25}, + {"x":8.25, "y":4.25}, + {"x":9.25, "y":4.25}, + {"x":10.25, "y":4.25}, + {"x":11.25, "y":4.25}, + {"x":12.25, "y":4.25, "w":2.75}, + {"x":16.25, "y":4.25}, + {"x":0, "y":5.25, "w":1.5}, + {"x":1.5, "y":5.25}, + {"x":2.5, "y":5.25, "w":1.5}, + {"x":4, "y":5.25, "w":7}, + {"x":11, "y":5.25, "w":1.5}, + {"x":12.5, "y":5.25}, + {"x":13.5, "y":5.25, "w":1.5}, + {"x":15.25, "y":5.25}, + {"x":16.25, "y":5.25}, + {"x":17.25, "y":5.25} + ] + }, + "LAYOUT_iso": { + "layout": [ + {"x":0, "y":0}, + {"x":1.25, "y":0}, + {"x":2.25, "y":0}, + {"x":3.25, "y":0}, + {"x":4.25, "y":0}, + {"x":5.5, "y":0}, + {"x":6.5, "y":0}, + {"x":7.5, "y":0}, + {"x":8.5, "y":0}, + {"x":9.75, "y":0}, + {"x":10.75, "y":0}, + {"x":11.75, "y":0}, + {"x":12.75, "y":0}, + {"x":14, "y":0}, + {"x":15.25, "y":0}, + {"x":16.25, "y":0}, + {"x":17.25, "y":0}, + {"x":0, "y":1.25}, + {"x":1, "y":1.25}, + {"x":2, "y":1.25}, + {"x":3, "y":1.25}, + {"x":4, "y":1.25}, + {"x":5, "y":1.25}, + {"x":6, "y":1.25}, + {"x":7, "y":1.25}, + {"x":8, "y":1.25}, + {"x":9, "y":1.25}, + {"x":10, "y":1.25}, + {"x":11, "y":1.25}, + {"x":12, "y":1.25}, + {"x":13, "y":1.25, "w":2}, + {"x":15.25, "y":1.25}, + {"x":16.25, "y":1.25}, + {"x":17.25, "y":1.25}, + {"x":0, "y":2.25, "w":1.5}, + {"x":1.5, "y":2.25}, + {"x":2.5, "y":2.25}, + {"x":3.5, "y":2.25}, + {"x":4.5, "y":2.25}, + {"x":5.5, "y":2.25}, + {"x":6.5, "y":2.25}, + {"x":7.5, "y":2.25}, + {"x":8.5, "y":2.25}, + {"x":9.5, "y":2.25}, + {"x":10.5, "y":2.25}, + {"x":11.5, "y":2.25}, + {"x":12.5, "y":2.25}, + {"x":15.25, "y":2.25}, + {"x":16.25, "y":2.25}, + {"x":17.25, "y":2.25}, + {"x":0, "y":3.25, "w":1.75}, + {"x":1.75, "y":3.25}, + {"x":2.75, "y":3.25}, + {"x":3.75, "y":3.25}, + {"x":4.75, "y":3.25}, + {"x":5.75, "y":3.25}, + {"x":6.75, "y":3.25}, + {"x":7.75, "y":3.25}, + {"x":8.75, "y":3.25}, + {"x":9.75, "y":3.25}, + {"x":10.75, "y":3.25}, + {"x":11.75, "y":3.25}, + {"x":12.75, "y":3.25}, + {"x":13.75, "y":2.25, "w":1.25, "h":2}, + {"x":0, "y":4.25, "w":1.25}, + {"x":1.25, "y":4.25}, + {"x":2.25, "y":4.25}, + {"x":3.25, "y":4.25}, + {"x":4.25, "y":4.25}, + {"x":5.25, "y":4.25}, + {"x":6.25, "y":4.25}, + {"x":7.25, "y":4.25}, + {"x":8.25, "y":4.25}, + {"x":9.25, "y":4.25}, + {"x":10.25, "y":4.25}, + {"x":11.25, "y":4.25}, + {"x":12.25, "y":4.25, "w":2.75}, + {"x":16.25, "y":4.25}, + {"x":0, "y":5.25, "w":1.5}, + {"x":1.5, "y":5.25}, + {"x":2.5, "y":5.25, "w":1.5}, + {"x":4, "y":5.25, "w":7}, + {"x":11, "y":5.25, "w":1.5}, + {"x":12.5, "y":5.25}, + {"x":13.5, "y":5.25, "w":1.5}, + {"x":15.25, "y":5.25}, + {"x":16.25, "y":5.25}, + {"x":17.25, "y":5.25} + ] + } + } +} \ No newline at end of file diff --git a/keyboards/owlab/suit80/iso/iso.c b/keyboards/owlab/suit80/iso/iso.c new file mode 100644 index 000000000000..e8f326d37ec5 --- /dev/null +++ b/keyboards/owlab/suit80/iso/iso.c @@ -0,0 +1,19 @@ + + +/* +Copyright 2021 owlab + +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 . +*/ +#include "iso.h" diff --git a/keyboards/owlab/suit80/iso/iso.h b/keyboards/owlab/suit80/iso/iso.h new file mode 100644 index 000000000000..77cc55b452ce --- /dev/null +++ b/keyboards/owlab/suit80/iso/iso.h @@ -0,0 +1,52 @@ +/* +Copyright 2021 owlab + +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 . +*/ + +#pragma once + +#include "quantum.h" + +#define LAYOUT_all( \ + K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014, K114, K214, \ + K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K213, K113, K313, K314, K412, \ + K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212, K413, K414, K510, \ + K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, K506, K312, \ + K400, K503, K401, K402, K403, K404, K405, K406, K407, K408, K409, K410, K411, K511, \ + K500, K501, K502, K504, K507, K508, K509, K512, K513, K514 \ +) { \ + { K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014 }, \ + { K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, K114 }, \ + { K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212, K213, K214 }, \ + { K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, K312, K313, K314 }, \ + { K400, K401, K402, K403, K404, K405, K406, K407, K408, K409, K410, K411, K412, K413, K414 }, \ + { K500, K501, K502, K503, K504, KC_NO, K506, K507, K508, K509, K510, K511, K512, K513, K514 } \ +} + +#define LAYOUT_iso( \ + K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014, K114, K214, \ + K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, K313, K314, K412, \ + K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212, K413, K414, K510, \ + K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, K506, K312, \ + K400, K503, K401, K402, K403, K404, K405, K406, K407, K408, K409, K410, K411, K511, \ + K500, K501, K502, K504, K507, K508, K509, K512, K513, K514 \ +) { \ + { K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014 }, \ + { K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, K114 }, \ + { K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212, KC_NO, K214 }, \ + { K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, K312, K313, K314 }, \ + { K400, K401, K402, K403, K404, K405, K406, K407, K408, K409, K410, K411, K412, K413, K414 }, \ + { K500, K501, K502, K503, K504, KC_NO, K506, K507, K508, K509, K510, K511, K512, K513, K514 } \ +} \ No newline at end of file diff --git a/keyboards/owlab/suit80/iso/keymaps/default/keymap.c b/keyboards/owlab/suit80/iso/keymaps/default/keymap.c new file mode 100644 index 000000000000..84cfcc4ad27b --- /dev/null +++ b/keyboards/owlab/suit80/iso/keymaps/default/keymap.c @@ -0,0 +1,41 @@ +/* +Copyright 2021 owlab + +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 . +*/ +#include QMK_KEYBOARD_H + + + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT_iso( + KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_F13, KC_PSCR, KC_SLCK, KC_PAUS, + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_DEL, KC_END, KC_PGDN, + KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENT, + KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, MO(1), KC_LEFT, KC_DOWN, KC_RIGHT + ), + [1] = LAYOUT_iso( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RESET, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ) +}; + + diff --git a/keyboards/owlab/suit80/iso/keymaps/via/keymap.c b/keyboards/owlab/suit80/iso/keymaps/via/keymap.c new file mode 100644 index 000000000000..d392b797e833 --- /dev/null +++ b/keyboards/owlab/suit80/iso/keymaps/via/keymap.c @@ -0,0 +1,56 @@ +/* +Copyright 2021 owlab + +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 . +*/ + +#include QMK_KEYBOARD_H + + + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + + [0] = LAYOUT_all( + KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_F13, KC_PSCR, KC_SLCK, KC_PAUS, + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSLS, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_DEL, KC_END, KC_PGDN, + KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENT, + KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, MO(1), KC_LEFT, KC_DOWN, KC_RIGHT + ), + [1] = LAYOUT_all( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RESET, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [1] = LAYOUT_all( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ), + [1] = LAYOUT_all( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS + ) +}; diff --git a/keyboards/owlab/suit80/iso/keymaps/via/rules.mk b/keyboards/owlab/suit80/iso/keymaps/via/rules.mk new file mode 100644 index 000000000000..36b7ba9cbc98 --- /dev/null +++ b/keyboards/owlab/suit80/iso/keymaps/via/rules.mk @@ -0,0 +1,2 @@ +VIA_ENABLE = yes +LTO_ENABLE = yes diff --git a/keyboards/owlab/suit80/iso/readme.md b/keyboards/owlab/suit80/iso/readme.md new file mode 100644 index 000000000000..c16dfa255df3 --- /dev/null +++ b/keyboards/owlab/suit80/iso/readme.md @@ -0,0 +1,21 @@ +# Suit80 - ISO PCB + +![suit80](https://i.imgur.com/wTUPZFB.jpg) + +A 80% made by Owlab. + +* Keyboard Maintainer: [owlab](https://github.com/owlab-git) +* Hardware Supported: Suit80 ISO PCB +* Hardware Availability: Ended groupbuy: https://www.zfrontier.com/app/flow/2Q1YEKykXmYZ + +Make example for this keyboard (after setting up your build environment): + + make owlab/suit80/iso:default + +Flashing example for this keyboard: + + make owlab/suit80/iso:default:flash + +**Bootloader:** Press the physical reset button on the bottom side of the PCB (labeled SW1) or hold down ESC while plugging in the board. + +See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs). diff --git a/keyboards/owlab/suit80/iso/rules.mk b/keyboards/owlab/suit80/iso/rules.mk new file mode 100644 index 000000000000..001898bf4c73 --- /dev/null +++ b/keyboards/owlab/suit80/iso/rules.mk @@ -0,0 +1,21 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = atmel-dfu + +# 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 +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = yes # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +AUDIO_ENABLE = no # Audio output \ No newline at end of file diff --git a/keyboards/preonic/keymaps/arkag/keymap.c b/keyboards/preonic/keymaps/arkag/keymap.c index 42b875d6776b..5e50c584afcf 100644 --- a/keyboards/preonic/keymaps/arkag/keymap.c +++ b/keyboards/preonic/keymaps/arkag/keymap.c @@ -20,11 +20,11 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [_QWERTY] = LAYOUT_preonic_grid( - M_EHYPR, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, M_EHYPR, + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, XXXXXXX, KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT, - KC_LCTL, KC_LGUI, KC_LALT, MEDIA, SYMBOL, KC_SPC, M_LMHYP, ARROW, FUNCT, XXXXXXX, KC_RALT, KC_LEAD), + KC_LCTL, KC_LGUI, KC_LALT, MEDIA, SYMBOL, KC_SPC, KC_LEAD, ARROW, FUNCT, XXXXXXX, KC_RALT, KC_LEAD), [_SYMBOL] = LAYOUT_preonic_grid( _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, diff --git a/keyboards/pteron36/config.h b/keyboards/pteron36/config.h index dcc9d68c7867..d6f31514e60b 100644 --- a/keyboards/pteron36/config.h +++ b/keyboards/pteron36/config.h @@ -152,4 +152,16 @@ along with this program. If not, see . //#define BOOTMAGIC_LITE_ROW 0 //#define BOOTMAGIC_LITE_COLUMN 0 // for via -#define DYNAMIC_KEYMAP_LAYER_COUNT 7 \ No newline at end of file +#define DYNAMIC_KEYMAP_LAYER_COUNT 7 + +//left encoder +#define ENCODERS_PAD_A { F5 } +#define ENCODERS_PAD_B { F4 } + +//right encoder +#define ENCODERS_PAD_A_RIGHT { F4 } +#define ENCODERS_PAD_B_RIGHT { F5 } + +//RGB Underglow +#define RGB_DI_PIN B6 +#define RGBLED_NUM 10 \ No newline at end of file diff --git a/keyboards/pteron36/keymaps/default/keymap.c b/keyboards/pteron36/keymaps/default/keymap.c index 11d00bb31868..0cc0e2b4716a 100644 --- a/keyboards/pteron36/keymaps/default/keymap.c +++ b/keyboards/pteron36/keymaps/default/keymap.c @@ -32,4 +32,4 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_Z, KC_X, KC_C, KC_V, KC_B,KC_LBRACKET, KC_RBRACKET, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_LGUI, KC_BSPC, KC_SPC, KC_SPC, KC_ENT, KC_RALT - )}; \ No newline at end of file + )}; diff --git a/keyboards/pteron36/keymaps/via/keymap.c b/keyboards/pteron36/keymaps/via/keymap.c index 1c614596eb48..9e467dcde529 100644 --- a/keyboards/pteron36/keymaps/via/keymap.c +++ b/keyboards/pteron36/keymaps/via/keymap.c @@ -81,4 +81,61 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS ) -}; \ No newline at end of file +}; + +#ifdef OLED_DRIVER_ENABLE + +static void render_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, 0x00 + }; + + oled_write_P(qmk_logo, false); +} +static void render_status(void){ + oled_write_P(PSTR("Layer: "), false); + + switch (get_highest_layer(layer_state)) { + case _QWERTY: + oled_write_P(PSTR("Default\n"), false); + break; + case _SYMB: + oled_write_P(PSTR("Symbol\n"), false); + break; + case _NAV: + oled_write_P(PSTR("Nav\n"), false); + break; + case _ADJUST: + oled_write_P(PSTR("Adjust\n"), false); + break; + case _MOUSE: + oled_write_P(PSTR("Mouse\n"), false); + break; + case _NUMB: + oled_write_P(PSTR("Number\n"), false); + break; + case _FNR: + oled_write_P(PSTR("FunR\n"), false); + break; + default: + // Or use the write_ln shortcut over adding '\n' to the end of your string + oled_write_ln_P(PSTR("Undefined"), false); + } + + // Host Keyboard LED Status + led_t led_state = host_keyboard_led_state(); + oled_write_P(led_state.num_lock ? PSTR("NUM ") : PSTR(" "), false); + oled_write_P(led_state.caps_lock ? PSTR("CAP ") : PSTR(" "), false); + oled_write_P(led_state.scroll_lock ? PSTR("SCR ") : PSTR(" "), false); +} +void oled_task_user(void) { + if (is_keyboard_master()) { + render_status(); // Renders the current keyboard state (layer, lock, caps, scroll, etc) + } else { + render_logo(); // Renders a static logo + oled_scroll_left(); // Turns on scrolling + } +} +#endif diff --git a/keyboards/pteron36/keymaps/via/readme.md b/keyboards/pteron36/keymaps/via/readme.md index 32ab1253d7ae..5bde196156b3 100644 --- a/keyboards/pteron36/keymaps/via/readme.md +++ b/keyboards/pteron36/keymaps/via/readme.md @@ -1 +1 @@ -# Default keymap for Redox Wireless +# Default keymap for via \ No newline at end of file diff --git a/keyboards/pteron36/keymaps/via/rules.mk b/keyboards/pteron36/keymaps/via/rules.mk index 43061db1dd46..36b7ba9cbc98 100644 --- a/keyboards/pteron36/keymaps/via/rules.mk +++ b/keyboards/pteron36/keymaps/via/rules.mk @@ -1,2 +1,2 @@ VIA_ENABLE = yes -LTO_ENABLE = yes \ No newline at end of file +LTO_ENABLE = yes diff --git a/keyboards/pteron36/pteron36.c b/keyboards/pteron36/pteron36.c index 4f06d822de42..3288626f00f8 100644 --- a/keyboards/pteron36/pteron36.c +++ b/keyboards/pteron36/pteron36.c @@ -14,4 +14,53 @@ * along with this program. If not, see . */ -#include "pteron36.h" \ No newline at end of file +#include "pteron36.h" + +//common encoder setup + +bool encoder_update_kb(uint8_t index, bool clockwise) { + if (!encoder_update_user(index, clockwise)) { return false; } + if (index == 0) { /* First encoder */ + if (clockwise) { + tap_code(KC__VOLUP); + } else { + tap_code(KC__VOLDOWN); + } + } else if (index == 1) { /* Second encoder */ + if (clockwise) { + tap_code(KC_PGUP); + } else { + tap_code(KC_PGDN); + } + } + return true; +} +//common oled support. +#ifdef OLED_DRIVER_ENABLE +__attribute__((weak)) void oled_task_user(void) { + if (is_keyboard_master()) { + oled_write_P(PSTR("Layer: "), false); + switch (get_highest_layer(layer_state)) { + case _QWERTY: + oled_write_ln_P(PSTR("Default"), false); + break; + default: + // Or use the write_ln shortcut over adding '\n' to the end of your string + oled_write_ln_P(PSTR("Undefined"), false); + } + // Host Keyboard LED Status + led_t led_state = host_keyboard_led_state(); + oled_write_P(led_state.num_lock ? PSTR("NUM ") : PSTR(" "), false); + oled_write_P(led_state.caps_lock ? PSTR("CAP ") : PSTR(" "), false); + oled_write_P(led_state.scroll_lock ? PSTR("SCR ") : PSTR(" "), false); + } else { + 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, 0x00 + }; + oled_write_P(qmk_logo, false); + oled_scroll_left(); // Turns on scrolling + } +} +#endif diff --git a/keyboards/pteron36/readme.md b/keyboards/pteron36/readme.md index b9e919c7564f..a68c7a55b4fe 100644 --- a/keyboards/pteron36/readme.md +++ b/keyboards/pteron36/readme.md @@ -20,12 +20,15 @@ See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_to ## Default Keymap and Miryoku Layout support -The keyboard was designed with miryoku layout in mind. The default layout is very basic and does not have much use. I will be opening a pr to make the keyboard available with miryoku layout soon. Currently to build the keyboard with miryoku you will have to checkout latest miryoku qmk repo, and add the keyboard folder there manually. After copying the folder run the following command +The keyboard was designed with miryoku layout in mind. The default layout is very basic and does not have much use, modify the keymap as you see fit. Build keyboard with manna-harbour_miryoku as keymap, qmk should compile the firmare without any issue. + + make pteron36:manna-harbour_miryoku - make pteron36:manna-harbour_miryoku - Add miryoku params as required. +Pteron36 uses community layout, hence there is no need for separate keymap folder for any keymap that support 5x3_3 layout. + +## VIA support -## OLED and RotaryEncoder +The VIA keymap is working as intended. -I am working on adding OLED and RotaryEncoder support in keyboard config. + make pteron36:via diff --git a/keyboards/pteron36/rules.mk b/keyboards/pteron36/rules.mk index 64a21b2e9b74..278246b37134 100644 --- a/keyboards/pteron36/rules.mk +++ b/keyboards/pteron36/rules.mk @@ -17,10 +17,10 @@ SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work NKRO_ENABLE = no # USB Nkey Rollover BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality -RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow AUDIO_ENABLE = no # Audio output - -OLED_ENABLE = no # OLED display; work in progress to add support. will be update in future. -SPLIT_KEYBOARD = yes +OLED_DRIVER_ENABLE = yes # OLED display +ENCODER_ENABLE = yes # Encoder support +SPLIT_KEYBOARD = yes # Split enable LAYOUTS = split_3x5_3 diff --git a/keyboards/ramonimbao/squishytkl/info.json b/keyboards/ramonimbao/squishytkl/info.json index caf45d6319c4..aa19c73fa830 100644 --- a/keyboards/ramonimbao/squishytkl/info.json +++ b/keyboards/ramonimbao/squishytkl/info.json @@ -5,404 +5,434 @@ "layouts": { "LAYOUT_ansi": { "layout": [ - {"x":0, "y":0.5}, - {"x":1.25, "y":0.5}, - {"x":2.25, "y":0.5}, - {"x":3.25, "y":0.5}, - {"x":4.25, "y":0.5}, - {"x":5.5, "y":0.5}, - {"x":6.5, "y":0.5}, - {"x":7.5, "y":0.5}, - {"x":8.5, "y":0.5}, - {"x":9.75, "y":0.5}, - {"x":10.75, "y":0.5}, - {"x":11.75, "y":0.5}, - {"x":12.75, "y":0.5}, - {"x":14, "y":0.5}, - {"x":15.25, "y":0.5}, - {"x":16.25, "y":0.5}, - {"x":17.25, "y":0.5}, - - {"x":0, "y":1.75}, - {"x":1, "y":1.75}, - {"x":2, "y":1.75}, - {"x":3, "y":1.75}, - {"x":4, "y":1.75}, - {"x":5, "y":1.75}, - {"x":6, "y":1.75}, - {"x":7, "y":1.75}, - {"x":8, "y":1.75}, - {"x":9, "y":1.75}, - {"x":10, "y":1.75}, - {"x":11, "y":1.75}, - {"x":12, "y":1.75}, - {"x":13, "y":1.75, "w":2}, - {"x":15.25, "y":1.75}, - {"x":16.25, "y":1.75}, - {"x":17.25, "y":1.75}, - - {"x":0, "y":2.75, "w":1.5}, - {"x":1.5, "y":2.75}, - {"x":2.5, "y":2.75}, - {"x":3.5, "y":2.75}, - {"x":4.5, "y":2.75}, - {"x":5.5, "y":2.75}, - {"x":6.5, "y":2.75}, - {"x":7.5, "y":2.75}, - {"x":8.5, "y":2.75}, - {"x":9.5, "y":2.75}, - {"x":10.5, "y":2.75}, - {"x":11.5, "y":2.75}, - {"x":12.5, "y":2.75}, - {"x":13.5, "y":2.75, "w":1.5}, - {"x":15.25, "y":2.75}, - {"x":16.25, "y":2.75}, - {"x":17.25, "y":2.75}, - - {"x":0, "y":3.75, "w":1.75}, - {"x":1.75, "y":3.75}, - {"x":2.75, "y":3.75}, - {"x":3.75, "y":3.75}, - {"x":4.75, "y":3.75}, - {"x":5.75, "y":3.75}, - {"x":6.75, "y":3.75}, - {"x":7.75, "y":3.75}, - {"x":8.75, "y":3.75}, - {"x":9.75, "y":3.75}, - {"x":10.75, "y":3.75}, - {"x":11.75, "y":3.75}, - {"x":12.75, "y":3.75, "w":2.25}, - - {"x":0, "y":4.75, "w":2.25}, - {"x":2.25, "y":4.75}, - {"x":3.25, "y":4.75}, - {"x":4.25, "y":4.75}, - {"x":5.25, "y":4.75}, - {"x":6.25, "y":4.75}, - {"x":7.25, "y":4.75}, - {"x":8.25, "y":4.75}, - {"x":9.25, "y":4.75}, - {"x":10.25, "y":4.75}, - {"x":11.25, "y":4.75}, - {"x":12.25, "y":4.75, "w":2.75}, - {"x":16.25, "y":4.75}, - - {"x":0, "y":5.75, "w":1.25}, - {"x":1.25, "y":5.75, "w":1.25}, - {"x":2.5, "y":5.75, "w":1.25}, - {"x":3.75, "y":5.75, "w":6.25}, - {"x":10, "y":5.75, "w":1.25}, - {"x":11.25, "y":5.75, "w":1.25}, - {"x":12.5, "y":5.75, "w":1.25}, - {"x":13.75, "y":5.75, "w":1.25}, - {"x":15.25, "y":5.75}, - {"x":16.25, "y":5.75}, - {"x":17.25, "y":5.75} + {"x": 0, "y": 0}, + + {"x": 1.25, "y": 0}, + {"x": 2.25, "y": 0}, + {"x": 3.25, "y": 0}, + {"x": 4.25, "y": 0}, + + {"x": 5.5, "y": 0}, + {"x": 6.5, "y": 0}, + {"x": 7.5, "y": 0}, + {"x": 8.5, "y": 0}, + + {"x": 9.75, "y": 0}, + {"x": 10.75, "y": 0}, + {"x": 11.75, "y": 0}, + {"x": 12.75, "y": 0}, + + {"x": 14, "y": 0}, + + {"x": 15.25, "y": 0}, + {"x": 16.25, "y": 0}, + {"x": 17.25, "y": 0}, + + {"x": 0, "y": 1.25}, + {"x": 1, "y": 1.25}, + {"x": 2, "y": 1.25}, + {"x": 3, "y": 1.25}, + {"x": 4, "y": 1.25}, + {"x": 5, "y": 1.25}, + {"x": 6, "y": 1.25}, + {"x": 7, "y": 1.25}, + {"x": 8, "y": 1.25}, + {"x": 9, "y": 1.25}, + {"x": 10, "y": 1.25}, + {"x": 11, "y": 1.25}, + {"x": 12, "y": 1.25}, + {"x": 13, "y": 1.25, "w": 2}, + + {"x": 15.25, "y": 1.25}, + {"x": 16.25, "y": 1.25}, + {"x": 17.25, "y": 1.25}, + + {"x": 0, "y": 2.25, "w": 1.5}, + {"x": 1.5, "y": 2.25}, + {"x": 2.5, "y": 2.25}, + {"x": 3.5, "y": 2.25}, + {"x": 4.5, "y": 2.25}, + {"x": 5.5, "y": 2.25}, + {"x": 6.5, "y": 2.25}, + {"x": 7.5, "y": 2.25}, + {"x": 8.5, "y": 2.25}, + {"x": 9.5, "y": 2.25}, + {"x": 10.5, "y": 2.25}, + {"x": 11.5, "y": 2.25}, + {"x": 12.5, "y": 2.25}, + {"x": 13.5, "y": 2.25, "w": 1.5}, + + {"x": 15.25, "y": 2.25}, + {"x": 16.25, "y": 2.25}, + {"x": 17.25, "y": 2.25}, + + {"x": 0, "y": 3.25, "w": 1.75}, + {"x": 1.75, "y": 3.25}, + {"x": 2.75, "y": 3.25}, + {"x": 3.75, "y": 3.25}, + {"x": 4.75, "y": 3.25}, + {"x": 5.75, "y": 3.25}, + {"x": 6.75, "y": 3.25}, + {"x": 7.75, "y": 3.25}, + {"x": 8.75, "y": 3.25}, + {"x": 9.75, "y": 3.25}, + {"x": 10.75, "y": 3.25}, + {"x": 11.75, "y": 3.25}, + {"x": 12.75, "y": 3.25, "w": 2.25}, + + {"x": 0, "y": 4.25, "w": 2.25}, + {"x": 2.25, "y": 4.25}, + {"x": 3.25, "y": 4.25}, + {"x": 4.25, "y": 4.25}, + {"x": 5.25, "y": 4.25}, + {"x": 6.25, "y": 4.25}, + {"x": 7.25, "y": 4.25}, + {"x": 8.25, "y": 4.25}, + {"x": 9.25, "y": 4.25}, + {"x": 10.25, "y": 4.25}, + {"x": 11.25, "y": 4.25}, + {"x": 12.25, "y": 4.25, "w": 2.75}, + + {"x": 16.25, "y": 4.25}, + + {"x": 0, "y": 5.25, "w": 1.25}, + {"x": 1.25, "y": 5.25, "w": 1.25}, + {"x": 2.5, "y": 5.25, "w": 1.25}, + {"x": 3.75, "y": 5.25, "w": 6.25}, + {"x": 10, "y": 5.25, "w": 1.25}, + {"x": 11.25, "y": 5.25, "w": 1.25}, + {"x": 12.5, "y": 5.25, "w": 1.25}, + {"x": 13.75, "y": 5.25, "w": 1.25}, + + {"x": 15.25, "y": 5.25}, + {"x": 16.25, "y": 5.25}, + {"x": 17.25, "y": 5.25} ] }, "LAYOUT_iso": { "layout": [ - {"x":0, "y":0.5}, - {"x":1.25, "y":0.5}, - {"x":2.25, "y":0.5}, - {"x":3.25, "y":0.5}, - {"x":4.25, "y":0.5}, - {"x":5.5, "y":0.5}, - {"x":6.5, "y":0.5}, - {"x":7.5, "y":0.5}, - {"x":8.5, "y":0.5}, - {"x":9.75, "y":0.5}, - {"x":10.75, "y":0.5}, - {"x":11.75, "y":0.5}, - {"x":12.75, "y":0.5}, - {"x":14, "y":0.5}, - {"x":15.25, "y":0.5}, - {"x":16.25, "y":0.5}, - {"x":17.25, "y":0.5}, - - {"x":0, "y":1.75}, - {"x":1, "y":1.75}, - {"x":2, "y":1.75}, - {"x":3, "y":1.75}, - {"x":4, "y":1.75}, - {"x":5, "y":1.75}, - {"x":6, "y":1.75}, - {"x":7, "y":1.75}, - {"x":8, "y":1.75}, - {"x":9, "y":1.75}, - {"x":10, "y":1.75}, - {"x":11, "y":1.75}, - {"x":12, "y":1.75}, - {"x":13, "y":1.75, "w":2}, - {"x":15.25, "y":1.75}, - {"x":16.25, "y":1.75}, - {"x":17.25, "y":1.75}, - - {"x":0, "y":2.75, "w":1.5}, - {"x":1.5, "y":2.75}, - {"x":2.5, "y":2.75}, - {"x":3.5, "y":2.75}, - {"x":4.5, "y":2.75}, - {"x":5.5, "y":2.75}, - {"x":6.5, "y":2.75}, - {"x":7.5, "y":2.75}, - {"x":8.5, "y":2.75}, - {"x":9.5, "y":2.75}, - {"x":10.5, "y":2.75}, - {"x":11.5, "y":2.75}, - {"x":12.5, "y":2.75}, - {"x":15.25, "y":2.75}, - {"x":16.25, "y":2.75}, - {"x":17.25, "y":2.75}, - - {"x":0, "y":3.75, "w":1.75}, - {"x":1.75, "y":3.75}, - {"x":2.75, "y":3.75}, - {"x":3.75, "y":3.75}, - {"x":4.75, "y":3.75}, - {"x":5.75, "y":3.75}, - {"x":6.75, "y":3.75}, - {"x":7.75, "y":3.75}, - {"x":8.75, "y":3.75}, - {"x":9.75, "y":3.75}, - {"x":10.75, "y":3.75}, - {"x":11.75, "y":3.75}, - {"x":12.75, "y":3.75}, - {"x":13.75, "y":2.75, "w":1.25, "h":2}, - - {"x":0, "y":4.75, "w":1.25}, - {"x":1.25, "y":4.75}, - {"x":2.25, "y":4.75}, - {"x":3.25, "y":4.75}, - {"x":4.25, "y":4.75}, - {"x":5.25, "y":4.75}, - {"x":6.25, "y":4.75}, - {"x":7.25, "y":4.75}, - {"x":8.25, "y":4.75}, - {"x":9.25, "y":4.75}, - {"x":10.25, "y":4.75}, - {"x":11.25, "y":4.75}, - {"x":12.25, "y":4.75, "w":2.75}, - {"x":16.25, "y":4.75}, - - {"x":0, "y":5.75, "w":1.25}, - {"x":1.25, "y":5.75, "w":1.25}, - {"x":2.5, "y":5.75, "w":1.25}, - {"x":3.75, "y":5.75, "w":6.25}, - {"x":10, "y":5.75, "w":1.25}, - {"x":11.25, "y":5.75, "w":1.25}, - {"x":12.5, "y":5.75, "w":1.25}, - {"x":13.75, "y":5.75, "w":1.25}, - {"x":15.25, "y":5.75}, - {"x":16.25, "y":5.75}, - {"x":17.25, "y":5.75} + {"x": 0, "y": 0}, + + {"x": 1.25, "y": 0}, + {"x": 2.25, "y": 0}, + {"x": 3.25, "y": 0}, + {"x": 4.25, "y": 0}, + + {"x": 5.5, "y": 0}, + {"x": 6.5, "y": 0}, + {"x": 7.5, "y": 0}, + {"x": 8.5, "y": 0}, + + {"x": 9.75, "y": 0}, + {"x": 10.75, "y": 0}, + {"x": 11.75, "y": 0}, + {"x": 12.75, "y": 0}, + + {"x": 14, "y": 0}, + + {"x": 15.25, "y": 0}, + {"x": 16.25, "y": 0}, + {"x": 17.25, "y": 0}, + + {"x": 0, "y": 1.25}, + {"x": 1, "y": 1.25}, + {"x": 2, "y": 1.25}, + {"x": 3, "y": 1.25}, + {"x": 4, "y": 1.25}, + {"x": 5, "y": 1.25}, + {"x": 6, "y": 1.25}, + {"x": 7, "y": 1.25}, + {"x": 8, "y": 1.25}, + {"x": 9, "y": 1.25}, + {"x": 10, "y": 1.25}, + {"x": 11, "y": 1.25}, + {"x": 12, "y": 1.25}, + {"x": 13, "y": 1.25, "w": 2}, + + {"x": 15.25, "y": 1.25}, + {"x": 16.25, "y": 1.25}, + {"x": 17.25, "y": 1.25}, + + {"x": 0, "y": 2.25, "w": 1.5}, + {"x": 1.5, "y": 2.25}, + {"x": 2.5, "y": 2.25}, + {"x": 3.5, "y": 2.25}, + {"x": 4.5, "y": 2.25}, + {"x": 5.5, "y": 2.25}, + {"x": 6.5, "y": 2.25}, + {"x": 7.5, "y": 2.25}, + {"x": 8.5, "y": 2.25}, + {"x": 9.5, "y": 2.25}, + {"x": 10.5, "y": 2.25}, + {"x": 11.5, "y": 2.25}, + {"x": 12.5, "y": 2.25}, + + {"x": 15.25, "y": 2.25}, + {"x": 16.25, "y": 2.25}, + {"x": 17.25, "y": 2.25}, + + {"x": 0, "y": 3.25, "w": 1.75}, + {"x": 1.75, "y": 3.25}, + {"x": 2.75, "y": 3.25}, + {"x": 3.75, "y": 3.25}, + {"x": 4.75, "y": 3.25}, + {"x": 5.75, "y": 3.25}, + {"x": 6.75, "y": 3.25}, + {"x": 7.75, "y": 3.25}, + {"x": 8.75, "y": 3.25}, + {"x": 9.75, "y": 3.25}, + {"x": 10.75, "y": 3.25}, + {"x": 11.75, "y": 3.25}, + {"x": 12.75, "y": 3.25}, + {"x": 13.75, "y": 2.25, "w": 1.25, "h": 2}, + + {"x": 0, "y": 4.25, "w": 1.25}, + {"x": 1.25, "y": 4.25}, + {"x": 2.25, "y": 4.25}, + {"x": 3.25, "y": 4.25}, + {"x": 4.25, "y": 4.25}, + {"x": 5.25, "y": 4.25}, + {"x": 6.25, "y": 4.25}, + {"x": 7.25, "y": 4.25}, + {"x": 8.25, "y": 4.25}, + {"x": 9.25, "y": 4.25}, + {"x": 10.25, "y": 4.25}, + {"x": 11.25, "y": 4.25}, + {"x": 12.25, "y": 4.25, "w": 2.75}, + + {"x": 16.25, "y": 4.25}, + + {"x": 0, "y": 5.25, "w": 1.25}, + {"x": 1.25, "y": 5.25, "w": 1.25}, + {"x": 2.5, "y": 5.25, "w": 1.25}, + {"x": 3.75, "y": 5.25, "w": 6.25}, + {"x": 10, "y": 5.25, "w": 1.25}, + {"x": 11.25, "y": 5.25, "w": 1.25}, + {"x": 12.5, "y": 5.25, "w": 1.25}, + {"x": 13.75, "y": 5.25, "w": 1.25}, + + {"x": 15.25, "y": 5.25}, + {"x": 16.25, "y": 5.25}, + {"x": 17.25, "y": 5.25} ] }, "LAYOUT_jis": { "layout": [ - {"x":0, "y":0}, - {"x":1.25, "y":0}, - {"x":2.25, "y":0}, - {"x":3.25, "y":0}, - {"x":4.25, "y":0}, - {"x":5.5, "y":0}, - {"x":6.5, "y":0}, - {"x":7.5, "y":0}, - {"x":8.5, "y":0}, - {"x":9.75, "y":0}, - {"x":10.75, "y":0}, - {"x":11.75, "y":0}, - {"x":12.75, "y":0}, - {"x":14, "y":0}, - {"x":15.25, "y":0}, - {"x":16.25, "y":0}, - {"x":17.25, "y":0}, - - {"x":0, "y":1.25}, - {"x":1, "y":1.25}, - {"x":2, "y":1.25}, - {"x":3, "y":1.25}, - {"x":4, "y":1.25}, - {"x":5, "y":1.25}, - {"x":6, "y":1.25}, - {"x":7, "y":1.25}, - {"x":8, "y":1.25}, - {"x":9, "y":1.25}, - {"x":10, "y":1.25}, - {"x":11, "y":1.25}, - {"x":12, "y":1.25}, - {"x":13, "y":1.25}, - {"x":14, "y":1.25}, - {"x":15.25, "y":1.25}, - {"x":16.25, "y":1.25}, - {"x":17.25, "y":1.25}, - - {"x":0, "y":2.25, "w":1.5}, - {"x":1.5, "y":2.25}, - {"x":2.5, "y":2.25}, - {"x":3.5, "y":2.25}, - {"x":4.5, "y":2.25}, - {"x":5.5, "y":2.25}, - {"x":6.5, "y":2.25}, - {"x":7.5, "y":2.25}, - {"x":8.5, "y":2.25}, - {"x":9.5, "y":2.25}, - {"x":10.5, "y":2.25}, - {"x":11.5, "y":2.25}, - {"x":12.5, "y":2.25}, - {"x":15.25, "y":2.25}, - {"x":16.25, "y":2.25}, - {"x":17.25, "y":2.25}, - - {"x":0, "y":3.25, "w":1.75}, - {"x":1.75, "y":3.25}, - {"x":2.75, "y":3.25}, - {"x":3.75, "y":3.25}, - {"x":4.75, "y":3.25}, - {"x":5.75, "y":3.25}, - {"x":6.75, "y":3.25}, - {"x":7.75, "y":3.25}, - {"x":8.75, "y":3.25}, - {"x":9.75, "y":3.25}, - {"x":10.75, "y":3.25}, - {"x":11.75, "y":3.25}, - {"x":12.75, "y":3.25}, - {"x":13.75, "y":2.25, "w":1.25, "h":2}, - - {"x":0, "y":4.25, "w":2.25}, - {"x":2.25, "y":4.25}, - {"x":3.25, "y":4.25}, - {"x":4.25, "y":4.25}, - {"x":5.25, "y":4.25}, - {"x":6.25, "y":4.25}, - {"x":7.25, "y":4.25}, - {"x":8.25, "y":4.25}, - {"x":9.25, "y":4.25}, - {"x":10.25, "y":4.25}, - {"x":11.25, "y":4.25}, - {"x":12.25, "y":4.25}, - {"x":13.25, "y":4.25, "w":1.75}, - {"x":16.25, "y":4.25}, - - {"x":0, "y":5.25, "w":1.5}, - {"x":1.5, "y":5.25}, - {"x":2.5, "y":5.25, "w":1.5}, - {"x":4, "y":5.25}, - {"x":5, "y":5.25}, - {"x":6, "y":5.25, "w":3}, - {"x":9, "y":5.25}, - {"x":10, "y":5.25}, - {"x":11, "y":5.25, "w":1.5}, - {"x":12.5, "y":5.25}, - {"x":13.5, "y":5.25, "w":1.5}, - {"x":15.25, "y":5.25}, - {"x":16.25, "y":5.25}, - {"x":17.25, "y":5.25} + {"x": 0, "y": 0}, + {"x": 1.25, "y": 0}, + {"x": 2.25, "y": 0}, + {"x": 3.25, "y": 0}, + {"x": 4.25, "y": 0}, + {"x": 5.5, "y": 0}, + {"x": 6.5, "y": 0}, + {"x": 7.5, "y": 0}, + {"x": 8.5, "y": 0}, + {"x": 9.75, "y": 0}, + {"x": 10.75, "y": 0}, + {"x": 11.75, "y": 0}, + {"x": 12.75, "y": 0}, + {"x": 14, "y": 0}, + {"x": 15.25, "y": 0}, + {"x": 16.25, "y": 0}, + {"x": 17.25, "y": 0}, + + {"x": 0, "y": 1.25}, + {"x": 1, "y": 1.25}, + {"x": 2, "y": 1.25}, + {"x": 3, "y": 1.25}, + {"x": 4, "y": 1.25}, + {"x": 5, "y": 1.25}, + {"x": 6, "y": 1.25}, + {"x": 7, "y": 1.25}, + {"x": 8, "y": 1.25}, + {"x": 9, "y": 1.25}, + {"x": 10, "y": 1.25}, + {"x": 11, "y": 1.25}, + {"x": 12, "y": 1.25}, + {"x": 13, "y": 1.25}, + {"x": 14, "y": 1.25}, + {"x": 15.25, "y": 1.25}, + {"x": 16.25, "y": 1.25}, + {"x": 17.25, "y": 1.25}, + + {"x": 0, "y": 2.25, "w": 1.5}, + {"x": 1.5, "y": 2.25}, + {"x": 2.5, "y": 2.25}, + {"x": 3.5, "y": 2.25}, + {"x": 4.5, "y": 2.25}, + {"x": 5.5, "y": 2.25}, + {"x": 6.5, "y": 2.25}, + {"x": 7.5, "y": 2.25}, + {"x": 8.5, "y": 2.25}, + {"x": 9.5, "y": 2.25}, + {"x": 10.5, "y": 2.25}, + {"x": 11.5, "y": 2.25}, + {"x": 12.5, "y": 2.25}, + {"x": 15.25, "y": 2.25}, + {"x": 16.25, "y": 2.25}, + {"x": 17.25, "y": 2.25}, + + {"x": 0, "y": 3.25, "w": 1.75}, + {"x": 1.75, "y": 3.25}, + {"x": 2.75, "y": 3.25}, + {"x": 3.75, "y": 3.25}, + {"x": 4.75, "y": 3.25}, + {"x": 5.75, "y": 3.25}, + {"x": 6.75, "y": 3.25}, + {"x": 7.75, "y": 3.25}, + {"x": 8.75, "y": 3.25}, + {"x": 9.75, "y": 3.25}, + {"x": 10.75, "y": 3.25}, + {"x": 11.75, "y": 3.25}, + {"x": 12.75, "y": 3.25}, + {"x": 13.75, "y": 2.25, "w": 1.25, "h": 2}, + + {"x": 0, "y": 4.25, "w": 2.25}, + {"x": 2.25, "y": 4.25}, + {"x": 3.25, "y": 4.25}, + {"x": 4.25, "y": 4.25}, + {"x": 5.25, "y": 4.25}, + {"x": 6.25, "y": 4.25}, + {"x": 7.25, "y": 4.25}, + {"x": 8.25, "y": 4.25}, + {"x": 9.25, "y": 4.25}, + {"x": 10.25, "y": 4.25}, + {"x": 11.25, "y": 4.25}, + {"x": 12.25, "y": 4.25}, + {"x": 13.25, "y": 4.25, "w": 1.75}, + + {"x": 16.25, "y": 4.25}, + + {"x": 0, "y": 5.25, "w": 1.5}, + {"x": 1.5, "y": 5.25}, + {"x": 2.5, "y": 5.25, "w": 1.5}, + {"x": 4, "y": 5.25}, + {"x": 5, "y": 5.25}, + {"x": 6, "y": 5.25, "w": 3}, + {"x": 9, "y": 5.25}, + {"x": 10, "y": 5.25}, + {"x": 11, "y": 5.25, "w": 1.5}, + {"x": 12.5, "y": 5.25}, + {"x": 13.5, "y": 5.25, "w": 1.5}, + + {"x": 15.25, "y": 5.25}, + {"x": 16.25, "y": 5.25}, + {"x": 17.25, "y": 5.25} ] }, "LAYOUT_all": { "layout": [ - {"x":0, "y":0.5}, - {"x":1.25, "y":0.5}, - {"x":2.25, "y":0.5}, - {"x":3.25, "y":0.5}, - {"x":4.25, "y":0.5}, - {"x":5.5, "y":0.5}, - {"x":6.5, "y":0.5}, - {"x":7.5, "y":0.5}, - {"x":8.5, "y":0.5}, - {"x":9.75, "y":0.5}, - {"x":10.75, "y":0.5}, - {"x":11.75, "y":0.5}, - {"x":12.75, "y":0.5}, - {"x":14, "y":0.5}, - {"x":15.25, "y":0.5}, - {"x":16.25, "y":0.5}, - {"x":17.25, "y":0.5}, - - {"x":0, "y":1.75}, - {"x":1, "y":1.75}, - {"x":2, "y":1.75}, - {"x":3, "y":1.75}, - {"x":4, "y":1.75}, - {"x":5, "y":1.75}, - {"x":6, "y":1.75}, - {"x":7, "y":1.75}, - {"x":8, "y":1.75}, - {"x":9, "y":1.75}, - {"x":10, "y":1.75}, - {"x":11, "y":1.75}, - {"x":12, "y":1.75}, - {"x":13, "y":1.75}, - {"x":14, "y":1.75}, - {"x":15.25, "y":1.75}, - {"x":16.25, "y":1.75}, - {"x":17.25, "y":1.75}, - - {"x":0, "y":2.75, "w":1.5}, - {"x":1.5, "y":2.75}, - {"x":2.5, "y":2.75}, - {"x":3.5, "y":2.75}, - {"x":4.5, "y":2.75}, - {"x":5.5, "y":2.75}, - {"x":6.5, "y":2.75}, - {"x":7.5, "y":2.75}, - {"x":8.5, "y":2.75}, - {"x":9.5, "y":2.75}, - {"x":10.5, "y":2.75}, - {"x":11.5, "y":2.75}, - {"x":12.5, "y":2.75}, - {"x":13.5, "y":2.75, "w":1.5}, - {"x":15.25, "y":2.75}, - {"x":16.25, "y":2.75}, - {"x":17.25, "y":2.75}, - - {"x":0, "y":3.75, "w":1.75}, - {"x":1.75, "y":3.75}, - {"x":2.75, "y":3.75}, - {"x":3.75, "y":3.75}, - {"x":4.75, "y":3.75}, - {"x":5.75, "y":3.75}, - {"x":6.75, "y":3.75}, - {"x":7.75, "y":3.75}, - {"x":8.75, "y":3.75}, - {"x":9.75, "y":3.75}, - {"x":10.75, "y":3.75}, - {"x":11.75, "y":3.75}, - {"x":12.75, "y":3.75, "w":2.25}, - - {"x":0, "y":4.75, "w":1.25}, - {"x":1.25, "y":4.75}, - {"x":2.25, "y":4.75}, - {"x":3.25, "y":4.75}, - {"x":4.25, "y":4.75}, - {"x":5.25, "y":4.75}, - {"x":6.25, "y":4.75}, - {"x":7.25, "y":4.75}, - {"x":8.25, "y":4.75}, - {"x":9.25, "y":4.75}, - {"x":10.25, "y":4.75}, - {"x":11.25, "y":4.75}, - {"x":12.25, "y":4.75, "w":1.75}, - {"x":14, "y":4.75}, - {"x":16.25, "y":4.75}, - - {"x":0, "y":5.75, "w":1.25}, - {"x":1.25, "y":5.75, "w":1.25}, - {"x":2.5, "y":5.75, "w":1.25}, - {"x":3.75, "y":5.75, "w":2.5}, - {"x":6.25, "y":5.75}, - {"x":7.25, "y":5.75, "w":2.75}, - {"x":10, "y":5.75, "w":1.25}, - {"x":11.25, "y":5.75, "w":1.25}, - {"x":12.5, "y":5.75, "w":1.25}, - {"x":13.75, "y":5.75, "w":1.25}, - {"x":15.25, "y":5.75}, - {"x":16.25, "y":5.75}, - {"x":17.25, "y":5.75}, - - {"x":18.5, "y":0}, - {"x":18.5, "y":1} + {"x": 0, "y": 0.5}, + + {"x": 1.25, "y": 0.5}, + {"x": 2.25, "y": 0.5}, + {"x": 3.25, "y": 0.5}, + {"x": 4.25, "y": 0.5}, + + {"x": 5.5, "y": 0.5}, + {"x": 6.5, "y": 0.5}, + {"x": 7.5, "y": 0.5}, + {"x": 8.5, "y": 0.5}, + + {"x": 9.75, "y": 0.5}, + {"x": 10.75, "y": 0.5}, + {"x": 11.75, "y": 0.5}, + {"x": 12.75, "y": 0.5}, + + {"x": 14, "y": 0.5}, + + {"x": 15.25, "y": 0.5}, + {"x": 16.25, "y": 0.5}, + {"x": 17.25, "y": 0.5}, + + {"x": 0, "y": 1.75}, + {"x": 1, "y": 1.75}, + {"x": 2, "y": 1.75}, + {"x": 3, "y": 1.75}, + {"x": 4, "y": 1.75}, + {"x": 5, "y": 1.75}, + {"x": 6, "y": 1.75}, + {"x": 7, "y": 1.75}, + {"x": 8, "y": 1.75}, + {"x": 9, "y": 1.75}, + {"x": 10, "y": 1.75}, + {"x": 11, "y": 1.75}, + {"x": 12, "y": 1.75}, + {"x": 13, "y": 1.75}, + {"x": 14, "y": 1.75}, + + {"x": 15.25, "y": 1.75}, + {"x": 16.25, "y": 1.75}, + {"x": 17.25, "y": 1.75}, + + {"x": 0, "y": 2.75, "w": 1.5}, + {"x": 1.5, "y": 2.75}, + {"x": 2.5, "y": 2.75}, + {"x": 3.5, "y": 2.75}, + {"x": 4.5, "y": 2.75}, + {"x": 5.5, "y": 2.75}, + {"x": 6.5, "y": 2.75}, + {"x": 7.5, "y": 2.75}, + {"x": 8.5, "y": 2.75}, + {"x": 9.5, "y": 2.75}, + {"x": 10.5, "y": 2.75}, + {"x": 11.5, "y": 2.75}, + {"x": 12.5, "y": 2.75}, + {"x": 13.5, "y": 2.75, "w": 1.5}, + + {"x": 15.25, "y": 2.75}, + {"x": 16.25, "y": 2.75}, + {"x": 17.25, "y": 2.75}, + + {"x": 0, "y": 3.75, "w": 1.75}, + {"x": 1.75, "y": 3.75}, + {"x": 2.75, "y": 3.75}, + {"x": 3.75, "y": 3.75}, + {"x": 4.75, "y": 3.75}, + {"x": 5.75, "y": 3.75}, + {"x": 6.75, "y": 3.75}, + {"x": 7.75, "y": 3.75}, + {"x": 8.75, "y": 3.75}, + {"x": 9.75, "y": 3.75}, + {"x": 10.75, "y": 3.75}, + {"x": 11.75, "y": 3.75}, + {"x": 12.75, "y": 3.75, "w": 2.25}, + + {"x": 0, "y": 4.75, "w": 1.25}, + {"x": 1.25, "y": 4.75}, + {"x": 2.25, "y": 4.75}, + {"x": 3.25, "y": 4.75}, + {"x": 4.25, "y": 4.75}, + {"x": 5.25, "y": 4.75}, + {"x": 6.25, "y": 4.75}, + {"x": 7.25, "y": 4.75}, + {"x": 8.25, "y": 4.75}, + {"x": 9.25, "y": 4.75}, + {"x": 10.25, "y": 4.75}, + {"x": 11.25, "y": 4.75}, + {"x": 12.25, "y": 4.75, "w": 1.75}, + {"x": 14, "y": 4.75}, + + {"x": 16.25, "y": 4.75}, + + {"x": 0, "y": 5.75, "w": 1.25}, + {"x": 1.25, "y": 5.75, "w": 1.25}, + {"x": 2.5, "y": 5.75, "w": 1.25}, + {"x": 3.75, "y": 5.75}, + {"x": 4.75, "y": 5.75, "w": 1.5}, + {"x": 6.25, "y": 5.75}, + {"x": 7.25, "y": 5.75, "w": 2.75}, + {"x": 10, "y": 5.75, "w": 1.25}, + {"x": 11.25, "y": 5.75, "w": 1.25}, + {"x": 12.5, "y": 5.75, "w": 1.25}, + {"x": 13.75, "y": 5.75, "w": 1.25}, + + {"x": 15.25, "y": 5.75}, + {"x": 16.25, "y": 5.75}, + {"x": 17.25, "y": 5.75}, + + {"x": 18.5, "y": 0}, + {"x": 18.5, "y": 1} ] } } diff --git a/keyboards/ramonimbao/squishytkl/squishytkl.h b/keyboards/ramonimbao/squishytkl/squishytkl.h index 53d91c27ed85..204d497a577d 100644 --- a/keyboards/ramonimbao/squishytkl/squishytkl.h +++ b/keyboards/ramonimbao/squishytkl/squishytkl.h @@ -30,106 +30,98 @@ #define ___ KC_NO #define LAYOUT_ansi( \ - k00, k01, k02, k03, k04, k10, k11, k12, k13, k20, k21, k22, k23, k24, k3k, k3l, k3m, \ - k85, k86, k87, k88, k89, k8a, k8b, k8c, k8d, k8e, k8f, k8g, k8h, k8i, k4k, k4l, k4m, \ - k95, k96, k97, k98, k99, k9a, k9b, k9c, k9d, k9e, k9f, k9g, k9h, k9j, k5k, k5l, k5m, \ - ka5, ka6, ka7, ka8, ka9, kaa, kab, kac, kad, kae, kaf, kag, kai, \ - kb5, kb7, kb8, kb9, kba, kbb, kbc, kbd, kbe, kbf, kbg, kbi, k6l, \ - kc5, kc6, kc7, kcd, kcf, kcg, kch, kci, k7k, k7l, k7m \ + k00, k01, k02, k03, k04, k10, k11, k12, k13, k20, k21, k22, k23, k24, k3K, k3L, k3M, \ + k85, k86, k87, k88, k89, k8A, k8B, k8C, k8D, k8E, k8F, k8G, k8H, k8I, k4K, k4L, k4M, \ + k95, k96, k97, k98, k99, k9A, k9B, k9C, k9D, k9E, k9F, k9G, k9H, k9J, k5K, k5L, k5M, \ + kA5, kA6, kA7, kA8, kA9, kAA, kAB, kAC, kAD, kAE, kAF, kAG, kAI, \ + kB5, kB7, kB8, kB9, kBA, kBB, kBC, kBD, kBE, kBF, kBG, kBI, k6O, \ + kC5, kC6, kC7, kCD, kCF, kCG, kCI, kCJ, k7N, k7O, k7P \ ) { \ - /* 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 */ \ - /* 0 1 2 3 4 5 6 7 8 9 a b c d e f g h i j k l m n o p */ \ - /* 0 | 0 */ { k00, k01, k02, k03, k04, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 1 | 1 */ { k10, k11, k12, k13, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 2 | 2 */ { k20, k21, k22, k23, k24, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 3 | 3 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k3k, k3l, k3m, ___, ___, ___ }, \ - /* 4 | 4 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k4k, k4l, k4m, ___, ___, ___ }, \ - /* 5 | 5 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k5k, k5l, k5m, ___, ___, ___ }, \ - /* 6 | 6 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k6l, ___ }, \ - /* 7 | 7 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k7k, k7l, k7m }, \ - /* 8 | 8 */ { ___, ___, ___, ___, ___, k85, k86, k87, k88, k89, k8a, k8b, k8c, k8d, k8e, k8f, k8g, k8h, k8i, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 9 | 9 */ { ___, ___, ___, ___, ___, k95, k96, k97, k98, k99, k9a, k9b, k9c, k9d, k9e, k9f, k9g, k9h, ___, k9j, ___, ___, ___, ___, ___, ___ }, \ - /* 10 | a */ { ___, ___, ___, ___, ___, ka5, ka6, ka7, ka8, ka9, kaa, kab, kac, kad, kae, kaf, kag, ___, kai, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 11 | b */ { ___, ___, ___, ___, ___, kb5, ___, kb7, kb8, kb9, kba, kbb, kbc, kbd, kbe, kbf, kbg, ___, kbi, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 12 | c */ { ___, ___, ___, ___, ___, kc5, kc6, kc7, ___, ___, ___, ___, ___, kcd, ___, kcf, kcg, ___, kch, kci, ___, ___, ___, ___, ___, ___ }, \ - /* 13 | c */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { k00, k01, k02, k03, k04, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { k10, k11, k12, k13, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { k20, k21, k22, k23, k24, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k3K, k3L, k3M, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k4K, k4L, k4M, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k5K, k5L, k5M, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k6O, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k7N, k7O, k7P }, \ + { ___, ___, ___, ___, ___, k85, k86, k87, k88, k89, k8A, k8B, k8C, k8D, k8E, k8F, k8G, k8H, k8I, ___, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, k95, k96, k97, k98, k99, k9A, k9B, k9C, k9D, k9E, k9F, k9G, k9H, ___, k9J, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, kA5, kA6, kA7, kA8, kA9, kAA, kAB, kAC, kAD, kAE, kAF, kAG, ___, kAI, ___, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, kB5, ___, kB7, kB8, kB9, kBA, kBB, kBC, kBD, kBE, kBF, kBG, ___, kBI, ___, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, kC5, kC6, kC7, ___, ___, ___, ___, ___, kCD, ___, kCF, kCG, ___, kCI, kCJ, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ } \ } #define LAYOUT_iso( \ - k00, k01, k02, k03, k04, k10, k11, k12, k13, k20, k21, k22, k23, k24, k3k, k3l, k3m, \ - k85, k86, k87, k88, k89, k8a, k8b, k8c, k8d, k8e, k8f, k8g, k8h, k8i, k4k, k4l, k4m, \ - k95, k96, k97, k98, k99, k9a, k9b, k9c, k9d, k9e, k9f, k9g, k9h, k5k, k5l, k5m, \ - ka5, ka6, ka7, ka8, ka9, kaa, kab, kac, kad, kae, kaf, kag, kai, k9j, \ - kb5, kb6, kb7, kb8, kb9, kba, kbb, kbc, kbd, kbe, kbf, kbg, kbi, k6l, \ - kc5, kc6, kc7, kcd, kcf, kcg, kch, kci, k7k, k7l, k7m \ + k00, k01, k02, k03, k04, k10, k11, k12, k13, k20, k21, k22, k23, k24, k3K, k3L, k3M, \ + k85, k86, k87, k88, k89, k8A, k8B, k8C, k8D, k8E, k8F, k8G, k8H, k8I, k4K, k4L, k4M, \ + k95, k96, k97, k98, k99, k9A, k9B, k9C, k9D, k9E, k9F, k9G, k9H, k5K, k5L, k5M, \ + kA5, kA6, kA7, kA8, kA9, kAA, kAB, kAC, kAD, kAE, kAF, kAG, kAI, k9J, \ + kB5, kB6, kB7, kB8, kB9, kBA, kBB, kBC, kBD, kBE, kBF, kBG, kBI, k6O, \ + kC5, kC6, kC7, kCD, kCF, kCG, kCI, kCJ, k7N, k7O, k7P \ ) { \ - /* 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 */ \ - /* 0 1 2 3 4 5 6 7 8 9 a b c d e f g h i j k l m n o p */ \ - /* 0 | 0 */ { k00, k01, k02, k03, k04, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 1 | 1 */ { k10, k11, k12, k13, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 2 | 2 */ { k20, k21, k22, k23, k24, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 3 | 3 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k3k, k3l, k3m, ___, ___, ___ }, \ - /* 4 | 4 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k4k, k4l, k4m, ___, ___, ___ }, \ - /* 5 | 5 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k5k, k5l, k5m, ___, ___, ___ }, \ - /* 6 | 6 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k6l, ___ }, \ - /* 7 | 7 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k7k, k7l, k7m }, \ - /* 8 | 8 */ { ___, ___, ___, ___, ___, k85, k86, k87, k88, k89, k8a, k8b, k8c, k8d, k8e, k8f, k8g, k8h, k8i, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 9 | 9 */ { ___, ___, ___, ___, ___, k95, k96, k97, k98, k99, k9a, k9b, k9c, k9d, k9e, k9f, k9g, k9h, ___, k9j, ___, ___, ___, ___, ___, ___ }, \ - /* 10 | a */ { ___, ___, ___, ___, ___, ka5, ka6, ka7, ka8, ka9, kaa, kab, kac, kad, kae, kaf, kag, ___, kai, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 11 | b */ { ___, ___, ___, ___, ___, kb5, kb6, kb7, kb8, kb9, kba, kbb, kbc, kbd, kbe, kbf, kbg, ___, kbi, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 12 | c */ { ___, ___, ___, ___, ___, kc5, kc6, kc7, ___, ___, ___, ___, ___, kcd, ___, kcf, kcg, ___, kch, kci, ___, ___, ___, ___, ___, ___ }, \ - /* 13 | c */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { k00, k01, k02, k03, k04, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { k10, k11, k12, k13, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { k20, k21, k22, k23, k24, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k3K, k3L, k3M, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k4K, k4L, k4M, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k5K, k5L, k5M, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k6O, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k7N, k7O, k7P }, \ + { ___, ___, ___, ___, ___, k85, k86, k87, k88, k89, k8A, k8B, k8C, k8D, k8E, k8F, k8G, k8H, k8I, ___, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, k95, k96, k97, k98, k99, k9A, k9B, k9C, k9D, k9E, k9F, k9G, k9H, ___, k9J, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, kA5, kA6, kA7, kA8, kA9, kAA, kAB, kAC, kAD, kAE, kAF, kAG, ___, kAI, ___, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, kB5, kB6, kB7, kB8, kB9, kBA, kBB, kBC, kBD, kBE, kBF, kBG, ___, kBI, ___, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, kC5, kC6, kC7, ___, ___, ___, ___, ___, kCD, ___, kCF, kCG, ___, kCI, kCJ, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ } \ } #define LAYOUT_jis( \ - k00, k01, k02, k03, k04, k10, k11, k12, k13, k20, k21, k22, k23, k24, k3k, k3l, k3m, \ - k85, k86, k87, k88, k89, k8a, k8b, k8c, k8d, k8e, k8f, k8g, k8h, k8i, k8j, k4k, k4l, k4m, \ - k95, k96, k97, k98, k99, k9a, k9b, k9c, k9d, k9e, k9f, k9g, k9h, k5k, k5l, k5m, \ - ka5, ka6, ka7, ka8, ka9, kaa, kab, kac, kad, kae, kaf, kag, kai, k9j, \ - kb5, kb7, kb8, kb9, kba, kbb, kbc, kbd, kbe, kbf, kbg, kbi, kbj, k6l, \ - kc5, kc6, kc7, kc8, kc9, kcd, kce, kcf, kcg, kch, kci, k7k, k7l, k7m \ + k00, k01, k02, k03, k04, k10, k11, k12, k13, k20, k21, k22, k23, k24, k3K, k3L, k3M, \ + k85, k86, k87, k88, k89, k8A, k8B, k8C, k8D, k8E, k8F, k8G, k8H, k8I, k8J, k4K, k4L, k4M, \ + k95, k96, k97, k98, k99, k9A, k9B, k9C, k9D, k9E, k9F, k9G, k9H, k5K, k5L, k5M, \ + kA5, kA6, kA7, kA8, kA9, kAA, kAB, kAC, kAD, kAE, kAF, kAG, kAI, k9J, \ + kB5, kB7, kB8, kB9, kBA, kBB, kBC, kBD, kBE, kBF, kBG, kBI, kBJ, k6O, \ + kC5, kC6, kC7, kC8, kC9, kCD, kCE, kCF, kCG, kCI, kCJ, k7N, k7O, k7P \ ) { \ - /* 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 */ \ - /* 0 1 2 3 4 5 6 7 8 9 a b c d e f g h i j k l m n o p */ \ - /* 0 | 0 */ { k00, k01, k02, k03, k04, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 1 | 1 */ { k10, k11, k12, k13, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 2 | 2 */ { k20, k21, k22, k23, k24, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 3 | 3 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k3k, k3l, k3m, ___, ___, ___ }, \ - /* 4 | 4 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k4k, k4l, k4m, ___, ___, ___ }, \ - /* 5 | 5 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k5k, k5l, k5m, ___, ___, ___ }, \ - /* 6 | 6 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k6l, ___ }, \ - /* 7 | 7 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k7k, k7l, k7m }, \ - /* 8 | 8 */ { ___, ___, ___, ___, ___, k85, k86, k87, k88, k89, k8a, k8b, k8c, k8d, k8e, k8f, k8g, k8h, k8i, k8j, ___, ___, ___, ___, ___, ___ }, \ - /* 9 | 9 */ { ___, ___, ___, ___, ___, k95, k96, k97, k98, k99, k9a, k9b, k9c, k9d, k9e, k9f, k9g, k9h, ___, k9j, ___, ___, ___, ___, ___, ___ }, \ - /* 10 | a */ { ___, ___, ___, ___, ___, ka5, ka6, ka7, ka8, ka9, kaa, kab, kac, kad, kae, kaf, kag, ___, kai, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 11 | b */ { ___, ___, ___, ___, ___, kb5, ___, kb7, kb8, kb9, kba, kbb, kbc, kbd, kbe, kbf, kbg, ___, kbi, kbj, ___, ___, ___, ___, ___, ___ }, \ - /* 12 | c */ { ___, ___, ___, ___, ___, kc5, kc6, kc7, kc8, kc9, ___, ___, ___, kcd, kce, kcf, kcg, ___, kch, kci, ___, ___, ___, ___, ___, ___ }, \ - /* 13 | c */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { k00, k01, k02, k03, k04, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { k10, k11, k12, k13, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { k20, k21, k22, k23, k24, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k3K, k3L, k3M, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k4K, k4L, k4M, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k5K, k5L, k5M, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k6O, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k7N, k7O, k7P }, \ + { ___, ___, ___, ___, ___, k85, k86, k87, k88, k89, k8A, k8B, k8C, k8D, k8E, k8F, k8G, k8H, k8I, k8J, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, k95, k96, k97, k98, k99, k9A, k9B, k9C, k9D, k9E, k9F, k9G, k9H, ___, k9J, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, kA5, kA6, kA7, kA8, kA9, kAA, kAB, kAC, kAD, kAE, kAF, kAG, ___, kAI, ___, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, kB5, ___, kB7, kB8, kB9, kBA, kBB, kBC, kBD, kBE, kBF, kBG, ___, kBI, kBJ, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, kC5, kC6, kC7, kC8, kC9, ___, ___, ___, kCD, kCE, kCF, kCG, ___, kCI, kCJ, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ } \ } #define LAYOUT_all( \ - k00, k01, k02, k03, k04, k10, k11, k12, k13, k20, k21, k22, k23, k24, k3k, k3l, k3m, \ - k85, k86, k87, k88, k89, k8a, k8b, k8c, k8d, k8e, k8f, k8g, k8h, k8i, k8j, k4k, k4l, k4m, \ - k95, k96, k97, k98, k99, k9a, k9b, k9c, k9d, k9e, k9f, k9g, k9h, k9j, k5k, k5l, k5m, \ - ka5, ka6, ka7, ka8, ka9, kaa, kab, kac, kad, kae, kaf, kag, kai, \ - kb5, kb6, kb7, kb8, kb9, kba, kbb, kbc, kbd, kbe, kbf, kbg, kbi, kbj, k6l, \ - kc5, kc6, kc7, kc8, kc9, kcd, kce, kcf, kcg, kch, kci, k7k, k7l, k7m, \ - kc0, kc1 \ + k00, k01, k02, k03, k04, k10, k11, k12, k13, k20, k21, k22, k23, k24, k3K, k3L, k3M, \ + k85, k86, k87, k88, k89, k8A, k8B, k8C, k8D, k8E, k8F, k8G, k8H, k8I, k8J, k4K, k4L, k4M, \ + k95, k96, k97, k98, k99, k9A, k9B, k9C, k9D, k9E, k9F, k9G, k9H, k9J, k5K, k5L, k5M, \ + kA5, kA6, kA7, kA8, kA9, kAA, kAB, kAC, kAD, kAE, kAF, kAG, kAI, \ + kB5, kB6, kB7, kB8, kB9, kBA, kBB, kBC, kBD, kBE, kBF, kBG, kBI, kBJ, k6O, \ + kC5, kC6, kC7, kC8, kC9, kCD, kCE, kCF, kCG, kCI, kCJ, k7N, k7O, k7P, \ + kD0, kD1 \ ) { \ - /* 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 */ \ - /* 0 1 2 3 4 5 6 7 8 9 a b c d e f g h i j k l m n o p */ \ - /* 0 | 0 */ { k00, k01, k02, k03, k04, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 1 | 1 */ { k10, k11, k12, k13, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 2 | 2 */ { k20, k21, k22, k23, k24, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 3 | 3 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k3k, k3l, k3m, ___, ___, ___ }, \ - /* 4 | 4 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k4k, k4l, k4m, ___, ___, ___ }, \ - /* 5 | 5 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k5k, k5l, k5m, ___, ___, ___ }, \ - /* 6 | 6 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k6l, ___ }, \ - /* 7 | 7 */ { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k7k, k7l, k7m }, \ - /* 8 | 8 */ { ___, ___, ___, ___, ___, k85, k86, k87, k88, k89, k8a, k8b, k8c, k8d, k8e, k8f, k8g, k8h, k8i, k8j, ___, ___, ___, ___, ___, ___ }, \ - /* 9 | 9 */ { ___, ___, ___, ___, ___, k95, k96, k97, k98, k99, k9a, k9b, k9c, k9d, k9e, k9f, k9g, k9h, ___, k9j, ___, ___, ___, ___, ___, ___ }, \ - /* 10 | a */ { ___, ___, ___, ___, ___, ka5, ka6, ka7, ka8, ka9, kaa, kab, kac, kad, kae, kaf, kag, ___, kai, ___, ___, ___, ___, ___, ___, ___ }, \ - /* 11 | b */ { ___, ___, ___, ___, ___, kb5, kb6, kb7, kb8, kb9, kba, kbb, kbc, kbd, kbe, kbf, kbg, ___, kbi, kbj, ___, ___, ___, ___, ___, ___ }, \ - /* 12 | c */ { ___, ___, ___, ___, ___, kc5, kc6, kc7, kc8, kc9, ___, ___, ___, kcd, kce, kcf, kcg, ___, kch, kci, ___, ___, ___, ___, ___, ___ }, \ - /* 13 | c */ { kc0, kc1, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { k00, k01, k02, k03, k04, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { k10, k11, k12, k13, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { k20, k21, k22, k23, k24, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k3K, k3L, k3M, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k4K, k4L, k4M, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k5K, k5L, k5M, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k6O, ___ }, \ + { ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, k7N, k7O, k7P }, \ + { ___, ___, ___, ___, ___, k85, k86, k87, k88, k89, k8A, k8B, k8C, k8D, k8E, k8F, k8G, k8H, k8I, k8J, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, k95, k96, k97, k98, k99, k9A, k9B, k9C, k9D, k9E, k9F, k9G, k9H, ___, k9J, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, kA5, kA6, kA7, kA8, kA9, kAA, kAB, kAC, kAD, kAE, kAF, kAG, ___, kAI, ___, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, kB5, kB6, kB7, kB8, kB9, kBA, kBB, kBC, kBD, kBE, kBF, kBG, ___, kBI, kBJ, ___, ___, ___, ___, ___, ___ }, \ + { ___, ___, ___, ___, ___, kC5, kC6, kC7, kC8, kC9, ___, ___, ___, kCD, kCE, kCF, kCG, ___, kCI, kCJ, ___, ___, ___, ___, ___, ___ }, \ + { kD0, kD1, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___ } \ } diff --git a/keyboards/viktus/sp_mini/keymaps/peott-fr/keymap.c b/keyboards/viktus/sp_mini/keymaps/peott-fr/keymap.c new file mode 100644 index 000000000000..93d65c93a217 --- /dev/null +++ b/keyboards/viktus/sp_mini/keymaps/peott-fr/keymap.c @@ -0,0 +1,117 @@ + /* Copyright 2021 peott + * + * 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 . + */ + +#include QMK_KEYBOARD_H + +// Layers by name +enum custom_layers { + _BASE, + _LHAND, + _RHAND, + _NUM +}; + +// Layers defined by function +#define LHAND LT(_LHAND,KC_SPC) +#define RHAND LT(_RHAND,KC_BSPC) +#define NUM TG(_NUM) +// Keycodes for cleaner code +#define L_CTRL LCTL_T(KC_MPRV) +#define L_ALT LALT_T(KC_MNXT) + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_BASE] = LAYOUT_all( + KC_MPLY, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSLS, + KC_TRNS, KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, NUM, + KC_TRNS, KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_DEL, + KC_TRNS, KC_LSPO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_UP, + KC_TRNS, L_CTRL, KC_LGUI, L_ALT, KC_NO, LHAND, RHAND, KC_RALT, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + [_LHAND] = LAYOUT_all( + RESET, KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, + KC_HOME, KC_TRNS, KC_TRNS, KC_TRNS, KC_UP, KC_TRNS, KC_TRNS, RGB_TOG, RGB_MOD, RGB_HUI, RGB_SAI, RGB_VAI, RGB_SPI, KC_TRNS, KC_TRNS, + KC_PGUP, KC_TRNS, KC_TRNS, KC_LEFT, KC_DOWN, KC_RGHT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_ENT, KC_TRNS, + KC_PGDN, KC_LSFT, KC_CALC, KC_MYCM, KC_TRNS, KC_ENT, KC_BSPC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_RSPC, KC_TRNS, + KC_END, KC_LCTL, KC_TRNS, KC_LALT, KC_TRNS, KC_TRNS, KC_TRNS, KC_RALT, KC_RCTL, KC_TRNS, KC_TRNS, KC_TRNS + ), + [_RHAND] = LAYOUT_all( + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, + KC_NO, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSLS, + KC_NO, KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_UNDS, KC_PLUS, KC_NO, KC_PIPE, + KC_NO, KC_LSFT, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_RSPC, KC_NO, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO + ), + [_NUM] = LAYOUT_all( + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, KC_NO, KC_NO, KC_NO, KC_F13, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_P7, KC_P8, KC_P9, KC_PPLS, KC_NO, KC_NO, KC_NO, NUM, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_P4, KC_P5, KC_P6, KC_PCMM, KC_NO, KC_NO, KC_NO, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_P1, KC_P2, KC_P3, KC_PEQL, KC_NO, KC_NO, + KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_P0, KC_PDOT, KC_PENT, KC_NO, KC_NO, KC_NO + ) +}; + +void keyboard_pre_init_user(void) { + setPinOutput(F5); // initialize F5 for LED + setPinOutput(F6); // initialize F6 for LED + setPinOutput(F7); // initialize F7 for LED +} + +layer_state_t layer_state_set_user(layer_state_t state) { + writePinLow(F5); + writePinLow(F6); + writePinLow(F7); + switch (get_highest_layer(state)) { + case _LHAND: + writePinHigh(F5); + break; + case _RHAND: + writePinHigh(F6); + break; + case _NUM: // replace 'XXXX' with the layer or function name + writePinHigh(F7); + break; + case KC_F13: + writePinHigh(F7); + writePinHigh(F5); + writePinHigh(F6); + break; + } + return state; +} + +bool spongebob_mode = false; +bool spongebob_case = false; +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + if (spongebob_mode) { + switch(keycode) { + case KC_A...KC_Z: + if (record->event.pressed) { + (spongebob_case ^= 1) == 0 ? tap_code16(S(keycode)) : tap_code(keycode); + return false; break; + } + } + } + switch(keycode) { + case KC_F13: + if (record->event.pressed) { + spongebob_mode ^= 1; + } + return false; break; + } + return true; +} + + diff --git a/keyboards/yampad/config.h b/keyboards/yampad/config.h index d04ae37d5a49..b21a606ddc97 100644 --- a/keyboards/yampad/config.h +++ b/keyboards/yampad/config.h @@ -20,7 +20,7 @@ along with this program. If not, see . #include "config_common.h" /* USB Device descriptor parameter */ -#define VENDOR_ID 0xFEED +#define VENDOR_ID 0x5950 // YP #define PRODUCT_ID 0x8369 #define DEVICE_VER 0x0001 #define MANUFACTURER Mattia Dal Ben diff --git a/keyboards/yampad/keymaps/via/keymap.c b/keyboards/yampad/keymaps/via/keymap.c new file mode 100644 index 000000000000..d22eb26177be --- /dev/null +++ b/keyboards/yampad/keymaps/via/keymap.c @@ -0,0 +1,163 @@ +/* MIT License + +Copyright (c) 2019 Mattia Dal Ben + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ + +#include QMK_KEYBOARD_H + +// Each layer gets a name for readability, which is then used in the keymap matrix below. +// The underscores don't mean anything - you can have a layer called STUFF or any other name. +// Layer names don't all need to be of the same length, obviously, and you can also skip them +// entirely and just use numbers. +enum layers { + _BL, + _NV, + _FN +}; + +enum custom_keycodes { + KC_DBL0 = SAFE_RANGE, +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { +/* Keymap _BL: (Base Layer) Default Layer + * ,-------------------. + * | NV | / | * |-/FN| + * |----|----|----|----| + * | 7 | 8 | 9 | | + * |----|----|----| + | + * | 4 | 5 | 6 | | + * |----|----|----|----| + * | 1 | 2 | 3 | | + * |----|----|----| En | + * | 0 | 00 | . | | + * `-------------------' + */ + [_BL] = LAYOUT( + TG(_NV), KC_PSLS, KC_PAST, LT(_FN, KC_PMNS), + KC_P7, KC_P8, KC_P9, + KC_P4, KC_P5, KC_P6, KC_PPLS, + KC_P1, KC_P2, KC_P3, + KC_P0, KC_DBL0, KC_PDOT, KC_PENT + ), + +/* Keymap _NV: Navigation layer + * ,-------------------. + * |INS |HOME|PGUP| | + * |----|----|----|----| + * |DEL |END |PGDN| | + * |----|----|----| | + * | | | | | + * |----|----|----|----| + * | | UP | | | + * |----|----|----| | + * |LEFT|DOWN|RIGH| | + * `-------------------' + */ + [_NV] = LAYOUT( + KC_INS, KC_HOME, KC_PGUP, TG(_NV), + KC_DEL, KC_END, KC_PGDN, + XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, + XXXXXXX, KC_UP, XXXXXXX, + KC_LEFT, KC_DOWN, KC_RGHT, XXXXXXX + ), + +/* Keymap _FN: RGB Function Layer + * ,-------------------. + * |RMOD|RGBP|RTOG| FN | + * |----|----|----|----| + * |HUD |HUI | | | + * |----|----|----| | + * |SAD |SAI | | | + * |----|----|----|----| + * |VAD |VAS | | | + * |----|----|----| | + * |RST | | | | + * `-------------------' + */ + [_FN] = LAYOUT( + RGB_MOD, RGB_M_P, RGB_TOG, _______, + RGB_HUD, RGB_HUI, XXXXXXX, + RGB_SAD, RGB_SAI, XXXXXXX, XXXXXXX, + RGB_VAD, RGB_VAI, XXXXXXX, + RESET, XXXXXXX, XXXXXXX, XXXXXXX + ), +}; + +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + case KC_DBL0: + if (record->event.pressed) { + SEND_STRING("00"); + } else { + // when keycode KC_DBL0 is released + } + break; + + } + return true; +}; + +#ifdef OLED_ENABLE + +oled_rotation_t oled_init_user(oled_rotation_t rotation) { + return OLED_ROTATION_270; // flips the display 270 degrees +} + +void oled_task_user(void) { + // Host Keyboard Layer Status + oled_write_P(PSTR("Layer"), false); + switch (get_highest_layer(layer_state)) { + case _BL: + oled_write_ln_P(PSTR(" BAS"), false); + break; + case _NV: + oled_write_ln_P(PSTR(" NAV"), false); + break; + case _FN: + oled_write_ln_P(PSTR(" RGB"), false); + break; + default: + // Or use the write_ln shortcut over adding '\n' to the end of your string + oled_write_ln_P(PSTR(" UND"), false); + } + + // Host Keyboard LED Status + led_t led_state = host_keyboard_led_state(); + oled_write_P(PSTR("-----"), false); + oled_write_P(PSTR("Stats"), false); + oled_write_P(led_state.num_lock ? PSTR("num:*") : PSTR("num:."), false); + oled_write_P(led_state.caps_lock ? PSTR("cap:*") : PSTR("cap:."), false); + oled_write_P(led_state.scroll_lock ? PSTR("scr:*") : PSTR("scr:."), false); + + // Host Keyboard RGB backlight status + oled_write_P(PSTR("-----"), false); + oled_write_P(PSTR("Light"), false); + + static char led_buf[30]; + snprintf(led_buf, sizeof(led_buf) - 1, "RGB:%cM: %2d\nh: %2ds: %2dv: %2d\n", + rgblight_is_enabled() ? '*' : '.', (uint8_t)rgblight_get_mode(), + (uint8_t)(rgblight_get_hue() / RGBLIGHT_HUE_STEP), + (uint8_t)(rgblight_get_sat() / RGBLIGHT_SAT_STEP), + (uint8_t)(rgblight_get_val() / RGBLIGHT_VAL_STEP)); + oled_write(led_buf, false); +} +#endif diff --git a/keyboards/yampad/keymaps/via/readme.md b/keyboards/yampad/keymaps/via/readme.md new file mode 100644 index 000000000000..29ea4d3cddfb --- /dev/null +++ b/keyboards/yampad/keymaps/via/readme.md @@ -0,0 +1,9 @@ +![Yampad Layout Image](https://i.imgur.com/QwrufEt.png) + +# VIA Yampad Layout + +This is the layout in the VIA enabled firmware. +Optional 2U zero key to suit your Yampad build. + +Compile: `make yampad:via` +Flash: `make yampad:via:flash` diff --git a/keyboards/yampad/keymaps/via/rules.mk b/keyboards/yampad/keymaps/via/rules.mk new file mode 100644 index 000000000000..9bf0baa68541 --- /dev/null +++ b/keyboards/yampad/keymaps/via/rules.mk @@ -0,0 +1,4 @@ +EXTRAKEY_ENABLE = no +LTO_ENABLE = yes +MOUSEKEY_ENABLE = no +VIA_ENABLE = yes diff --git a/keyboards/yampad/rules.mk b/keyboards/yampad/rules.mk index 5e14808709e8..667620e93b19 100644 --- a/keyboards/yampad/rules.mk +++ b/keyboards/yampad/rules.mk @@ -7,18 +7,17 @@ BOOTLOADER = caterina # Build Options # change yes to no to disable # -BOOTMAGIC_ENABLE = no # Enable Bootmagic Lite -MOUSEKEY_ENABLE = no # Mouse keys -EXTRAKEY_ENABLE = no # Audio control and System control -CONSOLE_ENABLE = no # Console for debug +AUDIO_ENABLE = no # Audio output +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite COMMAND_ENABLE = no # Commands for debug and configuration -# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE -SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +CONSOLE_ENABLE = no # Console for debug +DEBOUNCE_TYPE = sym_eager_pk +EXTRAKEY_ENABLE = no # Audio control and System control +LTO_ENABLE = yes # Link time optimise, reduce firmware size +MOUSEKEY_ENABLE = no # Mouse keys # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work NKRO_ENABLE = yes # USB Nkey Rollover -BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality -RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow -AUDIO_ENABLE = no # Audio output -OLED_ENABLE = yes OLED_DRIVER = SSD1306 -DEBOUNCE_TYPE = sym_eager_pk +OLED_ENABLE = yes +RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow diff --git a/keyboards/z12/config.h b/keyboards/z12/config.h new file mode 100644 index 000000000000..7f897b795d81 --- /dev/null +++ b/keyboards/z12/config.h @@ -0,0 +1,53 @@ +/* Copyright 2020 Sergi Meseguer + +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 . +*/ + +#pragma once + +#include "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x7A74 +#define PRODUCT_ID 0x0001 +#define DEVICE_VER 0x0001 +#define MANUFACTURER zigotica +#define PRODUCT z12 + +#define ENCODERS_PAD_A { B4, B2 } +#define ENCODERS_PAD_B { B5, B6 } +#define ENCODER_DIRECTION_FLIP + +/* key matrix size */ +#define MATRIX_ROWS 4 +#define MATRIX_COLS 4 + +/*Keyboard Matrix Assignments */ + +#define DIRECT_PINS { \ + { NO_PIN, E6, C6, NO_PIN }, \ + { D2, D7, D4, D3 }, \ + { F7, B1, B3, NO_PIN }, \ + { F6, F5, F4, NO_PIN } \ +} + +#define UNUSED_PINS + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + +/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ +#define LOCKING_SUPPORT_ENABLE +/* Locking resynchronize hack */ +#define LOCKING_RESYNC_ENABLE diff --git a/keyboards/z12/info.json b/keyboards/z12/info.json new file mode 100644 index 000000000000..3ae8937571e4 --- /dev/null +++ b/keyboards/z12/info.json @@ -0,0 +1,26 @@ +{ + "keyboard_name": "z12", + "url": "https://github.com/zigotica/mechanical-keyboards/tree/main/z12", + "maintainer": "@zigotica", + "layouts": { + "LAYOUT": { + "layout": [ + {"x": 1, "y": 0}, + {"x": 2, "y": 0}, + + {"x": 0, "y": 0.5}, + {"x": 1, "y": 1}, + {"x": 2, "y": 1}, + {"x": 3, "y": 0.5}, + + {"x": 0.5, "y": 2}, + {"x": 1.5, "y": 2}, + {"x": 2.5, "y": 2}, + + {"x": 0.5, "y": 3}, + {"x": 1.5, "y": 3}, + {"x": 2.5, "y": 3}, + ] + } + } +} diff --git a/keyboards/z12/keymaps/default/config.h b/keyboards/z12/keymaps/default/config.h new file mode 100644 index 000000000000..1fcf924f3532 --- /dev/null +++ b/keyboards/z12/keymaps/default/config.h @@ -0,0 +1,26 @@ +/* Copyright 2020 Sergi Meseguer + +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 . +*/ + +#pragma once + +#define OLED_DISPLAY_128X32 + +// EC11 encoders' resolution. +// Reduce the value to 2 if you feel missing values: +#define ENCODER_RESOLUTION 4 + +// Allows correct registered values by rotary encoder: +#define TAP_CODE_DELAY 10 diff --git a/keyboards/z12/keymaps/default/keymap.c b/keyboards/z12/keymaps/default/keymap.c new file mode 100644 index 000000000000..16a6c1f70e97 --- /dev/null +++ b/keyboards/z12/keymaps/default/keymap.c @@ -0,0 +1,59 @@ +/* Copyright 2020 Sergi Meseguer + +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 . +*/ + +#include QMK_KEYBOARD_H + +enum layers { + BASE = 0 +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { +/* + * Base Layer: BASE + * + * ,-----------------------. + * | | o | o | | + * |-------+---+---+-------| + * | o | o | o | o | + * |-------+-------+-------| + * | o | o | o | + * |-------+-------+-------| + * | o | o | o | + * |-------+-------+-------| + */ + [BASE] = LAYOUT( + KC_Q, KC_W, + KC_E, KC_R, KC_T, KC_Y, + KC_U, KC_I, KC_O, + KC_P, KC_K, KC_A + ), + +/* + * TEMPLATE + * + * ,-----------------------. + * | | o | o | | + * |-------+---+---+-------| + * | o | o | o | o | + * |-------+-------+-------| + * | o | o | o | + * |-------+-------+-------| + * | o | o | o | + * |-------+-------+-------| + */ + +}; + diff --git a/keyboards/z12/keymaps/default/readme.md b/keyboards/z12/keymaps/default/readme.md new file mode 100644 index 000000000000..5f30ab6a3966 --- /dev/null +++ b/keyboards/z12/keymaps/default/readme.md @@ -0,0 +1,3 @@ +# Default z12 Layout + +This is the default layout that comes flashed on every z12. diff --git a/keyboards/z12/keymaps/default/rules.mk b/keyboards/z12/keymaps/default/rules.mk new file mode 100644 index 000000000000..b220469c6c67 --- /dev/null +++ b/keyboards/z12/keymaps/default/rules.mk @@ -0,0 +1,2 @@ +OLED_ENABLE = yes # Enables the use of OLED displays +MOUSEKEY_ENABLE = yes diff --git a/keyboards/z12/readme.md b/keyboards/z12/readme.md new file mode 100644 index 000000000000..17e4bfdb8489 --- /dev/null +++ b/keyboards/z12/readme.md @@ -0,0 +1,3 @@ +# z12 + +Firmware for [z12 micropad](https://github.com/zigotica/mechanical-keyboards/tree/main/z12) designed by @zigotica diff --git a/keyboards/z12/rules.mk b/keyboards/z12/rules.mk new file mode 100644 index 000000000000..32cdab8e9595 --- /dev/null +++ b/keyboards/z12/rules.mk @@ -0,0 +1,24 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = caterina + +# Build Options +BOOTMAGIC_ENABLE = no # Enable Bootmagic Lite +MOUSEKEY_ENABLE = no # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +ENCODER_ENABLE = yes # Enables the use of encoders +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = no # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +AUDIO_ENABLE = no # Audio output +LTO_ENABLE = yes # Enables Link Time Optimization (LTO) which reduces the compiled size +OLED_ENABLE = yes # Enables the use of OLED displays +OLED_DRIVER = SSD1306 # Enables the use of OLED displays + diff --git a/keyboards/z12/z12.c b/keyboards/z12/z12.c new file mode 100644 index 000000000000..99fe62ab931c --- /dev/null +++ b/keyboards/z12/z12.c @@ -0,0 +1,39 @@ +/* Copyright 2020 Sergi Meseguer + * + * 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 . + */ + +#include "z12.h" + +#ifdef ENCODER_ENABLE +bool encoder_update_kb(uint8_t index, bool clockwise) { + if (!encoder_update_user(index, clockwise)) { return false; } + if (index == 0) { // LEFT + // Scroll + if (clockwise) { + tap_code_delay(KC_PGDN, 10); + } else { + tap_code_delay(KC_PGUP, 10); + } + } else { // RIGHT + // Volume control. + if (clockwise) { + tap_code_delay(KC_VOLU, 10); + } else { + tap_code_delay(KC_VOLD, 10); + } + } + return false; +} +#endif diff --git a/keyboards/z12/z12.h b/keyboards/z12/z12.h new file mode 100644 index 000000000000..0ea6c303f734 --- /dev/null +++ b/keyboards/z12/z12.h @@ -0,0 +1,34 @@ +/* Copyright 2020 Sergi Meseguer + * + * 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 . + */ + +#include "quantum.h" + +/* This a shortcut to help you visually see your layout */ + +#define ___ KC_NO + +#define LAYOUT( \ + BN4, BN2, \ + SW7, BN3, BN1, SW8, \ + SW4, SW5, SW6, \ + SW3, SW2, SW1 \ + ) \ + { \ + { ___, BN4, BN2, ___ }, \ + { SW7, BN3, BN1, SW8 }, \ + { SW4, SW5, SW6, ___ }, \ + { SW3, SW2, SW1, ___ }, \ + } diff --git a/keyboards/zinc/keymaps/default/rules.mk b/keyboards/zinc/keymaps/default/rules.mk index 883f0fc6030c..5cdd1c81aa3c 100644 --- a/keyboards/zinc/keymaps/default/rules.mk +++ b/keyboards/zinc/keymaps/default/rules.mk @@ -14,6 +14,7 @@ AUDIO_ENABLE = no # Audio output UNICODE_ENABLE = no # Unicode RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time. SWAP_HANDS_ENABLE = no # Enable one-hand typing +LTO_ENABLE = no # if firmware size over limit, try this option define ZINC_CUSTOMISE_MSG $(info Zinc customize) @@ -35,7 +36,6 @@ RGB_MATRIX = no # RGB LED Matrix RGB_MATRIX_SPLIT_RIGHT = no # RGB Matrix for RIGHT Hand LED_ANIMATIONS = yes # LED animations IOS_DEVICE_ENABLE = no # connect to IOS device (iPad,iPhone) -Link_Time_Optimization = no # if firmware size over limit, try this option #### LED_BACK_ENABLE and LED_UNDERGLOW_ENABLE. #### Do not enable these with audio at the same time. @@ -121,10 +121,6 @@ ifeq ($(strip $(RGB_MATRIX_SPLIT_RIGHT)), yes) OPT_DEFS += -DRGB_MATRIX_SPLIT_RIGHT endif -ifeq ($(strip $(Link_Time_Optimization)),yes) - EXTRAFLAGS += -flto -DUSE_Link_Time_Optimization -endif - # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend diff --git a/keyboards/zinc/keymaps/ginjake/rules.mk b/keyboards/zinc/keymaps/ginjake/rules.mk index 63e5227ef990..f2cb3633c6eb 100644 --- a/keyboards/zinc/keymaps/ginjake/rules.mk +++ b/keyboards/zinc/keymaps/ginjake/rules.mk @@ -15,6 +15,7 @@ UNICODE_ENABLE = no # Unicode BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time. SWAP_HANDS_ENABLE = no # Enable one-hand typing +LTO_ENABLE = no # if firmware size over limit, try this option define ZINC_CUSTOMISE_MSG $(info Zinc customize) @@ -33,7 +34,6 @@ LED_BOTH_ENABLE = no # LED backlight and underglow LED_RGB_CONT = no # LED continuous backlight or/and underglow between left Zinc and right Zinc LED_ANIMATIONS = yes # LED animations IOS_DEVICE_ENABLE = no # connect to IOS device (iPad,iPhone) -Link_Time_Optimization = no # if firmware size over limit, try this option #### LED_BACK_ENABLE and LED_UNDERGLOW_ENABLE. #### Do not enable these with audio at the same time. @@ -104,10 +104,6 @@ ifeq ($(strip $(LED_ANIMATIONS)), yes) endif -ifeq ($(strip $(Link_Time_Optimization)),yes) - EXTRAFLAGS += -flto -DUSE_Link_Time_Optimization -endif - # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend diff --git a/keyboards/zinc/keymaps/monks/rules.mk b/keyboards/zinc/keymaps/monks/rules.mk index d8ec4497e7ab..46646f919ce2 100644 --- a/keyboards/zinc/keymaps/monks/rules.mk +++ b/keyboards/zinc/keymaps/monks/rules.mk @@ -15,6 +15,7 @@ UNICODE_ENABLE = no # Unicode BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time. SWAP_HANDS_ENABLE = no # Enable one-hand typing +LTO_ENABLE = no # if firmware size over limit, try this option define ZINC_CUSTOMISE_MSG $(info Zinc customize) @@ -33,7 +34,6 @@ LED_BOTH_ENABLE = no # LED backlight and underglow LED_RGB_CONT = no # LED continuous backlight or/and underglow between left Zinc and right Zinc LED_ANIMATIONS = yes # LED animations IOS_DEVICE_ENABLE = no # connect to IOS device (iPad,iPhone) -Link_Time_Optimization = no # if firmware size over limit, try this option #### LED_BACK_ENABLE and LED_UNDERGLOW_ENABLE. #### Do not enable these with audio at the same time. @@ -104,10 +104,6 @@ ifeq ($(strip $(LED_ANIMATIONS)), yes) endif -ifeq ($(strip $(Link_Time_Optimization)),yes) - EXTRAFLAGS += -flto -DUSE_Link_Time_Optimization -endif - # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend diff --git a/keyboards/zinc/keymaps/toshi0383/rules.mk b/keyboards/zinc/keymaps/toshi0383/rules.mk index 7860cbd01902..9fef6963a1e0 100644 --- a/keyboards/zinc/keymaps/toshi0383/rules.mk +++ b/keyboards/zinc/keymaps/toshi0383/rules.mk @@ -15,6 +15,7 @@ UNICODE_ENABLE = no # Unicode BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time. SWAP_HANDS_ENABLE = no # Enable one-hand typing +LTO_ENABLE = no # if firmware size over limit, try this option define ZINC_CUSTOMISE_MSG $(info Zinc customize) @@ -36,7 +37,6 @@ RGB_MATRIX = no # RGB LED Matrix RGB_MATRIX_SPLIT_RIGHT = no # RGB Matrix for RIGHT Hand LED_ANIMATIONS = yes # LED animations IOS_DEVICE_ENABLE = no # connect to IOS device (iPad,iPhone) -Link_Time_Optimization = no # if firmware size over limit, try this option #### LED_BACK_ENABLE and LED_UNDERGLOW_ENABLE. #### Do not enable these with audio at the same time. @@ -122,10 +122,6 @@ ifeq ($(strip $(RGB_MATRIX_SPLIT_RIGHT)), yes) OPT_DEFS += -DRGB_MATRIX_SPLIT_RIGHT endif -ifeq ($(strip $(Link_Time_Optimization)),yes) - EXTRAFLAGS += -flto -DUSE_Link_Time_Optimization -endif - # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend diff --git a/layouts/community/ergodox/algernon/tools/log-to-heatmap.py b/layouts/community/ergodox/algernon/tools/log-to-heatmap.py index e927e0e39d4c..5f52d9932ba6 100755 --- a/layouts/community/ergodox/algernon/tools/log-to-heatmap.py +++ b/layouts/community/ergodox/algernon/tools/log-to-heatmap.py @@ -8,7 +8,6 @@ from math import floor from os.path import dirname -from subprocess import Popen, PIPE, STDOUT from blessings import Terminal class Heatmap(object): @@ -122,7 +121,6 @@ def get_heatmap(self): for (c, r) in self.log: coords = self.coord(c, r) - b, n = coords cap = self.max_cnt if cap == 0: cap = 1 @@ -302,7 +300,7 @@ def main(opts): break if not process_line(line, heatmaps, opts): continue - except: + except Exception: pass stamped_log = open ("%s/stamped-log" % (out_dir), "a+") diff --git a/layouts/community/ergodox/algernon/tools/text-to-log.py b/layouts/community/ergodox/algernon/tools/text-to-log.py index f080c32cd0d9..ba60a2e281d9 100755 --- a/layouts/community/ergodox/algernon/tools/text-to-log.py +++ b/layouts/community/ergodox/algernon/tools/text-to-log.py @@ -1,6 +1,5 @@ #!/usr/bin/env python3 -import os import sys charmap = { diff --git a/layouts/community/ergodox/german-manuneo/compile_keymap.py b/layouts/community/ergodox/german-manuneo/compile_keymap.py index 9ad5c88ecca5..df5d42984266 100644 --- a/layouts/community/ergodox/german-manuneo/compile_keymap.py +++ b/layouts/community/ergodox/german-manuneo/compile_keymap.py @@ -584,11 +584,6 @@ def unicode_macro_cases(config): for macro_id, uc_hex in config['unicode_macros'].items(): hi = int(uc_hex, 16) >> 8 lo = int(uc_hex, 16) & 0xFF - unimacro_keys = ", ".join( - "T({})".format( - "KP_" + digit if digit.isdigit() else digit - ) for digit in uc_hex - ) yield UNICODE_MACRO_TEMPLATE.format( macro_id=macro_id, hi=hi, lo=lo ) diff --git a/lib/python/qmk/cli/doctor/linux.py b/lib/python/qmk/cli/doctor/linux.py index 6ce00f6ef196..94683d3307af 100644 --- a/lib/python/qmk/cli/doctor/linux.py +++ b/lib/python/qmk/cli/doctor/linux.py @@ -118,10 +118,9 @@ def check_udev_rules(): cli.log.warning("{fg_yellow}Found old, deprecated udev rules for '%s' boards. The new rules on https://docs.qmk.fm/#/faq_build?id=linux-udev-rules offer better security with the same functionality.", bootloader) else: # For caterina, check if ModemManager is running - if bootloader == "caterina": - if check_modem_manager(): - rc = CheckStatus.WARNING - cli.log.warning("{fg_yellow}Detected ModemManager without the necessary udev rules. Please either disable it or set the appropriate udev rules if you are using a Pro Micro.") + if bootloader == "caterina" and check_modem_manager(): + cli.log.warning("{fg_yellow}Detected ModemManager without the necessary udev rules. Please either disable it or set the appropriate udev rules if you are using a Pro Micro.") + rc = CheckStatus.WARNING cli.log.warning("{fg_yellow}Missing or outdated udev rules for '%s' boards. Run 'sudo cp %s/util/udev/50-qmk.rules /etc/udev/rules.d/'.", bootloader, QMK_FIRMWARE) @@ -167,6 +166,5 @@ def os_test_linux(): return CheckStatus.OK else: cli.log.info("Detected {fg_cyan}Linux{fg_reset}.") - from .linux import check_udev_rules return check_udev_rules() diff --git a/lib/python/qmk/cli/doctor/main.py b/lib/python/qmk/cli/doctor/main.py index 6a31ccdfdde9..ed20f46d3f7f 100755 --- a/lib/python/qmk/cli/doctor/main.py +++ b/lib/python/qmk/cli/doctor/main.py @@ -79,12 +79,13 @@ def doctor(cli): cli.log.info('CLI version: %s', cli.version) cli.log.info('QMK home: {fg_cyan}%s', QMK_FIRMWARE) - status = os_tests() + status = os_status = os_tests() + git_status = git_tests() - status = git_tests() + if git_status == CheckStatus.ERROR or (os_status == CheckStatus.OK and git_status == CheckStatus.WARNING): + status = git_status - venv = in_virtualenv() - if venv: + if in_virtualenv(): cli.log.info('CLI installed in virtualenv.') # Make sure the basic CLI tools we need are available and can be executed. diff --git a/lib/python/qmk/cli/generate/config_h.py b/lib/python/qmk/cli/generate/config_h.py index ca7e14fe6be1..f16dca1de8b9 100755 --- a/lib/python/qmk/cli/generate/config_h.py +++ b/lib/python/qmk/cli/generate/config_h.py @@ -173,7 +173,7 @@ def generate_config_h(cli): kb_info_json = dotty(info_json(cli.args.keyboard)) # Build the info_config.h file. - config_h_lines = ['/* This file was generated by `qmk generate-config-h`. Do not edit or copy.' ' */', '', '#pragma once'] + config_h_lines = ['/* This file was generated by `qmk generate-config-h`. Do not edit or copy.', ' */', '', '#pragma once'] generate_config_items(kb_info_json, config_h_lines) diff --git a/lib/python/qmk/cli/generate/dfu_header.py b/lib/python/qmk/cli/generate/dfu_header.py index 211ed9991a18..5a1b109f1e97 100644 --- a/lib/python/qmk/cli/generate/dfu_header.py +++ b/lib/python/qmk/cli/generate/dfu_header.py @@ -30,7 +30,7 @@ def generate_dfu_header(cli): # Build the Keyboard.h file. kb_info_json = dotty(info_json(cli.config.generate_dfu_header.keyboard)) - keyboard_h_lines = ['/* This file was generated by `qmk generate-dfu-header`. Do not edit or copy.' ' */', '', '#pragma once'] + keyboard_h_lines = ['/* This file was generated by `qmk generate-dfu-header`. Do not edit or copy.', ' */', '', '#pragma once'] keyboard_h_lines.append(f'#define MANUFACTURER {kb_info_json["manufacturer"]}') keyboard_h_lines.append(f'#define PRODUCT {cli.config.generate_dfu_header.keyboard} Bootloader') diff --git a/lib/python/qmk/cli/generate/keyboard_h.py b/lib/python/qmk/cli/generate/keyboard_h.py index c9d7f549b30b..f05178cedef7 100755 --- a/lib/python/qmk/cli/generate/keyboard_h.py +++ b/lib/python/qmk/cli/generate/keyboard_h.py @@ -36,7 +36,7 @@ def generate_keyboard_h(cli): has_layout_h = would_populate_layout_h(cli.args.keyboard) # Build the layouts.h file. - keyboard_h_lines = ['/* This file was generated by `qmk generate-keyboard-h`. Do not edit or copy.' ' */', '', '#pragma once', '#include "quantum.h"'] + keyboard_h_lines = ['/* This file was generated by `qmk generate-keyboard-h`. Do not edit or copy.', ' */', '', '#pragma once', '#include "quantum.h"'] if not has_layout_h: keyboard_h_lines.append('#pragma error(".h is only optional for data driven keyboards - kb.h == bad times")') diff --git a/lib/python/qmk/cli/generate/layouts.py b/lib/python/qmk/cli/generate/layouts.py index 4de982f822f2..e44266e1c8f3 100755 --- a/lib/python/qmk/cli/generate/layouts.py +++ b/lib/python/qmk/cli/generate/layouts.py @@ -38,7 +38,7 @@ def generate_layouts(cli): kb_info_json = info_json(cli.config.generate_layouts.keyboard) # Build the layouts.h file. - layouts_h_lines = ['/* This file was generated by `qmk generate-layouts`. Do not edit or copy.' ' */', '', '#pragma once'] + layouts_h_lines = ['/* This file was generated by `qmk generate-layouts`. Do not edit or copy.', ' */', '', '#pragma once'] if 'matrix_pins' in kb_info_json: if 'direct' in kb_info_json['matrix_pins']: diff --git a/lib/python/qmk/info.py b/lib/python/qmk/info.py index 7f3aabdc3b01..1b4c42ff4127 100644 --- a/lib/python/qmk/info.py +++ b/lib/python/qmk/info.py @@ -29,10 +29,10 @@ def info_json(keyboard): """Generate the info.json data for a specific keyboard. """ cur_dir = Path('keyboards') - rules = parse_rules_mk_file(cur_dir / keyboard / 'rules.mk') - if 'DEFAULT_FOLDER' in rules: - keyboard = rules['DEFAULT_FOLDER'] - rules = parse_rules_mk_file(cur_dir / keyboard / 'rules.mk', rules) + root_rules_mk = parse_rules_mk_file(cur_dir / keyboard / 'rules.mk') + + if 'DEFAULT_FOLDER' in root_rules_mk: + keyboard = root_rules_mk['DEFAULT_FOLDER'] info_data = { 'keyboard_name': str(keyboard), diff --git a/lib/python/qmk/keymap.py b/lib/python/qmk/keymap.py index 2d5921e7a868..6eec49cfd1a7 100644 --- a/lib/python/qmk/keymap.py +++ b/lib/python/qmk/keymap.py @@ -149,8 +149,8 @@ def is_keymap_dir(keymap, c=True, json=True, additional_files=None): for file in files: if (keymap / file).is_file(): if additional_files: - for file in additional_files: - if not (keymap / file).is_file(): + for additional_file in additional_files: + if not (keymap / additional_file).is_file(): return False return True diff --git a/message.mk b/message.mk index 419e3f5f314d..cb4ef43719a3 100644 --- a/message.mk +++ b/message.mk @@ -88,6 +88,7 @@ endef MSG_AVAILABLE_KEYMAPS = $(eval $(call GENERATE_MSG_AVAILABLE_KEYMAPS))$(MSG_AVAILABLE_KEYMAPS_ACTUAL) MSG_CHECK_FILESIZE = Checking file size of $(TARGET).$(FIRMWARE_FORMAT) +MSG_CHECK_FILESIZE_SKIPPED = (Firmware size check does not yet support $(MCU_ORIG); skipping) MSG_FILE_TOO_BIG = $(ERROR_COLOR)The firmware is too large!$(NO_COLOR) $(CURRENT_SIZE)/$(MAX_SIZE) ($(OVER_SIZE) bytes over)\n MSG_FILE_TOO_SMALL = The firmware is too small! $(CURRENT_SIZE)/$(MAX_SIZE)\n MSG_FILE_JUST_RIGHT = The firmware size is fine - $(CURRENT_SIZE)/$(MAX_SIZE) ($(PERCENT_SIZE)%%, $(FREE_SIZE) bytes free)\n diff --git a/tmk_core/rules.mk b/tmk_core/rules.mk index 5a7f299102e1..fd59fa032a1c 100644 --- a/tmk_core/rules.mk +++ b/tmk_core/rules.mk @@ -484,7 +484,7 @@ check-size: fi else check-size: - $(SILENT) || echo "(Firmware size check does not yet support $(MCU) microprocessors; skipping.)" + $(SILENT) || echo "$(MSG_CHECK_FILESIZE_SKIPPED)" endif check-md5: diff --git a/users/arkag/arkag.c b/users/arkag/arkag.c index ea716ecdab8f..da85d4f6d499 100644 --- a/users/arkag/arkag.c +++ b/users/arkag/arkag.c @@ -392,6 +392,10 @@ void matrix_scan_user(void) { // end format functions // start fancy functions + SEQ_TWO_KEYS(KC_V, KC_P) { + SEND_STRING("ggvG}x:set paste\ni"); + pri_mod_keystroke(KC_V); + } SEQ_THREE_KEYS(KC_C, KC_C, KC_ENT) { surround_type(6, KC_GRAVE, false); pri_mod_keystroke(KC_V); diff --git a/users/dennytom/chording_engine/chord.py b/users/dennytom/chording_engine/chord.py index 707f36b82a8a..5e3b6d2834f2 100644 --- a/users/dennytom/chording_engine/chord.py +++ b/users/dennytom/chording_engine/chord.py @@ -1,5 +1,4 @@ from functools import reduce -import re strings = [] number_of_strings = -1 @@ -463,4 +462,4 @@ def secret_chord(PSEUDOLAYER, ACTION, INPUT_STRING, data, output_buffer, index, hash = hash[3:] if hash != "": - return add_key(PSEUDOLAYER, hash, ACTION, output_buffer, index, number_of_strings, strings) \ No newline at end of file + return add_key(PSEUDOLAYER, hash, ACTION, output_buffer, index, number_of_strings, strings) diff --git a/util/stm32eeprom_parser.py b/util/stm32eeprom_parser.py index b124f713d543..e08b67064be9 100755 --- a/util/stm32eeprom_parser.py +++ b/util/stm32eeprom_parser.py @@ -197,7 +197,6 @@ def display(pos, row): print("") size = len(data) - empty_rows = 0 prev_row = '' first_repeat = True for pos in range(0, size, 16): diff --git a/util/uf2conv.py b/util/uf2conv.py index 044a7f231890..8677a828c9fd 100755 --- a/util/uf2conv.py +++ b/util/uf2conv.py @@ -78,7 +78,7 @@ def convert_from_uf2(buf): if datalen > 476: assert False, "Invalid UF2 data size at " + ptr newaddr = hd[3] - if curraddr == None: + if curraddr is None: appstartaddr = newaddr curraddr = newaddr padding = newaddr - curraddr @@ -171,7 +171,7 @@ def convert_from_hex_to_uf2(buf): break elif tp == 0: addr = upper | (rec[1] << 8) | rec[2] - if appstartaddr == None: + if appstartaddr is None: appstartaddr = addr i = 4 while i < len(rec) - 1: @@ -215,7 +215,7 @@ def get_drives(): def has_info(d): try: return os.path.isfile(d + INFO_FILE) - except: + except Exception: return False return list(filter(has_info, drives)) @@ -300,7 +300,7 @@ def error(msg): (ext, len(outbuf), appstartaddr)) if args.convert or ext != "uf2": drives = [] - if args.output == None: + if args.output is None: args.output = "flash." + ext else: drives = get_drives() From 6e7951e96dcef24650198fd3fdfa174f19e7be97 Mon Sep 17 00:00:00 2001 From: Jonavin <=> Date: Tue, 28 Sep 2021 16:50:50 -0400 Subject: [PATCH 24/24] resolve conflicts