aboutsummaryrefslogtreecommitdiff
path: root/tmk_core/common/keyboard.c
diff options
context:
space:
mode:
Diffstat (limited to 'tmk_core/common/keyboard.c')
-rw-r--r--tmk_core/common/keyboard.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/tmk_core/common/keyboard.c b/tmk_core/common/keyboard.c
index 1bfd4c9cc..d22300116 100644
--- a/tmk_core/common/keyboard.c
+++ b/tmk_core/common/keyboard.c
@@ -18,7 +18,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
18#include <stdint.h> 18#include <stdint.h>
19#include "keyboard.h" 19#include "keyboard.h"
20#include "matrix.h" 20#include "matrix.h"
21#include "debounce.h"
22#include "keymap.h" 21#include "keymap.h"
23#include "host.h" 22#include "host.h"
24#include "led.h" 23#include "led.h"
@@ -164,8 +163,7 @@ bool is_keyboard_master(void) {
164 */ 163 */
165void keyboard_init(void) { 164void keyboard_init(void) {
166 timer_init(); 165 timer_init();
167 matrix_init(); 166 matrix_init();
168 matrix_debounce_init();
169#ifdef QWIIC_ENABLE 167#ifdef QWIIC_ENABLE
170 qwiic_init(); 168 qwiic_init();
171#endif 169#endif
@@ -225,12 +223,11 @@ void keyboard_task(void)
225 uint8_t keys_processed = 0; 223 uint8_t keys_processed = 0;
226#endif 224#endif
227 225
228 matrix_scan(); 226 matrix_scan();
229 matrix_debounce();
230 227
231 if (is_keyboard_master()) { 228 if (is_keyboard_master()) {
232 for (uint8_t r = 0; r < MATRIX_ROWS; r++) { 229 for (uint8_t r = 0; r < MATRIX_ROWS; r++) {
233 matrix_row = matrix_debounce_get_row(r); 230 matrix_row = matrix_get_row(r);
234 matrix_change = matrix_row ^ matrix_prev[r]; 231 matrix_change = matrix_row ^ matrix_prev[r];
235 if (matrix_change) { 232 if (matrix_change) {
236#ifdef MATRIX_HAS_GHOST 233#ifdef MATRIX_HAS_GHOST