[Keymap] Add personal CRKBD keymap (#6843)

* Add personal keymap

* Additional readme note

* Fix typo's in readme

* Additional layer key info in readme

* Update keyboards/crkbd/keymaps/rpbaptist/config.h

Co-Authored-By: Drashna Jaelre <drashna@live.com>

* Update keyboards/crkbd/keymaps/rpbaptist/rules.mk

Co-Authored-By: Drashna Jaelre <drashna@live.com>

* Update keyboards/crkbd/keymaps/rpbaptist/keymap.c

Co-Authored-By: fauxpark <fauxpark@gmail.com>

* Remove redundant config

* Remove disabling of NO_ACTION_MACRO and NO_ACTION_FUNCTION

* Remove layer keycode macros

* Use layer_state_t instead of uint32_t

Co-Authored-By: Drashna Jaelre <drashna@live.com>

* Use get_highest_layer instead of biton32

Co-Authored-By: Drashna Jaelre <drashna@live.com>

* OLED_ROTATION_90 instead of 180

Co-Authored-By: Drashna Jaelre <drashna@live.com>

* Use get_highest_layer instead of biton32

Co-Authored-By: Drashna Jaelre <drashna@live.com>

* Use get_highest_layer instead of biton32

Co-Authored-By: Drashna Jaelre <drashna@live.com>

* Revert "OLED_ROTATION_90 instead of 180"

This reverts commit f14a4353ab6719c6e4e8974a4d17f8b91940de56.

It messed up the logo on slave

* Use IS_LED_ON function to check LED status

Co-Authored-By: fauxpark <fauxpark@gmail.com>
This commit is contained in:
Richard Baptist 2019-10-02 18:39:43 +02:00 committed by Drashna Jaelre
parent fa8359fa1a
commit 482ec79e59
5 changed files with 677 additions and 0 deletions

View File

@ -0,0 +1,112 @@
/*
This is the c configuration file for the keymap
Copyright 2012 Jun Wako <wakojun@gmail.com>
Copyright 2015 Jack Humbert
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
//#define USE_MATRIX_I2C
/* Select hand configuration */
#define EE_HANDS
#undef SSD1306OLED
#define USE_SERIAL_PD2
#define FORCE_NKRO
#define QMK_ESC_OUTPUT F4 // usually COL
#define QMK_ESC_INPUT D4 // usually ROW
#define QMK_LED B0
#ifdef RGB_MATRIX_ENABLE
#define RGB_DISABLE_WHEN_USB_SUSPENDED true // turn off effects when suspended
#define RGB_MATRIX_MAXIMUM_BRIGHTNESS 150
#define RGB_MATRIX_HUE_STEP 10
#define RGB_MATRIX_SAT_STEP 15
#define RGB_MATRIX_VAL_STEP 16
#define RGB_MATRIX_SPD_STEP 10
#define DISABLE_RGB_MATRIX_ALPHAS_MODS
#define DISABLE_RGB_MATRIX_GRADIENT_UP_DOWN
#define DISABLE_RGB_MATRIX_BREATHING
#define DISABLE_RGB_MATRIX_BAND_SAT
#define DISABLE_RGB_MATRIX_BAND_VAL
#define DISABLE_RGB_MATRIX_BAND_PINWHEEL_SAT
#define DISABLE_RGB_MATRIX_BAND_PINWHEEL_VAL
#define DISABLE_RGB_MATRIX_BAND_SPIRAL_SAT
#define DISABLE_RGB_MATRIX_BAND_SPIRAL_VAL
// #define DISABLE_RGB_MATRIX_CYCLE_ALL
#define DISABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT
#define DISABLE_RGB_MATRIX_CYCLE_UP_DOWN
#define DISABLE_RGB_MATRIX_CYCLE_OUT_IN
#define DISABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL
#define DISABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON
#define DISABLE_RGB_MATRIX_CYCLE_PINWHEEL
#define DISABLE_RGB_MATRIX_CYCLE_SPIRAL
// #define DISABLE_RGB_MATRIX_DUAL_BEACON
#define DISABLE_RGB_MATRIX_RAINBOW_BEACON
#define DISABLE_RGB_MATRIX_RAINBOW_PINWHEELS
#define DISABLE_RGB_MATRIX_RAINDROPS
#define DISABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS
#define RGB_MATRIX_FRAMEBUFFER_EFFECTS
// #define DISABLE_RGB_MATRIX_TYPING_HEATMAP
#define DISABLE_RGB_MATRIX_DIGITAL_RAIN
#define RGB_MATRIX_KEYPRESSES // reacts to keypresses
#define DISABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
#define DISABLE_RGB_MATRIX_SOLID_REACTIVE
#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 RGB_MATRIX_STARTUP_MODE RGB_MATRIX_TYPING_HEATMAP
#endif
#define TAPPING_TERM 150
// #define PERMISSIVE_HOLD
#define IGNORE_MOD_TAP_INTERRUPT
// #define RETRO_TAPPING
#define TAPPING_TOGGLE 2
#define MOUSEKEY_DELAY 0
#define MOUSEKEY_INTERVAL 16
#define MOUSEKEY_MAX_SPEED 6
#define MOUSEKEY_TIME_TO_MAX 32
#define MOUSEKEY_WHEEL_MAX_SPEED 4
#define MOUSEKEY_WHEEL_TIME_TO_MAX 40
#define OLED_FONT_H "keyboards/crkbd/keymaps/rpbaptist/glcdfont.c"
#define NO_ACTION_ONESHOT
#undef PRODUCT
#define PRODUCT Corne Keyboard

View File

@ -0,0 +1,240 @@
#pragma once
#ifdef __AVR__
#include <avr/io.h>
#include <avr/pgmspace.h>
#elif defined(ESP8266)
#include <pgmspace.h>
#else
#define PROGMEM
#endif
// Helidox 8x6 font with QMK Firmware Logo
// Online editor: http://teripom.x0.com/
const unsigned char font[] PROGMEM = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x3E, 0x5B, 0x4F, 0x5B, 0x3E, 0x00,
0x3E, 0x6B, 0x4F, 0x6B, 0x3E, 0x00,
0x1C, 0x3E, 0x7C, 0x3E, 0x1C, 0x00,
0x18, 0x3C, 0x7E, 0x3C, 0x18, 0x00,
0x1C, 0x57, 0x7D, 0x57, 0x1C, 0x00,
0x1C, 0x5E, 0x7F, 0x5E, 0x1C, 0x00,
0x00, 0x18, 0x3C, 0x18, 0x00, 0x00,
0xFF, 0xE7, 0xC3, 0xE7, 0xFF, 0x00,
0x00, 0x18, 0x24, 0x18, 0x00, 0x00,
0xFF, 0xE7, 0xDB, 0xE7, 0xFF, 0x00,
0x30, 0x48, 0x3A, 0x06, 0x0E, 0x00,
0x26, 0x29, 0x79, 0x29, 0x26, 0x00,
0x40, 0x7F, 0x05, 0x05, 0x07, 0x00,
0x40, 0x7F, 0x05, 0x25, 0x3F, 0x00,
0x5A, 0x3C, 0xE7, 0x3C, 0x5A, 0x00,
0x7F, 0x3E, 0x1C, 0x1C, 0x08, 0x00,
0x08, 0x1C, 0x1C, 0x3E, 0x7F, 0x00,
0x14, 0x22, 0x7F, 0x22, 0x14, 0x00,
0x5F, 0x5F, 0x00, 0x5F, 0x5F, 0x00,
0x06, 0x09, 0x7F, 0x01, 0x7F, 0x00,
0x00, 0x66, 0x89, 0x95, 0x6A, 0x00,
0x60, 0x60, 0x60, 0x60, 0x60, 0x00,
0x94, 0xA2, 0xFF, 0xA2, 0x94, 0x00,
0x08, 0x04, 0x7E, 0x04, 0x08, 0x00,
0x10, 0x20, 0x7E, 0x20, 0x10, 0x00,
0x08, 0x08, 0x2A, 0x1C, 0x08, 0x00,
0x08, 0x1C, 0x2A, 0x08, 0x08, 0x00,
0x1E, 0x10, 0x10, 0x10, 0x10, 0x00,
0x0C, 0x1E, 0x0C, 0x1E, 0x0C, 0x00,
0x30, 0x38, 0x3E, 0x38, 0x30, 0x00,
0x06, 0x0E, 0x3E, 0x0E, 0x06, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x5F, 0x00, 0x00, 0x00,
0x00, 0x07, 0x00, 0x07, 0x00, 0x00,
0x14, 0x7F, 0x14, 0x7F, 0x14, 0x00,
0x24, 0x2A, 0x7F, 0x2A, 0x12, 0x00,
0x23, 0x13, 0x08, 0x64, 0x62, 0x00,
0x36, 0x49, 0x56, 0x20, 0x50, 0x00,
0x00, 0x08, 0x07, 0x03, 0x00, 0x00,
0x00, 0x1C, 0x22, 0x41, 0x00, 0x00,
0x00, 0x41, 0x22, 0x1C, 0x00, 0x00,
0x2A, 0x1C, 0x7F, 0x1C, 0x2A, 0x00,
0x08, 0x08, 0x3E, 0x08, 0x08, 0x00,
0x00, 0x80, 0x70, 0x30, 0x00, 0x00,
0x08, 0x08, 0x08, 0x08, 0x08, 0x00,
0x00, 0x00, 0x60, 0x60, 0x00, 0x00,
0x20, 0x10, 0x08, 0x04, 0x02, 0x00,
0x3E, 0x51, 0x49, 0x45, 0x3E, 0x00,
0x00, 0x42, 0x7F, 0x40, 0x00, 0x00,
0x72, 0x49, 0x49, 0x49, 0x46, 0x00,
0x21, 0x41, 0x49, 0x4D, 0x33, 0x00,
0x18, 0x14, 0x12, 0x7F, 0x10, 0x00,
0x27, 0x45, 0x45, 0x45, 0x39, 0x00,
0x3C, 0x4A, 0x49, 0x49, 0x31, 0x00,
0x41, 0x21, 0x11, 0x09, 0x07, 0x00,
0x36, 0x49, 0x49, 0x49, 0x36, 0x00,
0x46, 0x49, 0x49, 0x29, 0x1E, 0x00,
0x00, 0x00, 0x14, 0x00, 0x00, 0x00,
0x00, 0x40, 0x34, 0x00, 0x00, 0x00,
0x00, 0x08, 0x14, 0x22, 0x41, 0x00,
0x14, 0x14, 0x14, 0x14, 0x14, 0x00,
0x00, 0x41, 0x22, 0x14, 0x08, 0x00,
0x02, 0x01, 0x59, 0x09, 0x06, 0x00,
0x3E, 0x41, 0x5D, 0x59, 0x4E, 0x00,
0x7C, 0x12, 0x11, 0x12, 0x7C, 0x00,
0x7F, 0x49, 0x49, 0x49, 0x36, 0x00,
0x3E, 0x41, 0x41, 0x41, 0x22, 0x00,
0x7F, 0x41, 0x41, 0x41, 0x3E, 0x00,
0x7F, 0x49, 0x49, 0x49, 0x41, 0x00,
0x7F, 0x09, 0x09, 0x09, 0x01, 0x00,
0x3E, 0x41, 0x41, 0x51, 0x73, 0x00,
0x7F, 0x08, 0x08, 0x08, 0x7F, 0x00,
0x00, 0x41, 0x7F, 0x41, 0x00, 0x00,
0x20, 0x40, 0x41, 0x3F, 0x01, 0x00,
0x7F, 0x08, 0x14, 0x22, 0x41, 0x00,
0x7F, 0x40, 0x40, 0x40, 0x40, 0x00,
0x7F, 0x02, 0x1C, 0x02, 0x7F, 0x00,
0x7F, 0x04, 0x08, 0x10, 0x7F, 0x00,
0x3E, 0x41, 0x41, 0x41, 0x3E, 0x00,
0x7F, 0x09, 0x09, 0x09, 0x06, 0x00,
0x3E, 0x41, 0x51, 0x21, 0x5E, 0x00,
0x7F, 0x09, 0x19, 0x29, 0x46, 0x00,
0x26, 0x49, 0x49, 0x49, 0x32, 0x00,
0x03, 0x01, 0x7F, 0x01, 0x03, 0x00,
0x3F, 0x40, 0x40, 0x40, 0x3F, 0x00,
0x1F, 0x20, 0x40, 0x20, 0x1F, 0x00,
0x3F, 0x40, 0x38, 0x40, 0x3F, 0x00,
0x63, 0x14, 0x08, 0x14, 0x63, 0x00,
0x03, 0x04, 0x78, 0x04, 0x03, 0x00,
0x61, 0x59, 0x49, 0x4D, 0x43, 0x00,
0x00, 0x7F, 0x41, 0x41, 0x41, 0x00,
0x02, 0x04, 0x08, 0x10, 0x20, 0x00,
0x00, 0x41, 0x41, 0x41, 0x7F, 0x00,
0x04, 0x02, 0x01, 0x02, 0x04, 0x00,
0x40, 0x40, 0x40, 0x40, 0x40, 0x00,
0x00, 0x03, 0x07, 0x08, 0x00, 0x00,
0x20, 0x54, 0x54, 0x78, 0x40, 0x00,
0x7F, 0x28, 0x44, 0x44, 0x38, 0x00,
0x38, 0x44, 0x44, 0x44, 0x28, 0x00,
0x38, 0x44, 0x44, 0x28, 0x7F, 0x00,
0x38, 0x54, 0x54, 0x54, 0x18, 0x00,
0x00, 0x08, 0x7E, 0x09, 0x02, 0x00,
0x18, 0x24, 0x24, 0x1C, 0x78, 0x00,
0x7F, 0x08, 0x04, 0x04, 0x78, 0x00,
0x00, 0x44, 0x7D, 0x40, 0x00, 0x00,
0x20, 0x40, 0x40, 0x3D, 0x00, 0x00,
0x7F, 0x10, 0x28, 0x44, 0x00, 0x00,
0x00, 0x41, 0x7F, 0x40, 0x00, 0x00,
0x7C, 0x04, 0x78, 0x04, 0x78, 0x00,
0x7C, 0x08, 0x04, 0x04, 0x78, 0x00,
0x38, 0x44, 0x44, 0x44, 0x38, 0x00,
0x7C, 0x18, 0x24, 0x24, 0x18, 0x00,
0x18, 0x24, 0x24, 0x18, 0x7C, 0x00,
0x7C, 0x08, 0x04, 0x04, 0x08, 0x00,
0x48, 0x54, 0x54, 0x54, 0x24, 0x00,
0x04, 0x04, 0x3F, 0x44, 0x24, 0x00,
0x3C, 0x40, 0x40, 0x20, 0x7C, 0x00,
0x1C, 0x20, 0x40, 0x20, 0x1C, 0x00,
0x3C, 0x40, 0x30, 0x40, 0x3C, 0x00,
0x44, 0x28, 0x10, 0x28, 0x44, 0x00,
0x4C, 0x90, 0x90, 0x90, 0x7C, 0x00,
0x44, 0x64, 0x54, 0x4C, 0x44, 0x00,
0x00, 0x08, 0x36, 0x41, 0x00, 0x00,
0x00, 0x00, 0x77, 0x00, 0x00, 0x00,
0x00, 0x41, 0x36, 0x08, 0x00, 0x00,
0x02, 0x01, 0x02, 0x04, 0x02, 0x00,
0x3C, 0x26, 0x23, 0x26, 0x3C, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0xE0,
0x38, 0x1C, 0x0C, 0x06, 0x03, 0x03,
0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
0x03, 0x03, 0x82, 0x86, 0xCC, 0xF8,
0xF0, 0xF0, 0x38, 0x1C, 0x0C, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0xC0, 0x70,
0xF8, 0x0C, 0x04, 0xC6, 0xA2, 0xB3,
0x9F, 0x87, 0x01, 0x01, 0x1F, 0x66,
0x66, 0x44, 0x4C, 0x58, 0x70, 0xE0,
0x80, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0xC0,
0xE0, 0x78, 0x18, 0x8C, 0xC6, 0xE6,
0xE3, 0xE3, 0xC3, 0x83, 0x03, 0x03,
0x73, 0x76, 0x76, 0x0C, 0x18, 0xF8,
0xF0, 0xC0, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0xE0, 0xF0, 0xF0, 0xF0, 0xE0, 0xEC,
0xEE, 0xF7, 0xF3, 0x70, 0x20, 0x00,
0x7C, 0x7C, 0x7C, 0x7E, 0x00, 0x7E,
0x7E, 0x7E, 0x7F, 0x7F, 0x7F, 0x00,
0x00, 0x80, 0xC0, 0xE0, 0x7E, 0x5B,
0x4F, 0x5B, 0xFE, 0xC0, 0x00, 0x00,
0xC0, 0x00, 0xDC, 0xD7, 0xDE, 0xDE,
0xDE, 0xD7, 0xDC, 0x00, 0xC0, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x80, 0xC0, 0x40, 0x7F, 0xF3,
0x60, 0x20, 0x30, 0x30, 0x38, 0x18,
0x9C, 0xCC, 0x6C, 0x6E, 0x3E, 0x3E,
0x1F, 0x0F, 0x0F, 0x03, 0x03, 0x01,
0xC0, 0xFF, 0x3E, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x7F, 0xC1, 0x00,
0x1D, 0x67, 0xC0, 0x80, 0x01, 0x00,
0x00, 0xF0, 0x0F, 0x00, 0x00, 0x00,
0x0C, 0x1A, 0x32, 0xC2, 0x01, 0xC1,
0xFF, 0x3E, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x7E, 0xFF,
0x80, 0x00, 0x00, 0xC3, 0xC7, 0xC7,
0x8F, 0x0F, 0x07, 0x03, 0x80, 0xC0,
0xC0, 0xC0, 0xC0, 0x80, 0x00, 0x07,
0x0F, 0xFF, 0x7F, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x0F, 0x1F, 0x3F, 0x7F, 0x7F, 0x7F,
0x7F, 0x7F, 0x3F, 0x1E, 0x0C, 0x00,
0x1F, 0x1F, 0x1F, 0x3F, 0x00, 0x3F,
0x3F, 0x3F, 0x7F, 0x7F, 0x7F, 0x00,
0x30, 0x7B, 0x7F, 0x78, 0x30, 0x20,
0x20, 0x30, 0x78, 0x7F, 0x3B, 0x00,
0x03, 0x00, 0x0F, 0x7F, 0x0F, 0x0F,
0x0F, 0x7F, 0x0F, 0x00, 0x03, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x01, 0x01, 0x00, 0x40, 0x60, 0x31,
0x3B, 0x1E, 0x0C, 0x1E, 0x36, 0x23,
0x61, 0x60, 0x60, 0x60, 0x60, 0x60,
0x60, 0x30, 0x1C, 0x3E, 0x3E, 0x3F,
0x1D, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x01, 0x07,
0x0C, 0x18, 0x10, 0x33, 0x3E, 0x38,
0x6E, 0x67, 0x60, 0x60, 0x60, 0x20,
0x30, 0x18, 0x08, 0x0F, 0x06, 0x03,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x01,
0x03, 0x06, 0x0C, 0x19, 0x31, 0x21,
0x60, 0x60, 0x60, 0x60, 0x61, 0x63,
0x67, 0x67, 0x33, 0x39, 0x18, 0x0E,
0x07, 0x03, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};

View File

@ -0,0 +1,234 @@
#include QMK_KEYBOARD_H
extern uint8_t is_master;
enum layer_names {
_COLEMAKDHM,
_GAMING,
_GAMING_EXT,
_NUM,
_FN,
_NAV,
_UTIL
};
// Base layers
#define COLEMAK DF(_COLEMAKDHM)
#define GAMING DF(_GAMING)
// Layer toggle and switch
#define T_NAV TT(_NAV)
#define S_NAV MO(_NAV)
#define T_NUM TT(_NUM)
#define S_NUM MO(_NUM)
// Layer keys with functionality on tap
#define FN_TAB LT(_FN, KC_TAB)
#define NAV_0 LT(_NAV, KC_0)
#define EXT_SF LT(_GAMING_EXT, KC_LSHIFT)
// Tap/mod keys
#define RCTBR RCTL_T(KC_RBRACKET)
#define LCTBR LCTL_T(KC_LBRACKET)
#define SFSPC LSFT_T(KC_SPACE)
#define SFENT LSFT_T(KC_ENTER)
// Global tab forward and backward
#define TBFWD LCTL(KC_TAB)
#define TBBCK LCTL(LSFT(KC_TAB))
// Custom key for NUM layer
#define CTEQL RCTL_T(KC_EQL)
// €
#define KC_EUR ALGR(KC_5)
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_COLEMAKDHM] = LAYOUT( \
//,-----------------------------------------------------. ,-----------------------------------------------------.
KC_ESC, KC_Q, KC_W, KC_F, KC_P, KC_B, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_BSPC,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
FN_TAB, KC_A, KC_R, KC_S, KC_T, KC_G, KC_M, KC_N, KC_E, KC_I, KC_O, KC_QUOT,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
LCTBR, KC_Z, KC_X, KC_C, KC_D, KC_V, KC_K, KC_H, KC_COMM, KC_DOT, KC_SLSH, RCTBR,\
//|--------+--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------|
KC_LALT, T_NUM, SFSPC, SFENT, T_NAV, KC_RGUI \
//`--------------------------' `--------------------------'
),
[_GAMING] = LAYOUT( \
//,-----------------------------------------------------. ,-----------------------------------------------------.
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
KC_TAB, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
KC_LCTL, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_RCTL,\
//|--------+--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------|
_______, EXT_SF, KC_SPC, _______, _______, _______ \
//`--------------------------' `--------------------------'
),
[_GAMING_EXT] = LAYOUT( \
//,-----------------------------------------------------. ,-----------------------------------------------------.
KC_GRV, KC_1, KC_2, _______, KC_3, KC_4, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_DEL,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
KC_LBRC, KC_RBRC, _______, _______, _______, KC_BSLS, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, _______,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_F11, KC_F12, KC_MINS, KC_EQL, _______, _______,\
//|--------+--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, KC_ENT, _______, _______ \
//`--------------------------' `--------------------------'
),
[_FN] = LAYOUT( \
//,-----------------------------------------------------. ,-----------------------------------------------------.
KC_F12, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
_______, XXXXXXX, XXXXXXX, XXXXXXX, KC_CAPS, KC_NLCK, XXXXXXX, KC_MINS, KC_PIPE, KC_BSLS, KC_PLUS, XXXXXXX,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
_______, XXXXXXX, KC_PAUS, KC_SLCK, KC_PSCR, KC_INS, XXXXXXX, KC_UNDS, KC_LT, KC_GT, KC_EQL, _______,\
//|--------+--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, _______, _______, _______ \
//`--------------------------' `--------------------------'
),
[_NUM] = LAYOUT( \
//,-----------------------------------------------------. ,-----------------------------------------------------.
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, _______,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_SLSH, KC_4, KC_5, KC_6, KC_MINS, KC_PLUS,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
_______, KC_CIRC, KC_AMPR, KC_EUR, KC_LPRN, KC_RPRN, KC_ASTR, KC_1, KC_2, KC_3, KC_UNDS, CTEQL,\
//|--------+--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------|
_______, S_NUM, _______, _______, NAV_0, KC_DOT \
//`--------------------------' `--------------------------'
),
[_NAV] = LAYOUT( \
//,-----------------------------------------------------. ,-----------------------------------------------------.
_______, KC_WH_U, TBBCK, KC_MS_U, TBFWD, KC_BTN2, KC_PGUP, KC_HOME, KC_UP, KC_END, XXXXXXX, KC_DEL,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
KC_TAB, KC_WH_D, KC_MS_L, KC_MS_D, KC_MS_R, KC_BTN1, KC_PGDN, KC_LEFT, KC_DOWN, KC_RGHT, XXXXXXX, XXXXXXX,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
_______, XXXXXXX, KC_WH_L, XXXXXXX, KC_WH_R, XXXXXXX, XXXXXXX, KC_ACL0, KC_ACL1, KC_ACL2, XXXXXXX, _______,\
//|--------+--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+-------+---------|
_______, _______, _______, _______, S_NAV, _______ \
//`--------------------------' `--------------------------'
),
[_UTIL] = LAYOUT( \
//,-----------------------------------------------------. ,-----------------------------------------------------.
RESET, XXXXXXX, KC_MSTP, KC_VOLU, KC_MNXT, XXXXXXX, COLEMAK, GAMING, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, KC_MPRV, KC_VOLD, KC_MPLY, XXXXXXX, XXXXXXX, RGB_MOD, RGB_SPI, RGB_HUI, RGB_SAI, RGB_VAI,\
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------|
XXXXXXX, KC_SLEP, XXXXXXX, KC_MUTE, XXXXXXX, XXXXXXX, RGB_TOG,RGB_RMOD, RGB_SPD, RGB_HUD, RGB_SAD, RGB_VAD,\
//|--------+--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, _______, _______, _______ \
//`--------------------------' `--------------------------'
)
};
layer_state_t layer_state_set_user(layer_state_t state) {
switch (get_highest_layer(default_layer_state)) {
case _COLEMAKDHM:
state = update_tri_layer_state(state, _NUM, _NAV, _UTIL);
break;
case _GAMING:
state = update_tri_layer_state(state, _GAMING_EXT, _NAV, _UTIL);
break;
}
return state;
}
#ifdef OLED_DRIVER_ENABLE
oled_rotation_t oled_init_user(oled_rotation_t rotation) {
if (is_master) {
return OLED_ROTATION_270;
} else {
return OLED_ROTATION_180;
}
}
void render_crkbd_logo(void) {
static const char PROGMEM crkbd_logo[] = {
0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, 0x90, 0x91, 0x92, 0x93, 0x94,
0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4,
0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4,
0};
oled_write_P(crkbd_logo, false);
}
void render_status(void) {
// oled_write_P(PSTR("Layout: "), false);
switch (get_highest_layer(default_layer_state)) {
case _COLEMAKDHM:
oled_write_P(PSTR("CLMK "), false);
break;
case _GAMING:
oled_write_P(PSTR("GAME "), false);
break;
}
oled_write_P(PSTR("\n"), false);
switch (get_highest_layer(layer_state)) {
case 0:
oled_write_P(PSTR(" "), false);
break;
case _NUM:
oled_write_P(PSTR("Comm "), false);
break;
case _FN:
oled_write_P(PSTR("Stage"), false);
break;
case _NAV:
oled_write_P(PSTR("Fuel "), false);
break;
case _GAMING_EXT:
oled_write_P(PSTR("Ext "), false);
break;
case _UTIL:
oled_write_P(PSTR("Util "), false);
break;
default:
oled_write_P(PSTR("Unkn "), false);
break;
}
oled_write_P(PSTR("\n"), false);
uint8_t modifiers = get_mods();
oled_write_P( (modifiers & MOD_MASK_CTRL) ? PSTR("PROG ") : PSTR(" "), false);
oled_write_P( (modifiers & MOD_MASK_SHIFT) ? PSTR("PULSE") : PSTR(" "), false);
oled_write_P( (modifiers & MOD_MASK_ALT) ? PSTR("STBY ") : PSTR(" "), false);
oled_write_P( (modifiers & MOD_MASK_GUI) ? PSTR("GYRO ") : PSTR(" "), false);
oled_write_P(PSTR("\n"), false);
uint8_t led_usb_state = host_keyboard_leds();
oled_write_P(PSTR("Mode:\n"), false);
oled_write_P(IS_LED_ON(led_usb_state, USB_LED_NUM_LOCK) ? PSTR(" NUM ") : PSTR(" "), false);
oled_write_P(IS_LED_ON(led_usb_state, USB_LED_CAPS_LOCK) ? PSTR(" CAPS") : PSTR(" "), false);
oled_write_P(IS_LED_ON(led_usb_state, USB_LED_SCROLL_LOCK) ? PSTR(" SCRL") : PSTR(" "), false);
}
void oled_task_user(void) {
if (is_master) {
render_status(); // Renders the current keyboard state (layer, lock, caps, scroll, etc)
} else {
render_crkbd_logo();
// oled_scroll_left(); // Turns on scrolling
}
}
#endif
void suspend_power_down_keymap(void) {
rgb_matrix_set_suspend_state(true);
}
void suspend_wakeup_init_keymap(void) {
rgb_matrix_set_suspend_state(false);
}

View File

@ -0,0 +1,57 @@
# Corne keyboard layout
This is my highly personalized CRKBD layout. I use Colemak DHm as main typing layer. I use this keyboard and layout in my daily programming job and for everything at home, including gaming.
This keymap is the result of an evolution from Ultimate Hacking Keyboard to Iris, to Corne. It took many iterations and changes and only now I feel this is ready to be merged into the main QMK repository, because I think further changes will be minor. This is my 1.0 release so to speak.
Many thanks to foostan for the keyboard, all QMK contributors and drashna specifically for his work on this keyboard.
## Layers
### COLEMAKDHM
Main typing layer. I really love having SHIFT available on thumbs. I am a left thumb space bar person, so I put SPACE there and ENTER on right. I use CTRL key combos lot in my text editor and desktop environment. That's why I have two of them. I also found them to be a great position for the square brackets. (`[` and `]`)
I don't know about you but "lower" and "raise" don't mean that much to me. I named my layers `NUM`, short for numbers and `NAV`, short for navigation. Holding the key will activate the layer for as long as it is held, double tapping it will switch to it. Single tapping it once will switch to main layer again.
Everything else is pretty standard I'd say.
### NUM
Includes a number row, the symbols normally on SHIFT and numbers, as well as a numpad under right side homing keys.
### NAV
This is where I access arrow keys, page up, down, home, end and mouse control. I also added general tab forward and backward keys. I use these in my browser, terminal and text editor.
## FN
Short for function. This gives access to the function keys, as well as rarely used keys on the left side and often used symbols (for me) on the right side. It is accessed by holding TAB.
### UTIL
Short for utility. This is accessed by pressing both `NUM` and `NAV` at the same time. It has a software `RESET` key, media keys, RGB control and switches main layer between Colemak and a gaming layer.
### GAMING
Sometimes I switch to type in Discord, Steam, or in game chat, so I think it's more important to keep typing functional than put WASD on where I want movement to be. This means I rebind my keys in all games. It's worth it to me.
I put movement on FRST (would be ESDF on QWERTY), because it lines up more comfortably with the columnar staggered layout of the Corne. It also gives more easy access to all keys on left half.
Most notable here is that there are no tap and hold differences anymore on left hand side besides the new layer key. This is a different layer than `NUM`.
### GAMING_EXT
This is the gaming extended layer where movement keys remain the same. This means I can keep moving while accessing second layer keys. All other keys are keys on which I can easily rebind something. Besides that it gives me the function keys and an ENTER key which does not change. This is good when a game requires you to hold ENTER.
## Notes
I use MT3 Godspeed caps and thought it would be fun to theme the OLED output towards it. The slave side has the icon and two planets. The left side refers to modifiers by matching the novelty mod legends.
## Building
I am using DFU and have to flash both halves individually.
Left half: `make crkbd/rev1:rpbaptist:dfu-split-left`
Right half: `make crkbd/rev1:rpbaptist:dfu-split-right RGB_MATRIX_SPLIT_RIGHT=yes`

View File

@ -0,0 +1,34 @@
# This enables Link Time Optimization. This can save a good chunk of space (several KB for me), but the macro and function ... functions cause it to error out.
LINK_TIME_OPTIMIZATION_ENABLE = yes
# Build Options
# change to "no" to disable the options, or define them in the Makefile in
# the appropriate keymap folder that will get included automatically
#
MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
NKRO_ENABLE = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight.
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
CONSOLE_ENABLE = no # Console for debug(+400)
COMMAND_ENABLE = no # Commands for debug and configuration
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
MIDI_ENABLE = no # MIDI controls
AUDIO_ENABLE = no # Audio output on port C6
UNICODE_ENABLE = no # Unicode
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
SWAP_HANDS_ENABLE = no # Enable one-hand typing
RGB_MATRIX_ENABLE = WS2812
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
BOOTLOADER = qmk-dfu
OLED_DRIVER_ENABLE = yes
# ifneq ($(strip $(OLED_DRIVER_ENABLE)), yes)
# RGB_MATRIX_SPLIT_RIGHT=yes
# endif