From 3eabd7946ec5e47d12d603d591e8d8658d82fa42 Mon Sep 17 00:00:00 2001 From: Seth Barberee Date: Sat, 11 Aug 2018 13:10:23 -0500 Subject: Split Common: Serial Backlight LED fix (#3586) --- quantum/split_common/matrix.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'quantum/split_common') diff --git a/quantum/split_common/matrix.c b/quantum/split_common/matrix.c index 0a79e4256..4af90209f 100644 --- a/quantum/split_common/matrix.c +++ b/quantum/split_common/matrix.c @@ -340,6 +340,24 @@ void matrix_slave_scan(void) { for (int i = 0; i < ROWS_PER_HAND; ++i) { serial_slave_buffer[i] = matrix[offset+i]; } +#endif +#ifdef USE_I2C +#ifdef BACKLIGHT_ENABLE + // Read backlight level sent from master and update level on slave + backlight_set(i2c_slave_buffer[0]); +#endif + for (int i = 0; i < ROWS_PER_HAND; ++i) { + i2c_slave_buffer[i+1] = matrix[offset+i]; + } +#else // USE_SERIAL + for (int i = 0; i < ROWS_PER_HAND; ++i) { + serial_slave_buffer[i] = matrix[offset+i]; + } + +#ifdef BACKLIGHT_ENABLE + // Read backlight level sent from master and update level on slave + backlight_set(serial_master_buffer[SERIAL_BACKLIT_START]); +#endif #endif matrix_slave_scan_user(); } -- cgit v1.2.3-24-g4f1b