summaryrefslogtreecommitdiff
path: root/quantum/led_matrix_drivers.c
diff options
context:
space:
mode:
authorskullY <skullydazed@gmail.com>2019-01-26 14:33:55 -0800
committerskullydazed <skullydazed@users.noreply.github.com>2019-02-10 15:37:12 -0800
commitbf2670601d29551896bab6811b9bb64de2d0ee0e (patch)
tree459467a986f6ce0fa3ef2accbfd0d43a3afffad8 /quantum/led_matrix_drivers.c
parent159191a8747891920aea7de2324507daa8a661fb (diff)
downloadqmk_firmware-bf2670601d29551896bab6811b9bb64de2d0ee0e.tar.gz
qmk_firmware-bf2670601d29551896bab6811b9bb64de2d0ee0e.zip
compiles, but long delay on startup and problems
Diffstat (limited to 'quantum/led_matrix_drivers.c')
-rw-r--r--quantum/led_matrix_drivers.c50
1 files changed, 25 insertions, 25 deletions
diff --git a/quantum/led_matrix_drivers.c b/quantum/led_matrix_drivers.c
index f00f4f3668..e0f8b20949 100644
--- a/quantum/led_matrix_drivers.c
+++ b/quantum/led_matrix_drivers.c
@@ -39,32 +39,32 @@ static void init(void) {
i2c_init();
#ifdef IS31FL3731
#ifdef LED_DRIVER_ADDR_1
- IS31FL3731_init(DRIVER_ADDR_1);
+ IS31FL3731_init(LED_DRIVER_ADDR_1);
#endif
#ifdef LED_DRIVER_ADDR_2
- IS31FL3731_init(DRIVER_ADDR_2);
+ IS31FL3731_init(LED_DRIVER_ADDR_2);
#endif
#ifdef LED_DRIVER_ADDR_3
- IS31FL3731_init(DRIVER_ADDR_3);
+ IS31FL3731_init(LED_DRIVER_ADDR_3);
#endif
#ifdef LED_DRIVER_ADDR_4
- IS31FL3731_init(DRIVER_ADDR_4);
+ IS31FL3731_init(LED_DRIVER_ADDR_4);
#endif
#else
#ifdef LED_DRIVER_ADDR_1
- IS31FL3733_init(DRIVER_ADDR_1);
+ IS31FL3733_init(LED_DRIVER_ADDR_1);
#endif
#ifdef LED_DRIVER_ADDR_2
- IS31FL3733_init(DRIVER_ADDR_2);
+ IS31FL3733_init(LED_DRIVER_ADDR_2);
#endif
#ifdef LED_DRIVER_ADDR_3
- IS31FL3733_init(DRIVER_ADDR_3);
+ IS31FL3733_init(LED_DRIVER_ADDR_3);
#endif
#ifdef LED_DRIVER_ADDR_4
- IS31FL3733_init(DRIVER_ADDR_4);
+ IS31FL3733_init(LED_DRIVER_ADDR_4);
#endif
#endif
- for (int index = 0; index < DRIVER_LED_TOTAL; index++) {
+ for (int index = 0; index < LED_DRIVER_COUNT; index++) {
#ifdef IS31FL3731
IS31FL3731_set_led_control_register(index, true);
#else
@@ -74,29 +74,29 @@ static void init(void) {
// This actually updates the LED drivers
#ifdef IS31FL3731
#ifdef LED_DRIVER_ADDR_1
- IS31FL3731_update_led_control_registers(DRIVER_ADDR_1);
+ IS31FL3731_update_led_control_registers(LED_DRIVER_ADDR_1, 0);
#endif
#ifdef LED_DRIVER_ADDR_2
- IS31FL3731_update_led_control_registers(DRIVER_ADDR_2);
+ IS31FL3731_update_led_control_registers(LED_DRIVER_ADDR_2, 1);
#endif
#ifdef LED_DRIVER_ADDR_3
- IS31FL3731_update_led_control_registers(DRIVER_ADDR_3);
+ IS31FL3731_update_led_control_registers(LED_DRIVER_ADDR_3, 2);
#endif
#ifdef LED_DRIVER_ADDR_4
- IS31FL3731_update_led_control_registers(DRIVER_ADDR_4);
+ IS31FL3731_update_led_control_registers(LED_DRIVER_ADDR_4, 3);
#endif
#else
#ifdef LED_DRIVER_ADDR_1
- IS31FL3733_update_led_control_registers(DRIVER_ADDR_1);
+ IS31FL3733_update_led_control_registers(LED_DRIVER_ADDR_1, 0);
#endif
#ifdef LED_DRIVER_ADDR_2
- IS31FL3733_update_led_control_registers(DRIVER_ADDR_2);
+ IS31FL3733_update_led_control_registers(LED_DRIVER_ADDR_2, 1);
#endif
#ifdef LED_DRIVER_ADDR_3
- IS31FL3733_update_led_control_registers(DRIVER_ADDR_3);
+ IS31FL3733_update_led_control_registers(LED_DRIVER_ADDR_3, 2);
#endif
#ifdef LED_DRIVER_ADDR_4
- IS31FL3733_update_led_control_registers(DRIVER_ADDR_4);
+ IS31FL3733_update_led_control_registers(LED_DRIVER_ADDR_4, 3);
#endif
#endif
}
@@ -104,29 +104,29 @@ static void init(void) {
static void flush(void) {
#ifdef IS31FL3731
#ifdef LED_DRIVER_ADDR_1
- IS31FL3731_update_pwm_buffers(DRIVER_ADDR_1);
+ IS31FL3731_update_pwm_buffers(LED_DRIVER_ADDR_1, 0);
#endif
#ifdef LED_DRIVER_ADDR_2
- IS31FL3731_update_pwm_buffers(DRIVER_ADDR_2);
+ IS31FL3731_update_pwm_buffers(LED_DRIVER_ADDR_2, 1);
#endif
#ifdef LED_DRIVER_ADDR_3
- IS31FL3731_update_pwm_buffers(DRIVER_ADDR_3);
+ IS31FL3731_update_pwm_buffers(LED_DRIVER_ADDR_3, 2);
#endif
#ifdef LED_DRIVER_ADDR_4
- IS31FL3731_update_pwm_buffers(DRIVER_ADDR_4);
+ IS31FL3731_update_pwm_buffers(LED_DRIVER_ADDR_4, 3);
#endif
#else
#ifdef LED_DRIVER_ADDR_1
- IS31FL3733_update_pwm_buffers(DRIVER_ADDR_1);
+ IS31FL3733_update_pwm_buffers(LED_DRIVER_ADDR_1, 0);
#endif
#ifdef LED_DRIVER_ADDR_2
- IS31FL3733_update_pwm_buffers(DRIVER_ADDR_2);
+ IS31FL3733_update_pwm_buffers(LED_DRIVER_ADDR_2, 1);
#endif
#ifdef LED_DRIVER_ADDR_3
- IS31FL3733_update_pwm_buffers(DRIVER_ADDR_3);
+ IS31FL3733_update_pwm_buffers(LED_DRIVER_ADDR_3, 2);
#endif
#ifdef LED_DRIVER_ADDR_4
- IS31FL3733_update_pwm_buffers(DRIVER_ADDR_4);
+ IS31FL3733_update_pwm_buffers(LED_DRIVER_ADDR_4, 3);
#endif
#endif
}