diff options
author | Drashna Jaelre <drashna@live.com> | 2021-08-17 10:31:34 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-08-17 10:31:34 -0700 |
commit | fae5cc6c67c9475d08c56ff01e470389747196f7 (patch) | |
tree | d680e47018f1f8a71bd4b620cbd9f41ab5640e17 | |
parent | a6d2993fc5609baab3003dd04cdafb142dd7b779 (diff) | |
download | qmk_firmware-fae5cc6c67c9475d08c56ff01e470389747196f7.tar.gz qmk_firmware-fae5cc6c67c9475d08c56ff01e470389747196f7.zip |
[Keyboard] Fixup Neson Design N6 ISSI includes (#14045)
-rw-r--r-- | keyboards/neson_design/n6/n6.c | 96 | ||||
-rw-r--r-- | keyboards/neson_design/n6/rules.mk | 2 |
2 files changed, 49 insertions, 49 deletions
diff --git a/keyboards/neson_design/n6/n6.c b/keyboards/neson_design/n6/n6.c index 800aa0ae9..38b0fd4c8 100644 --- a/keyboards/neson_design/n6/n6.c +++ b/keyboards/neson_design/n6/n6.c | |||
@@ -19,7 +19,7 @@ | |||
19 | 19 | ||
20 | #include "n6.h" | 20 | #include "n6.h" |
21 | #include "i2c_master.h" | 21 | #include "i2c_master.h" |
22 | #include "issi/is31fl3731.h" | 22 | #include "drivers/led/issi/is31fl3731.h" |
23 | 23 | ||
24 | enum { | 24 | enum { |
25 | SELF_TESTING, | 25 | SELF_TESTING, |
@@ -158,7 +158,7 @@ static void self_testing(void) | |||
158 | } | 158 | } |
159 | 159 | ||
160 | // light left and right | 160 | // light left and right |
161 | 161 | ||
162 | if (rgb_state.index == 16) { | 162 | if (rgb_state.index == 16) { |
163 | if (rgb_state.duration) { | 163 | if (rgb_state.duration) { |
164 | rgb_state.duration--; | 164 | rgb_state.duration--; |
@@ -187,49 +187,49 @@ static void self_testing(void) | |||
187 | update_ticks(); | 187 | update_ticks(); |
188 | } | 188 | } |
189 | 189 | ||
190 | const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { | 190 | const is31_led __flash g_is31_leds[DRIVER_LED_TOTAL] = { |
191 | /* Refer to IS31 manual for these locations | 191 | /* Refer to IS31 manual for these locations |
192 | * driver | 192 | * driver |
193 | * | R location | 193 | * | R location |
194 | * | | G location | 194 | * | | G location |
195 | * | | | B location | 195 | * | | | B location |
196 | * | | | | */ | 196 | * | | | | */ |
197 | // left CA | 197 | // left CA |
198 | {0, C1_1, C3_2, C4_2}, | 198 | {0, C1_1, C3_2, C4_2}, |
199 | {0, C1_2, C2_2, C4_3}, | 199 | {0, C1_2, C2_2, C4_3}, |
200 | {0, C1_3, C2_3, C3_3}, | 200 | {0, C1_3, C2_3, C3_3}, |
201 | {0, C1_4, C2_4, C3_4}, | 201 | {0, C1_4, C2_4, C3_4}, |
202 | {0, C1_5, C2_5, C3_5}, | 202 | {0, C1_5, C2_5, C3_5}, |
203 | {0, C1_6, C2_6, C3_6}, | 203 | {0, C1_6, C2_6, C3_6}, |
204 | {0, C1_7, C2_7, C3_7}, | 204 | {0, C1_7, C2_7, C3_7}, |
205 | {0, C1_8, C2_8, C3_8}, | 205 | {0, C1_8, C2_8, C3_8}, |
206 | 206 | ||
207 | {0, C9_1, C8_1, C7_1}, | 207 | {0, C9_1, C8_1, C7_1}, |
208 | {0, C9_2, C8_2, C7_2}, | 208 | {0, C9_2, C8_2, C7_2}, |
209 | {0, C9_3, C8_3, C7_3}, | 209 | {0, C9_3, C8_3, C7_3}, |
210 | {0, C9_4, C8_4, C7_4}, | 210 | {0, C9_4, C8_4, C7_4}, |
211 | {0, C9_5, C8_5, C7_5}, | 211 | {0, C9_5, C8_5, C7_5}, |
212 | {0, C9_6, C8_6, C7_6}, | 212 | {0, C9_6, C8_6, C7_6}, |
213 | {0, C9_7, C8_7, C6_6}, | 213 | {0, C9_7, C8_7, C6_6}, |
214 | {0, C9_8, C7_7, C6_7}, | 214 | {0, C9_8, C7_7, C6_7}, |
215 | // left CB | 215 | // left CB |
216 | {0, C1_9, C3_10, C4_10}, | 216 | {0, C1_9, C3_10, C4_10}, |
217 | {0, C1_10, C2_10, C4_11}, | 217 | {0, C1_10, C2_10, C4_11}, |
218 | {0, C1_11, C2_11, C3_11}, | 218 | {0, C1_11, C2_11, C3_11}, |
219 | {0, C1_12, C2_12, C3_12}, | 219 | {0, C1_12, C2_12, C3_12}, |
220 | {0, C1_13, C2_13, C3_13}, | 220 | {0, C1_13, C2_13, C3_13}, |
221 | {0, C1_14, C2_14, C3_14}, | 221 | {0, C1_14, C2_14, C3_14}, |
222 | {0, C1_15, C2_15, C3_15}, | 222 | {0, C1_15, C2_15, C3_15}, |
223 | {0, C1_16, C2_16, C3_16}, | 223 | {0, C1_16, C2_16, C3_16}, |
224 | 224 | ||
225 | {0, C9_9, C8_9, C7_9}, | 225 | {0, C9_9, C8_9, C7_9}, |
226 | {0, C9_10, C8_10, C7_10}, | 226 | {0, C9_10, C8_10, C7_10}, |
227 | {0, C9_11, C8_11, C7_11}, | 227 | {0, C9_11, C8_11, C7_11}, |
228 | {0, C9_12, C8_12, C7_12}, | 228 | {0, C9_12, C8_12, C7_12}, |
229 | {0, C9_13, C8_13, C7_13}, | 229 | {0, C9_13, C8_13, C7_13}, |
230 | {0, C9_14, C8_14, C7_14}, | 230 | {0, C9_14, C8_14, C7_14}, |
231 | {0, C9_15, C8_15, C6_14}, | 231 | {0, C9_15, C8_15, C6_14}, |
232 | {0, C9_16, C7_15, C6_15}, | 232 | {0, C9_16, C7_15, C6_15}, |
233 | }; | 233 | }; |
234 | #endif | 234 | #endif |
235 | __attribute__((weak)) | 235 | __attribute__((weak)) |
@@ -240,7 +240,7 @@ void matrix_init_kb(void) | |||
240 | // clear caps led | 240 | // clear caps led |
241 | setPinOutput(CAPS_PIN); | 241 | setPinOutput(CAPS_PIN); |
242 | writePinLow(CAPS_PIN); | 242 | writePinLow(CAPS_PIN); |
243 | #ifdef RGBLIGHT_ENABLE | 243 | #ifdef RGBLIGHT_ENABLE |
244 | i2c_init(); | 244 | i2c_init(); |
245 | IS31FL3731_init(DRIVER_ADDR_1); | 245 | IS31FL3731_init(DRIVER_ADDR_1); |
246 | for (int index = 0; index < DRIVER_LED_TOTAL; index++) { | 246 | for (int index = 0; index < DRIVER_LED_TOTAL; index++) { |
@@ -252,7 +252,7 @@ void matrix_init_kb(void) | |||
252 | matrix_init_user(); | 252 | matrix_init_user(); |
253 | } | 253 | } |
254 | 254 | ||
255 | #ifdef RGBLIGHT_ENABLE | 255 | #ifdef RGBLIGHT_ENABLE |
256 | void housekeeping_task_kb(void) | 256 | void housekeeping_task_kb(void) |
257 | { | 257 | { |
258 | if (rgb_state.state == SELF_TESTING) { | 258 | if (rgb_state.state == SELF_TESTING) { |
@@ -261,7 +261,7 @@ void housekeeping_task_kb(void) | |||
261 | //gold 0xFF, 0xD9, 0x00 | 261 | //gold 0xFF, 0xD9, 0x00 |
262 | LED_TYPE led = { | 262 | LED_TYPE led = { |
263 | .r = 0xFF, | 263 | .r = 0xFF, |
264 | .g = 0xD9, | 264 | .g = 0xD9, |
265 | .b = 0x00, | 265 | .b = 0x00, |
266 | }; | 266 | }; |
267 | if (rgb_state.alert) { | 267 | if (rgb_state.alert) { |
@@ -303,7 +303,7 @@ bool led_update_kb(led_t led_state) | |||
303 | if (res) { | 303 | if (res) { |
304 | writePin(CAPS_PIN, led_state.caps_lock); | 304 | writePin(CAPS_PIN, led_state.caps_lock); |
305 | 305 | ||
306 | #ifdef RGBLIGHT_ENABLE | 306 | #ifdef RGBLIGHT_ENABLE |
307 | if (rgb_state.state != SELF_TESTING) { | 307 | if (rgb_state.state != SELF_TESTING) { |
308 | if (led_state.caps_lock) { | 308 | if (led_state.caps_lock) { |
309 | rgb_state.state = CAPS_ALERT; | 309 | rgb_state.state = CAPS_ALERT; |
@@ -316,4 +316,4 @@ bool led_update_kb(led_t led_state) | |||
316 | #endif | 316 | #endif |
317 | } | 317 | } |
318 | return res; | 318 | return res; |
319 | } \ No newline at end of file | 319 | } |
diff --git a/keyboards/neson_design/n6/rules.mk b/keyboards/neson_design/n6/rules.mk index a12a4034b..f551ee91d 100644 --- a/keyboards/neson_design/n6/rules.mk +++ b/keyboards/neson_design/n6/rules.mk | |||
@@ -19,5 +19,5 @@ NKRO_ENABLE = yes # USB Nkey Rollover | |||
19 | BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality | 19 | BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality |
20 | RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow | 20 | RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow |
21 | 21 | ||
22 | QUANTUM_LIB_SRC += i2c_master.c issi/is31fl3731.c | 22 | QUANTUM_LIB_SRC += i2c_master.c drivers/led/issi/is31fl3731.c |
23 | LAYOUTS = 65_ansi_blocker | 23 | LAYOUTS = 65_ansi_blocker |