aboutsummaryrefslogtreecommitdiff
path: root/quantum/split_common/split_util.c
diff options
context:
space:
mode:
authorDrashna Jaelre <drashna@live.com>2018-10-31 15:14:59 -0700
committerMechMerlin <30334081+mechmerlin@users.noreply.github.com>2018-10-31 15:14:59 -0700
commitf63c0b784490a04069b59f1b77355d5982f55ceb (patch)
tree31570c4ad73a9f0914af873006e0edeb16ec6dfd /quantum/split_common/split_util.c
parentbd6d6d93f26578baf7ef1d05d51963d8c38ee7c9 (diff)
downloadqmk_firmware-f63c0b784490a04069b59f1b77355d5982f55ceb.tar.gz
qmk_firmware-f63c0b784490a04069b59f1b77355d5982f55ceb.zip
Add pointer(?) to disable_JTAG to prevent compiler errors (#4310)
Diffstat (limited to 'quantum/split_common/split_util.c')
-rw-r--r--quantum/split_common/split_util.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/quantum/split_common/split_util.c b/quantum/split_common/split_util.c
index 7ca68c56c..8d39329d4 100644
--- a/quantum/split_common/split_util.c
+++ b/quantum/split_common/split_util.c
@@ -92,13 +92,14 @@ void split_keyboard_setup(void) {
92 sei(); 92 sei();
93} 93}
94 94
95void disable_JTAG(void);
95void keyboard_slave_loop(void) { 96void keyboard_slave_loop(void) {
96 // Disable JTAG since we skip calling keyboard_init() on the slave side 97 // Disable JTAG since we skip calling keyboard_init() on the slave side
97 // Future fix will possible call keyboard_init() on the slave to remove this need 98 // Future fix will possible call keyboard_init() on the slave to remove this need
98 disable_JTAG(); 99 disable_JTAG();
99 100
100 matrix_init(); 101 matrix_init();
101 102
102 //Init RGB 103 //Init RGB
103 #ifdef RGBLIGHT_ENABLE 104 #ifdef RGBLIGHT_ENABLE
104 rgblight_init(); 105 rgblight_init();
@@ -107,7 +108,7 @@ void keyboard_slave_loop(void) {
107 while (1) { 108 while (1) {
108 // Matrix Slave Scan 109 // Matrix Slave Scan
109 matrix_slave_scan(); 110 matrix_slave_scan();
110 111
111 // Read Backlight Info 112 // Read Backlight Info
112 #ifdef BACKLIGHT_ENABLE 113 #ifdef BACKLIGHT_ENABLE
113 #ifdef USE_I2C 114 #ifdef USE_I2C
@@ -126,14 +127,14 @@ void keyboard_slave_loop(void) {
126 // Disable interupts (RGB data is big) 127 // Disable interupts (RGB data is big)
127 cli(); 128 cli();
128 // Create new DWORD for RGB data 129 // Create new DWORD for RGB data
129 uint32_t dword; 130 uint32_t dword;
130 131
131 // Fill the new DWORD with the data that was sent over 132 // Fill the new DWORD with the data that was sent over
132 uint8_t *dword_dat = (uint8_t *)(&dword); 133 uint8_t *dword_dat = (uint8_t *)(&dword);
133 for (int i = 0; i < 4; i++) { 134 for (int i = 0; i < 4; i++) {
134 dword_dat[i] = i2c_slave_buffer[I2C_RGB_START+i]; 135 dword_dat[i] = i2c_slave_buffer[I2C_RGB_START+i];
135 } 136 }
136 137
137 // Update the RGB now with the new data and set RGB_DIRTY to false 138 // Update the RGB now with the new data and set RGB_DIRTY to false
138 rgblight_update_dword(dword); 139 rgblight_update_dword(dword);
139 RGB_DIRTY = false; 140 RGB_DIRTY = false;