summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Didron <fdidron@users.noreply.github.com>2019-05-20 15:53:21 +0900
committerGitHub <noreply@github.com>2019-05-20 15:53:21 +0900
commit85291ed7a3de1cbd1868ad69687c805315558702 (patch)
tree750be8ef9c0ce2534a3eef02607b71f41f2a12dc
parent09e6b949274fcb83de23792a02033cdeabec4d74 (diff)
parentb58ea9ad0fb1ab7ea3dec14406105df089ecc923 (diff)
Merge pull request #50 from zsa/fix/split_common_i2c_backlight
Fix issue with Split Common backlight disabling
-rw-r--r--changelog.md1
-rw-r--r--quantum/split_common/transport.c5
2 files changed, 3 insertions, 3 deletions
diff --git a/changelog.md b/changelog.md
index 89ce1af652..af61dd3e64 100644
--- a/changelog.md
+++ b/changelog.md
@@ -16,6 +16,7 @@
05-05-2019 - New keycode macro (XP) for shifted character pairs using UNICODEMAP, and bugfixes/improvements
05-05-2019 - Add `LINK_TIME_OPTIMIZATION_ENABLE` to enable LTO and disable problematic features that cause LTO to fail
05-05-2019 - Fix issue with Space Cadet
+05-10-2019 - Split Common i2c Backlight fix
05-06-2019 - More readable fix of Mousekeys issue
05-06-2019 - Changes to Split Common and OLED code
05-16-2019 - Add RGB Light Effect Range functionality
diff --git a/quantum/split_common/transport.c b/quantum/split_common/transport.c
index 7ea1a9cec9..a3539576f5 100644
--- a/quantum/split_common/transport.c
+++ b/quantum/split_common/transport.c
@@ -13,7 +13,6 @@
#ifdef BACKLIGHT_ENABLE
# include "backlight.h"
-extern backlight_config_t backlight_config;
#endif
#ifdef ENCODER_ENABLE
@@ -55,7 +54,7 @@ bool transport_master(matrix_row_t matrix[]) {
// write backlight info
# ifdef BACKLIGHT_ENABLE
- uint8_t level = get_backlight_level();
+ uint8_t level = is_backlight_enabled() ? get_backlight_level() : 0;
if (level != i2c_buffer->backlight_level) {
if (i2c_writeReg(SLAVE_I2C_ADDRESS, I2C_BACKLIGHT_START, (void *)&level, sizeof(level), TIMEOUT) >= 0) {
i2c_buffer->backlight_level = level;
@@ -223,7 +222,7 @@ bool transport_master(matrix_row_t matrix[]) {
# ifdef BACKLIGHT_ENABLE
// Write backlight level for slave to read
- serial_m2s_buffer.backlight_level = backlight_config.enable ? backlight_config.level : 0;
+ serial_m2s_buffer.backlight_level = is_backlight_enabled() ? get_backlight_level() : 0;
# endif
# ifdef ENCODER_ENABLE