From e01b2d518a1a08ce07278ef9a38c7a793c843749 Mon Sep 17 00:00:00 2001 From: XScorpion2 Date: Mon, 6 May 2019 17:06:43 -0500 Subject: [Keyboard] Sol keyboard conversion to split common (#5773) * Split common conversion * Updated serial and encoder pins * Fixing default folder until r2 * Fixing oled driver on slave split common * Fixing keymap compile errors * Fixing oled inactivity timer on slave split common * Hoisted oled driver task, init, & activity to keyboard.c * Update keyboards/sol/config.h Co-Authored-By: XScorpion2 * Remove TAPPING_FORCE_HOLD --- quantum/quantum.c | 23 +++++------------------ quantum/split_common/matrix.c | 2 +- 2 files changed, 6 insertions(+), 19 deletions(-) (limited to 'quantum') diff --git a/quantum/quantum.c b/quantum/quantum.c index fcedf0bc18..d4fa7f2efc 100644 --- a/quantum/quantum.c +++ b/quantum/quantum.c @@ -247,12 +247,6 @@ bool process_record_quantum(keyrecord_t *record) { preprocess_tap_dance(keycode, record); #endif - #if defined(OLED_DRIVER_ENABLE) && !defined(OLED_DISABLE_TIMEOUT) - // Wake up oled if user is using those fabulous keys! - if (record->event.pressed) - oled_on(); - #endif - if (!( #if defined(KEY_LOCK_ENABLE) // Must run first to be able to mask key_up events. @@ -976,9 +970,6 @@ void matrix_init_quantum() { #ifdef OUTPUT_AUTO_ENABLE set_output(OUTPUT_AUTO); #endif - #ifdef OLED_DRIVER_ENABLE - oled_init(OLED_ROTATION_0); - #endif matrix_init_kb(); } @@ -1015,10 +1006,6 @@ void matrix_scan_quantum() { haptic_task(); #endif - #ifdef OLED_DRIVER_ENABLE - oled_task(); - #endif - matrix_scan_kb(); } #if defined(BACKLIGHT_ENABLE) && (defined(BACKLIGHT_PIN) || defined(BACKLIGHT_PINS)) @@ -1214,10 +1201,10 @@ void backlight_task(void) { // (which is not possible since the backlight is not wired to PWM pins on the // CPU), we do the LED on/off by oursleves. // The timer is setup to count up to 0xFFFF, and we set the Output Compare -// register to the current 16bits backlight level (after CIE correction). -// This means the CPU will trigger a compare match interrupt when the counter -// reaches the backlight level, where we turn off the LEDs, -// but also an overflow interrupt when the counter rolls back to 0, +// register to the current 16bits backlight level (after CIE correction). +// This means the CPU will trigger a compare match interrupt when the counter +// reaches the backlight level, where we turn off the LEDs, +// but also an overflow interrupt when the counter rolls back to 0, // in which we're going to turn on the LEDs. // The LED will then be on for OCRxx/0xFFFF time, adjusted every 244Hz. @@ -1229,7 +1216,7 @@ ISR(TIMERx_COMPA_vect) { } // Triggered when the counter reaches the TOP value -// this one triggers at F_CPU/65536 =~ 244 Hz +// this one triggers at F_CPU/65536 =~ 244 Hz ISR(TIMERx_OVF_vect) { #ifdef BACKLIGHT_BREATHING breathing_task(); diff --git a/quantum/split_common/matrix.c b/quantum/split_common/matrix.c index eb110bd23a..3c3daf3d3b 100644 --- a/quantum/split_common/matrix.c +++ b/quantum/split_common/matrix.c @@ -299,7 +299,7 @@ uint8_t _matrix_scan(void) { debounce(raw_matrix, matrix + thisHand, ROWS_PER_HAND, changed); - return 1; + return (uint8_t)changed; } uint8_t matrix_scan(void) { -- cgit v1.2.1