From fadb69e2031a259248dd575384da8846ba0c2aa3 Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Thu, 15 Aug 2019 22:01:34 +0100 Subject: Refactor of lets_split_eh to enable RGB split animations (#6411) --- keyboards/lets_split_eh/config.h | 8 +------- keyboards/lets_split_eh/eh/config.h | 18 ++++++++---------- keyboards/lets_split_eh/eh/eh.c | 13 ------------- keyboards/lets_split_eh/eh/eh.h | 5 +---- keyboards/lets_split_eh/eh/rules.mk | 2 +- keyboards/lets_split_eh/keymaps/default/keymap.c | 24 +++++++++++------------- keyboards/lets_split_eh/lets_split_eh.h | 5 +---- 7 files changed, 23 insertions(+), 52 deletions(-) (limited to 'keyboards/lets_split_eh') diff --git a/keyboards/lets_split_eh/config.h b/keyboards/lets_split_eh/config.h index 655d35e1ab..f07706a834 100644 --- a/keyboards/lets_split_eh/config.h +++ b/keyboards/lets_split_eh/config.h @@ -15,8 +15,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -#ifndef CONFIG_H -#define CONFIG_H +#pragma once #include "config_common.h" @@ -35,8 +34,3 @@ along with this program. If not, see . /* Set 0 if debouncing isn't needed */ #define DEBOUNCE 5 - -/* serial.c configuration for split keyboard */ -//#define SOFT_SERIAL_PIN D0 - -#endif diff --git a/keyboards/lets_split_eh/eh/config.h b/keyboards/lets_split_eh/eh/config.h index 59afb39c0f..43e0266502 100644 --- a/keyboards/lets_split_eh/eh/config.h +++ b/keyboards/lets_split_eh/eh/config.h @@ -16,13 +16,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . */ -#ifndef EH_CONFIG_H -#define EH_CONFIG_H - -// To let configuration know this is of type EH, which will force I2C irregardless of user config -#define EH -// The 'EH' only uses I2C -#define USE_I2C +#pragma once #include "config_common.h" @@ -40,10 +34,14 @@ along with this program. If not, see . /* ws2812 RGB LED */ #define RGB_DI_PIN B2 -#define RGBLED_NUM 6 // Number of LEDs (each hand) +#define RGBLED_NUM 12 // Number of LEDs (each hand) +#define RGBLED_SPLIT { 6, 6 } +#define RGBLIGHT_ANIMATIONS /* Split Defines */ #define SPLIT_HAND_PIN D3 +#define SOFT_SERIAL_PIN D0 -#endif - +// The 'EH' has previously forced use of I2C so this default has been kept +// however users can undef to use serial +#define USE_I2C diff --git a/keyboards/lets_split_eh/eh/eh.c b/keyboards/lets_split_eh/eh/eh.c index e748d3ae05..d5a312085d 100644 --- a/keyboards/lets_split_eh/eh/eh.c +++ b/keyboards/lets_split_eh/eh/eh.c @@ -1,14 +1 @@ #include "lets_split_eh.h" - -void matrix_init_kb(void) { - - // JTAG disable for PORT F. write JTD bit twice within four cycles. - MCUCR |= (1<