From 40b0ddd425bf09ddbb15a414b5147e98256f10a8 Mon Sep 17 00:00:00 2001 From: XScorpion2 Date: Mon, 22 Jul 2019 12:43:52 -0500 Subject: Sol Rev 2 Keyboard (#6389) * Basic Rev 2 implementation * Updated LED defines and added Extra encoder support * Fixed rgb pin assignment * Physically accurate LED positions * Single Color Band scrolling left to right effects * Spirals, Pinwheels, and Documentation....Oh My! * Spiral effect band thickness adjustments * Fixing animation spin directions * Full hand LED positions * Basic Rev 2 implementation Updated LED defines and added Extra encoder support Fixed rgb pin assignment Physically accurate LED positions Full hand LED positions Moving rev2 folder * RGB Center Point LED position update * Fixing led config commas * Fixing led config commas * fix enter key * fix enter * Small changes to default * update default * typo fix * update default * Fixing defines & led config, turned full hand & extra encoders into rules.mk feature * Refactored rules.mk to have a post_rules.mk * Forgot to offset the matrix to led map due to the edge led additions * Updated LED flags and fixed my keymap * Update keymap.c include speed controls for RGB * Fixing more rules.mk and adding keymap like encoders functionality * Sol Rev 2 Implementation * Minor fixes * Keymap fixes * Fix Colemak, add lock keys --- keyboards/rgbkb/sol/rev1/config.h | 7 +++++++ keyboards/rgbkb/sol/rev1/post_rules.mk | 19 +++++++++++++++++++ keyboards/rgbkb/sol/rev1/rev1.c | 24 ++++++++++++------------ keyboards/rgbkb/sol/rev1/rules.mk | 28 ++++++++++++++++++++++++++++ 4 files changed, 66 insertions(+), 12 deletions(-) create mode 100644 keyboards/rgbkb/sol/rev1/post_rules.mk (limited to 'keyboards/rgbkb/sol/rev1') diff --git a/keyboards/rgbkb/sol/rev1/config.h b/keyboards/rgbkb/sol/rev1/config.h index 51c4bbb65b..3cfc3eef94 100644 --- a/keyboards/rgbkb/sol/rev1/config.h +++ b/keyboards/rgbkb/sol/rev1/config.h @@ -26,6 +26,9 @@ along with this program. If not, see . #define PRODUCT Sol #define DESCRIPTION "An RGB, split, ortho-esque keyboard" +/* ws2812 RGB LED */ +#define RGB_DI_PIN B3 + #ifdef LED_MIRRORED #define RGBLED_NUM 35 #else @@ -34,3 +37,7 @@ along with this program. If not, see . #define DRIVER_LED_TOTAL RGBLED_NUM #define RGB_MATRIX_CENTER { 112, 35 } + +// Encoder support +#define ENCODERS_PAD_A { D2 } +#define ENCODERS_PAD_B { D6 } diff --git a/keyboards/rgbkb/sol/rev1/post_rules.mk b/keyboards/rgbkb/sol/rev1/post_rules.mk new file mode 100644 index 0000000000..ede37a1ad7 --- /dev/null +++ b/keyboards/rgbkb/sol/rev1/post_rules.mk @@ -0,0 +1,19 @@ +# As long as the users rules.mk has include $(KEYBOARD)/post_rules.mk this will be run after to properly setup any keyboard features and defines + +ifeq ($(strip $(IOS_DEVICE_ENABLE)), yes) + OPT_DEFS += -DIOS_DEVICE_ENABLE +else ifeq ($(strip $(RGBLIGHT_FULL_POWER)), yes) + OPT_DEFS += -DRGBLIGHT_FULL_POWER +endif + +ifeq ($(strip $(RGB_MATRIX_KEYPRESSES)), yes) + OPT_DEFS += -DRGB_MATRIX_KEYPRESSES +endif + +ifeq ($(strip $(RGB_MATRIX_FRAMEBUFFER)), yes) + OPT_DEFS += -DRGB_MATRIX_FRAMEBUFFER_EFFECTS +endif + +ifeq ($(strip $(LED_MIRRORED)), yes) + OPT_DEFS += -DLED_MIRRORED +endif diff --git a/keyboards/rgbkb/sol/rev1/rev1.c b/keyboards/rgbkb/sol/rev1/rev1.c index 6ee4b610b3..21b4503ab9 100644 --- a/keyboards/rgbkb/sol/rev1/rev1.c +++ b/keyboards/rgbkb/sol/rev1/rev1.c @@ -2,18 +2,18 @@ #ifdef RGB_MATRIX_ENABLE led_config_t g_led_config = { { - { 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 }, - { NO_LED, NO_LED, NO_LED, NO_LED, NO_LED, 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, 68 }, - { NO_LED, NO_LED, NO_LED, NO_LED, NO_LED, 68, 68 } + { 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 }, + { NO_LED, NO_LED, NO_LED, NO_LED, NO_LED, 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, 68 }, + { NO_LED, NO_LED, NO_LED, NO_LED, NO_LED, 68, 68 } }, { // Left Hand Mapped Left to Right { 0, 0 }, { 21, 0 }, { 38, 0 }, { 56, 0 }, { 73, 0 }, { 91, 0 }, { 112, 0 }, diff --git a/keyboards/rgbkb/sol/rev1/rules.mk b/keyboards/rgbkb/sol/rev1/rules.mk index e69de29bb2..dd6d25eb98 100644 --- a/keyboards/rgbkb/sol/rev1/rules.mk +++ b/keyboards/rgbkb/sol/rev1/rules.mk @@ -0,0 +1,28 @@ +# RGBKB Sol Rev1 Defaults + +# Keycode Options +BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000) +MOUSEKEY_ENABLE = no # Mouse keys(+4700) +EXTRAKEY_ENABLE = yes # Audio control and System control(+450) +UNICODE_ENABLE = no # Unicode keycodes +NKRO_ENABLE = no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work + +# Debug Options +CONSOLE_ENABLE = no # Console for debug(+400) +COMMAND_ENABLE = no # Commands for debug and configuration + +# RGB Options +RGBLIGHT_ENABLE = yes # Enable global lighting effects. Do not enable with RGB Matrix +RGBLIGHT_ANIMATIONS = yes # LED animations +LED_MIRRORED = yes # Mirror LEDs across halves (enable DIP 1 on slave, and DIP 2 and 3 on master) + +RGB_MATRIX_ENABLE = no # Enable per-key coordinate based RGB effects. Do not enable with RGBlight +RGB_MATRIX_KEYPRESSES = no # Enable reactive per-key effects. +RGB_MATRIX_FRAMEBUFFER_EFFECTS = no # Enable frame buffer effects like the typing heatmap. + +RGBLIGHT_FULL_POWER = no # Allow maximum RGB brightness for RGBLIGHT or RGB_MATRIX. Otherwise, limited to a safe level for a normal USB-A port +IOS_DEVICE_ENABLE = no # Limit max brightness to connect to IOS device (iPad,iPhone) + +# Misc +OLED_DRIVER_ENABLE = no # Enable the OLED Driver +SWAP_HANDS_ENABLE = no # Enable one-hand typing -- cgit v1.2.1