summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Didron <fdidron@users.noreply.github.com>2019-05-06 09:54:03 +0900
committerGitHub <noreply@github.com>2019-05-06 09:54:03 +0900
commite622e6d1bb3e23878da7fa7da0ad4061aac07777 (patch)
treecc07d0eb233af0ffd02c2a484cf2e34eccaf92e0
parent2a70dc8eea79029a92eedc0d9d53b5341bb8271c (diff)
parent882b8df7afcbcb38e57e2d4b7c47ca86203127dc (diff)
Merge pull request #37 from zsa/feature/rgb_matrix_led_lookup
Implement kb function for rgb matrix to led lookup
-rw-r--r--quantum/rgb_matrix.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/quantum/rgb_matrix.c b/quantum/rgb_matrix.c
index 1d27a620a2..3c83463146 100644
--- a/quantum/rgb_matrix.c
+++ b/quantum/rgb_matrix.c
@@ -144,9 +144,14 @@ void eeconfig_debug_rgb_matrix(void) {
dprintf("rgb_matrix_config.speed = %d\n", rgb_matrix_config.speed);
}
+__attribute__ ((weak))
+uint8_t rgb_matrix_map_row_column_to_led_kb(uint8_t row, uint8_t column, uint8_t *led_i) {
+ return 0;
+}
+
uint8_t rgb_matrix_map_row_column_to_led(uint8_t row, uint8_t column, uint8_t *led_i) {
// TODO: This is kinda expensive, fix this soonish
- uint8_t led_count = 0;
+ uint8_t led_count = rgb_matrix_map_row_column_to_led_kb(row, column, led_i);
for (uint8_t i = 0; i < DRIVER_LED_TOTAL && led_count < LED_HITS_TO_REMEMBER; i++) {
matrix_co_t matrix_co = g_rgb_leds[i].matrix_co;
if (row == matrix_co.row && column == matrix_co.col) {