mirror of
https://github.com/Cian-H/qmk_firmware.git
synced 2026-08-05 05:23:23 +01:00
RGB Matrix: driver naming cleanups (#21594)
This commit is contained in:
@@ -55,7 +55,7 @@
|
||||
},
|
||||
"community_layouts": ["ortho_4x4"],
|
||||
"rgb_matrix": {
|
||||
"driver": "WS2812",
|
||||
"driver": "ws2812",
|
||||
"animations": {
|
||||
"alphas_mods": true,
|
||||
"gradient_up_down": true,
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
"pin": "E2"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "WS2812"
|
||||
"driver": "ws2812"
|
||||
},
|
||||
"rgblight": {
|
||||
"max_brightness": 180
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
"pin": "E2"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "WS2812"
|
||||
"driver": "ws2812"
|
||||
},
|
||||
"rgblight": {
|
||||
"max_brightness": 180
|
||||
|
||||
@@ -153,16 +153,16 @@ LED_TYPE rgb_matrix_ws2812_array[WS2812_LED_TOTAL];
|
||||
|
||||
static void rgb_matrix_driver_init(void) {
|
||||
i2c_init();
|
||||
IS31FL3733_init(DRIVER_ADDR_1, 0);
|
||||
is31fl3733_init(DRIVER_ADDR_1, 0);
|
||||
for (uint8_t index = 0; index < ISSI_LED_TOTAL; index++) {
|
||||
bool enabled = true;
|
||||
IS31FL3733_set_led_control_register(index, enabled, enabled, enabled);
|
||||
is31fl3733_set_led_control_register(index, enabled, enabled, enabled);
|
||||
}
|
||||
IS31FL3733_update_led_control_registers(DRIVER_ADDR_1, 0);
|
||||
is31fl3733_update_led_control_registers(DRIVER_ADDR_1, 0);
|
||||
}
|
||||
|
||||
static void rgb_matrix_driver_flush(void) {
|
||||
IS31FL3733_update_pwm_buffers(DRIVER_ADDR_1, 0);
|
||||
is31fl3733_update_pwm_buffers(DRIVER_ADDR_1, 0);
|
||||
# if WS2812_LED_TOTAL > 0
|
||||
ws2812_setleds(rgb_matrix_ws2812_array, WS2812_LED_TOTAL);
|
||||
# endif
|
||||
@@ -170,7 +170,7 @@ static void rgb_matrix_driver_flush(void) {
|
||||
|
||||
static void rgb_matrix_driver_set_color(int index, uint8_t red, uint8_t green, uint8_t blue) {
|
||||
if (index < ISSI_LED_TOTAL) {
|
||||
IS31FL3733_set_color(index, red, green, blue);
|
||||
is31fl3733_set_color(index, red, green, blue);
|
||||
} else {
|
||||
# if WS2812_LED_TOTAL > 0
|
||||
rgb_matrix_ws2812_array[index - ISSI_LED_TOTAL].r = red;
|
||||
@@ -181,7 +181,7 @@ static void rgb_matrix_driver_set_color(int index, uint8_t red, uint8_t green, u
|
||||
}
|
||||
|
||||
static void rgb_matrix_driver_set_color_all(uint8_t red, uint8_t green, uint8_t blue) {
|
||||
IS31FL3733_set_color_all(red, green, blue);
|
||||
is31fl3733_set_color_all(red, green, blue);
|
||||
# if WS2812_LED_TOTAL > 0
|
||||
for (uint8_t i = 0; i < WS2812_LED_TOTAL; i++) {
|
||||
rgb_matrix_ws2812_array[i].r = red;
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
"pin": "E2"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "WS2812"
|
||||
"driver": "ws2812"
|
||||
},
|
||||
"matrix_pins": {
|
||||
"cols": ["D0", "D1", "D2", "D3", "D5", "D4", "D6", "D7", "B4", "B5", "B6", "C6", "C7", "F7"],
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
"pin": "F0"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "IS31FL3733"
|
||||
"driver": "is31fl3733"
|
||||
},
|
||||
"rgblight": {
|
||||
"saturation_steps": 8,
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
"pin": "E2"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "WS2812"
|
||||
"driver": "ws2812"
|
||||
},
|
||||
"matrix_pins": {
|
||||
"cols": ["D0", "D1", "D2", "D3", "D5", "D4", "D6", "D7", "B4", "B5", "B6", "C6", "C7", "F7"],
|
||||
|
||||
@@ -153,16 +153,16 @@ LED_TYPE rgb_matrix_ws2812_array[WS2812_LED_TOTAL];
|
||||
|
||||
static void rgb_matrix_driver_init(void) {
|
||||
i2c_init();
|
||||
IS31FL3733_init(DRIVER_ADDR_1, 0);
|
||||
is31fl3733_init(DRIVER_ADDR_1, 0);
|
||||
for (uint8_t index = 0; index < ISSI_LED_TOTAL; index++) {
|
||||
bool enabled = true;
|
||||
IS31FL3733_set_led_control_register(index, enabled, enabled, enabled);
|
||||
is31fl3733_set_led_control_register(index, enabled, enabled, enabled);
|
||||
}
|
||||
IS31FL3733_update_led_control_registers(DRIVER_ADDR_1, 0);
|
||||
is31fl3733_update_led_control_registers(DRIVER_ADDR_1, 0);
|
||||
}
|
||||
|
||||
static void rgb_matrix_driver_flush(void) {
|
||||
IS31FL3733_update_pwm_buffers(DRIVER_ADDR_1, 0);
|
||||
is31fl3733_update_pwm_buffers(DRIVER_ADDR_1, 0);
|
||||
# if WS2812_LED_TOTAL > 0
|
||||
ws2812_setleds(rgb_matrix_ws2812_array, WS2812_LED_TOTAL);
|
||||
# endif
|
||||
@@ -170,7 +170,7 @@ static void rgb_matrix_driver_flush(void) {
|
||||
|
||||
static void rgb_matrix_driver_set_color(int index, uint8_t red, uint8_t green, uint8_t blue) {
|
||||
if (index < ISSI_LED_TOTAL) {
|
||||
IS31FL3733_set_color(index, red, green, blue);
|
||||
is31fl3733_set_color(index, red, green, blue);
|
||||
} else {
|
||||
# if WS2812_LED_TOTAL > 0
|
||||
rgb_matrix_ws2812_array[index - ISSI_LED_TOTAL].r = red;
|
||||
@@ -181,7 +181,7 @@ static void rgb_matrix_driver_set_color(int index, uint8_t red, uint8_t green, u
|
||||
}
|
||||
|
||||
static void rgb_matrix_driver_set_color_all(uint8_t red, uint8_t green, uint8_t blue) {
|
||||
IS31FL3733_set_color_all(red, green, blue);
|
||||
is31fl3733_set_color_all(red, green, blue);
|
||||
# if WS2812_LED_TOTAL > 0
|
||||
for (uint8_t i = 0; i < WS2812_LED_TOTAL; i++) {
|
||||
rgb_matrix_ws2812_array[i].r = red;
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
"pin": "E2"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "WS2812"
|
||||
"driver": "ws2812"
|
||||
},
|
||||
"rgblight": {
|
||||
"saturation_steps": 8,
|
||||
|
||||
@@ -149,16 +149,16 @@ LED_TYPE rgb_matrix_ws2812_array[WS2812_LED_TOTAL];
|
||||
|
||||
static void rgb_matrix_driver_init(void) {
|
||||
i2c_init();
|
||||
IS31FL3733_init(DRIVER_ADDR_1, 0);
|
||||
is31fl3733_init(DRIVER_ADDR_1, 0);
|
||||
for (uint8_t index = 0; index < ISSI_LED_TOTAL; index++) {
|
||||
bool enabled = true;
|
||||
IS31FL3733_set_led_control_register(index, enabled, enabled, enabled);
|
||||
is31fl3733_set_led_control_register(index, enabled, enabled, enabled);
|
||||
}
|
||||
IS31FL3733_update_led_control_registers(DRIVER_ADDR_1, 0);
|
||||
is31fl3733_update_led_control_registers(DRIVER_ADDR_1, 0);
|
||||
}
|
||||
|
||||
static void rgb_matrix_driver_flush(void) {
|
||||
IS31FL3733_update_pwm_buffers(DRIVER_ADDR_1, 0);
|
||||
is31fl3733_update_pwm_buffers(DRIVER_ADDR_1, 0);
|
||||
# if WS2812_LED_TOTAL > 0
|
||||
ws2812_setleds(rgb_matrix_ws2812_array, WS2812_LED_TOTAL);
|
||||
# endif
|
||||
@@ -166,7 +166,7 @@ static void rgb_matrix_driver_flush(void) {
|
||||
|
||||
static void rgb_matrix_driver_set_color(int index, uint8_t red, uint8_t green, uint8_t blue) {
|
||||
if (index < ISSI_LED_TOTAL) {
|
||||
IS31FL3733_set_color(index, red, green, blue);
|
||||
is31fl3733_set_color(index, red, green, blue);
|
||||
} else {
|
||||
# if WS2812_LED_TOTAL > 0
|
||||
rgb_matrix_ws2812_array[index - ISSI_LED_TOTAL].r = red;
|
||||
@@ -177,7 +177,7 @@ static void rgb_matrix_driver_set_color(int index, uint8_t red, uint8_t green, u
|
||||
}
|
||||
|
||||
static void rgb_matrix_driver_set_color_all(uint8_t red, uint8_t green, uint8_t blue) {
|
||||
IS31FL3733_set_color_all(red, green, blue);
|
||||
is31fl3733_set_color_all(red, green, blue);
|
||||
# if WS2812_LED_TOTAL > 0
|
||||
for (uint8_t i = 0; i < WS2812_LED_TOTAL; i++) {
|
||||
rgb_matrix_ws2812_array[i].r = red;
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
"pin": "E2"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "WS2812"
|
||||
"driver": "ws2812"
|
||||
},
|
||||
"matrix_pins": {
|
||||
"cols": ["D0", "D1", "D2", "D3", "D5", "D4", "D6", "D7", "B4", "B5", "B6", "C6", "C7", "F7", "F6"],
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
"pin": "E2"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "WS2812"
|
||||
"driver": "ws2812"
|
||||
},
|
||||
"matrix_pins": {
|
||||
"cols": ["D0", "D1", "D2", "D3", "D5", "D4", "D6", "D7", "B4", "B5", "B6", "C6", "C7", "F7", "F6"],
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
"pin": "E2"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "WS2812"
|
||||
"driver": "ws2812"
|
||||
},
|
||||
"matrix_pins": {
|
||||
"cols": ["D0", "D1", "D2", "D3", "D5", "D4", "D6", "D7", "B4", "B5", "B6", "C6", "C7", "F7", "F6"],
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
"pin": "E2"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "IS31FL3741"
|
||||
"driver": "is31fl3741"
|
||||
},
|
||||
"rgblight": {
|
||||
"saturation_steps": 8,
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
"pin": "E2"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "WS2812"
|
||||
"driver": "ws2812"
|
||||
},
|
||||
"matrix_pins": {
|
||||
"cols": ["F0", "F1", "F4", "D7", "D6", "D4", "D5", "D3", "D2", "F5", "F6", "F7", "D1", "D0", "B4", "B5", "B6"],
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
"device_version": "0.0.2"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "IS31FL3741"
|
||||
"driver": "is31fl3741"
|
||||
},
|
||||
"matrix_pins": {
|
||||
"cols": ["E6", "F0", "F1", "F4", "D7", "D6", "B7", "B1", "B0", "B2", "B3", "D3", "D5", "D4", "D2", "B4", "B5"],
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
"device_version": "0.0.2"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "IS31FL3741"
|
||||
"driver": "is31fl3741"
|
||||
},
|
||||
"matrix_pins": {
|
||||
"cols": ["E6", "F0", "F1", "F4", "D7", "D6", "B7", "B1", "B0", "B2", "B3", "D3", "D5", "D4", "D2", "B4", "B5"],
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
"device_version": "0.0.1"
|
||||
},
|
||||
"rgb_matrix": {
|
||||
"driver": "WS2812"
|
||||
"driver": "ws2812"
|
||||
},
|
||||
"matrix_pins": {
|
||||
"cols": ["B1", "B2", "B3", "B7", "D0", "D1", "D2", "D3", "D5", "E6", "F0", "F1", "F4", "F5", "D6"],
|
||||
|
||||
Reference in New Issue
Block a user