From 3fed8bced718e24e414c0d5736554d7988235b20 Mon Sep 17 00:00:00 2001 From: yiancar Date: Tue, 16 Feb 2021 03:36:58 +0200 Subject: Dc01 fixes (#11843) * dc01-fixes * dc01-fixes * Cleanup and add VIA * Updated JSONs * fix --- keyboards/dc01/right/matrix.c | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) (limited to 'keyboards/dc01/right/matrix.c') diff --git a/keyboards/dc01/right/matrix.c b/keyboards/dc01/right/matrix.c index 6ec3a3b723..530834a7b2 100644 --- a/keyboards/dc01/right/matrix.c +++ b/keyboards/dc01/right/matrix.c @@ -31,8 +31,9 @@ along with this program. If not, see . #include "timer.h" #include "i2c_slave.h" #include "lufa.h" +#include "quantum.h" -#define SLAVE_I2C_ADDRESS 0x19 +#define SLAVE_I2C_ADDRESS 0x32 /* Set 0 if debouncing isn't needed */ @@ -196,12 +197,10 @@ uint8_t matrix_scan(void) } # endif - if (USB_DeviceState != DEVICE_STATE_Configured){ - i2c_slave_reg[1] = 0x55; - for (uint8_t i = 0; i < MATRIX_ROWS; i++){ - i2c_slave_reg[i+2] = matrix[i]; //send matrix over i2c - } - } + i2c_slave_reg[1] = 0x55; + for (uint8_t i = 0; i < MATRIX_ROWS; i++){ + i2c_slave_reg[i+2] = matrix[i]; //send matrix over i2c + } matrix_scan_quantum(); return 1; @@ -396,9 +395,6 @@ static void unselect_cols(void) //this replases tmk code void matrix_setup(void){ - - if (USB_DeviceState != DEVICE_STATE_Configured){ - i2c_slave_init(SLAVE_I2C_ADDRESS); //setup address of slave i2c - sei(); //enable interupts - } + i2c_slave_init(SLAVE_I2C_ADDRESS); //setup address of slave i2c + sei(); //enable interupts } \ No newline at end of file -- cgit v1.2.3