summaryrefslogtreecommitdiff
path: root/keyboards/splitkb
diff options
context:
space:
mode:
authorDrashna Jaelre <drashna@live.com>2022-01-30 13:20:33 -0800
committerGitHub <noreply@github.com>2022-01-30 13:20:33 -0800
commit941b1d35b8e40a9c93301a1131ef3f3336fee0b5 (patch)
tree54c8d1ec131d5c8a6e0dd89364a9840b3925fcdd /keyboards/splitkb
parent3555ee0555c8a9ff8aea2a101ae02a72b0e76076 (diff)
downloadqmk_firmware-941b1d35b8e40a9c93301a1131ef3f3336fee0b5.tar.gz
qmk_firmware-941b1d35b8e40a9c93301a1131ef3f3336fee0b5.zip
[Keymap] Add oled improvements and cnano keymap for drashna (#16133)
Diffstat (limited to 'keyboards/splitkb')
-rw-r--r--keyboards/splitkb/kyria/keymaps/drashna/config.h13
-rw-r--r--keyboards/splitkb/kyria/keymaps/drashna/keymap.c27
-rw-r--r--keyboards/splitkb/kyria/keymaps/drashna/rules.mk2
3 files changed, 38 insertions, 4 deletions
diff --git a/keyboards/splitkb/kyria/keymaps/drashna/config.h b/keyboards/splitkb/kyria/keymaps/drashna/config.h
index 8239e28cdc..89a162a9b1 100644
--- a/keyboards/splitkb/kyria/keymaps/drashna/config.h
+++ b/keyboards/splitkb/kyria/keymaps/drashna/config.h
@@ -19,17 +19,21 @@
#define EE_HANDS
#ifdef OLED_ENABLE
-# define OLED_DISPLAY_128X64
+# ifdef OLED_DRIVER_SH1107
+# undef OLED_DISPLAY_128X64
+# define OLED_DISPLAY_128X128
+# endif
#endif
#ifdef RGBLIGHT_ENABLE
# define RGBLIGHT_SLEEP
-# define RGBLIGHT_LIMIT_VAL 200
+# undef RGBLIGHT_LIMIT_VAL
+# define RGBLIGHT_LIMIT_VAL 120
# define RGBLIGHT_HUE_STEP 8
# define RGBLIGHT_SAT_STEP 8
# define RGBLIGHT_VAL_STEP 8
# define RGBLIGHT_SPLIT
-// # define RGBLIGHT_LAYERS
+# define RGBLIGHT_LAYERS
#endif
#define KEYLOGGER_LENGTH 10
@@ -41,3 +45,6 @@
#define BOOTMAGIC_LITE_COLUMN 7
#define BOOTMAGIC_LITE_ROW_RIGHT 4
#define BOOTMAGIC_LITE_COLUMN_RIGHT 7
+
+#define I2C1_CLOCK_SPEED 400000
+#define I2C1_DUTY_CYCLE FAST_DUTY_CYCLE_2
diff --git a/keyboards/splitkb/kyria/keymaps/drashna/keymap.c b/keyboards/splitkb/kyria/keymaps/drashna/keymap.c
index 1346616b20..41ef4b2705 100644
--- a/keyboards/splitkb/kyria/keymaps/drashna/keymap.c
+++ b/keyboards/splitkb/kyria/keymaps/drashna/keymap.c
@@ -121,7 +121,32 @@ const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = {
// clang-format on
#ifdef OLED_ENABLE
-oled_rotation_t oled_init_keymap(oled_rotation_t rotation) { return OLED_ROTATION_180; }
+oled_rotation_t oled_init_keymap(oled_rotation_t rotation) {
+#ifdef OLED_DRIVER_SH1107
+ return OLED_ROTATION_0;
+#else
+ return OLED_ROTATION_180;
+#endif
+}
+
+void oled_render_large_display(void) {
+ if (is_keyboard_left()) {
+ render_wpm_graph(54, 64);
+ } else {
+ static const char PROGMEM kyria_logo[] = {
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,128,128,192,224,240,112,120, 56, 60, 28, 30, 14, 14, 14, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 14, 14, 14, 30, 28, 60, 56,120,112,240,224,192,128,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0,192,224,240,124, 62, 31, 15, 7, 3, 1,128,192,224,240,120, 56, 60, 28, 30, 14, 14, 7, 7,135,231,127, 31,255,255, 31,127,231,135, 7, 7, 14, 14, 30, 28, 60, 56,120,240,224,192,128, 1, 3, 7, 15, 31, 62,124,240,224,192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0,240,252,255, 31, 7, 1, 0, 0,192,240,252,254,255,247,243,177,176, 48, 48, 48, 48, 48, 48, 48,120,254,135, 1, 0, 0,255,255, 0, 0, 1,135,254,120, 48, 48, 48, 48, 48, 48, 48,176,177,243,247,255,254,252,240,192, 0, 0, 1, 7, 31,255,252,240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0,255,255,255, 0, 0, 0, 0, 0,254,255,255, 1, 1, 7, 30,120,225,129,131,131,134,134,140,140,152,152,177,183,254,248,224,255,255,224,248,254,183,177,152,152,140,140,134,134,131,131,129,225,120, 30, 7, 1, 1,255,255,254, 0, 0, 0, 0, 0,255,255,255, 0, 0, 0, 0,255,255, 0, 0,192,192, 48, 48, 0, 0,240,240, 0, 0, 0, 0, 0, 0,240,240, 0, 0,240,240,192,192, 48, 48, 48, 48,192,192, 0, 0, 48, 48,243,243, 0, 0, 0, 0, 0, 0, 48, 48, 48, 48, 48, 48,192,192, 0, 0, 0, 0, 0,
+ 0, 0, 0,255,255,255, 0, 0, 0, 0, 0,127,255,255,128,128,224,120, 30,135,129,193,193, 97, 97, 49, 49, 25, 25,141,237,127, 31, 7,255,255, 7, 31,127,237,141, 25, 25, 49, 49, 97, 97,193,193,129,135, 30,120,224,128,128,255,255,127, 0, 0, 0, 0, 0,255,255,255, 0, 0, 0, 0, 63, 63, 3, 3, 12, 12, 48, 48, 0, 0, 0, 0, 51, 51, 51, 51, 51, 51, 15, 15, 0, 0, 63, 63, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 48, 48, 63, 63, 48, 48, 0, 0, 12, 12, 51, 51, 51, 51, 51, 51, 63, 63, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 15, 63,255,248,224,128, 0, 0, 3, 15, 63,127,255,239,207,141, 13, 12, 12, 12, 12, 12, 12, 12, 30,127,225,128, 0, 0,255,255, 0, 0,128,225,127, 30, 12, 12, 12, 12, 12, 12, 12, 13,141,207,239,255,127, 63, 15, 3, 0, 0,128,224,248,255, 63, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 3, 7, 15, 62,124,248,240,224,192,128, 1, 3, 7, 15, 30, 28, 60, 56,120,112,112,224,224,225,231,254,248,255,255,248,254,231,225,224,224,112,112,120, 56, 60, 28, 30, 15, 7, 3, 1,128,192,224,240,248,124, 62, 15, 7, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 3, 7, 15, 14, 30, 28, 60, 56,120,112,112,112,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,112,112,112,120, 56, 60, 28, 30, 14, 15, 7, 3, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
+ };
+ // clang-format on
+ oled_write_raw_P(kyria_logo, sizeof(kyria_logo));
+ }
+}
#endif
#ifdef ENCODER_ENABLE
diff --git a/keyboards/splitkb/kyria/keymaps/drashna/rules.mk b/keyboards/splitkb/kyria/keymaps/drashna/rules.mk
index 3cdfe1becd..ddba0780a2 100644
--- a/keyboards/splitkb/kyria/keymaps/drashna/rules.mk
+++ b/keyboards/splitkb/kyria/keymaps/drashna/rules.mk
@@ -20,8 +20,10 @@ ifeq ($(strip $(KEYBOARD)), splitkb/kyria/rev1/proton_c)
CTPC = yes
AUTOCORRECTION_ENABLE = yes
CAPS_WORD_ENABLE = yes
+ DEBUG_MATRIX_SCAN_RATE_ENABLE = api
else
LTO_ENABLE = yes
BOOTLOADER = qmk-hid
BOOTLOADER_SIZE = 512
+ CUSTOM_UNICODE_ENABLE = no
endif