summaryrefslogtreecommitdiffstats
path: root/keyboards/dztech/dz60rgb
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/dztech/dz60rgb')
-rw-r--r--keyboards/dztech/dz60rgb/dz60rgb.c419
-rw-r--r--keyboards/dztech/dz60rgb/keymaps/ansi/keymap.c5
-rw-r--r--keyboards/dztech/dz60rgb/keymaps/hhkb/keymap.c5
-rw-r--r--keyboards/dztech/dz60rgb/keymaps/hhkb_iso/keymap.c5
-rw-r--r--keyboards/dztech/dz60rgb/keymaps/iso/keymap.c5
-rw-r--r--keyboards/dztech/dz60rgb/keymaps/mekanist/keymap.c30
6 files changed, 121 insertions, 348 deletions
diff --git a/keyboards/dztech/dz60rgb/dz60rgb.c b/keyboards/dztech/dz60rgb/dz60rgb.c
index 10b2ea7a83..28ac7ce9e2 100644
--- a/keyboards/dztech/dz60rgb/dz60rgb.c
+++ b/keyboards/dztech/dz60rgb/dz60rgb.c
@@ -65,69 +65,26 @@ const is31_led g_is31_leds[DRIVER_LED_TOTAL] = {
{0, K_16, J_16, L_16},
};
-rgb_led g_rgb_leds[DRIVER_LED_TOTAL] = {
- {{0|(13<<4)}, {16*13.5, 0}, 1},
- {{0|(12<<4)}, {16*12, 0}, 1},
- {{0|(11<<4)}, {16*11, 0}, 1},
- {{0|(10<<4)}, {16*10, 0}, 1},
- {{0|(9<<4)}, {16*9, 0}, 1},
- {{0|(8<<4)}, {16*8, 0}, 1},
- {{0|(7<<4)}, {16*7, 0}, 1},
- {{0|(6<<4)}, {16*6, 0}, 1},
- {{0|(5<<4)}, {16*5, 0}, 1},
- {{0|(4<<4)}, {16*4, 0}, 1},
- {{0|(3<<4)}, {16*3, 0}, 1},
- {{0|(2<<4)}, {16*2, 0}, 1},
- {{0|(1<<4)}, {16*1, 0}, 1},
- {{0|(0<<4)}, {16*0, 0}, 1},
- {{2|(13<<4)}, {16*13.75, 24}, 1},
- {{1|(12<<4)}, {16*12.5, 16}, 4},
- {{1|(11<<4)}, {16*11.5, 16}, 4},
- {{1|(10<<4)}, {16*10.5, 16}, 4},
- {{1|(9<<4)}, { 16*9.5, 16}, 4},
- {{1|(8<<4)}, { 16*8.5, 16}, 4},
- {{1|(7<<4)}, { 16*7.5, 16}, 4},
- {{1|(6<<4)}, { 16*6.5, 16}, 4},
- {{1|(5<<4)}, { 16*5.5, 16}, 4},
- {{1|(4<<4)}, { 16*4.5, 16}, 4},
- {{1|(3<<4)}, { 16*3.5, 16}, 4},
- {{1|(2<<4)}, { 16*2.5, 16}, 4},
- {{1|(1<<4)}, { 16*1.5, 16}, 4},
- {{1|(0<<4)}, { 16*0.25, 16}, 1},
- {{1|(13<<4)}, {16*12.75, 32}, 1},
- {{2|(11<<4)}, {16*11.75, 32}, 4},
- {{2|(10<<4)}, {16*10.75, 32}, 4},
- {{2|(9<<4)}, {16*9.75, 32}, 4},
- {{2|(8<<4)}, {16*8.75, 32}, 4},
- {{2|(7<<4)}, {16*7.75, 32}, 4},
- {{2|(6<<4)}, { 16*6.75, 32}, 4},
- {{2|(5<<4)}, { 16*5.75, 32}, 4},
- {{2|(4<<4)}, { 16*4.75, 32}, 4},
- {{2|(3<<4)}, { 16*3.75, 32}, 4},
- {{2|(2<<4)}, { 16*2.75, 32}, 4},
- {{2|(1<<4)}, { 16*1.75, 32}, 4},
- {{2|(0<<4)}, { 16*0.375, 32}, 1},
- {{3|(11<<4)}, {16*13.125, 48}, 1},
- {{3|(10<<4)}, {16*11.25, 48}, 4},
- {{3|(9<<4)}, {16*10.25, 48}, 4},
- {{3|(8<<4)}, {16*9.25, 48}, 4},
- {{3|(7<<4)}, {16*8.25, 48}, 4},
- {{3|(6<<4)}, {16*7.25, 48}, 4},
- {{3|(5<<4)}, {16*6.25, 48}, 4},
- {{3|(4<<4)}, {16*5.25, 48}, 4},
- {{3|(3<<4)}, {16*4.25, 48}, 4},
- {{3|(2<<4)}, {16*3.25, 48}, 4},
- {{3|(1<<4)}, {16*1.25, 48}, 4},
- {{3|(0<<4)}, {16*0.625, 48}, 1},
- {{4|(13<<4)}, {16*13.875, 64}, 1},
- {{4|(11<<4)}, {16*12.625, 64}, 1},
- {{4|(10<<4)}, {16*11.375, 64}, 1},
- {{4|(9<<4)}, {16*10.125, 64}, 1},
- {{4|(5<<4)}, { 16*6.375, 64}, 4},
- {{4|(2<<4)}, { 16*2.625, 64}, 1},
- {{4|(1<<4)}, { 16*1.375, 64}, 1},
- {{4|(0<<4)}, { 16*0.125, 64}, 1},
-};
+led_config_t g_led_config = { {
+ { 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0 },
+ { 27, 26, 25, 24, 23, 22, 21, 20, 19, 18, 17, 16, 15, 28 },
+ { 40, 39, 38, 37, 36, 35, 34, 33, 32, 31, 30, 29, NO_LED, 14 },
+ { 52, 51, 50, 49, 48, 47, 46, 45, 44, 43, 42, 41, NO_LED, NO_LED },
+ { 60, 59, 58, NO_LED, NO_LED, 57, NO_LED, NO_LED, NO_LED, 56, 55, 54, NO_LED, 53 }
+}, {
+ { 216, 0 }, { 192, 0 }, { 176, 0 }, { 160, 0 }, { 144, 0 }, { 128, 0 }, { 112, 0 }, { 96, 0 }, { 80, 0 }, { 64, 0 }, { 48, 0 }, { 32, 0 }, { 16, 0 }, { 0, 0 },
+ { 220, 24 }, { 200, 16 }, { 184, 16 }, { 168, 16 }, { 152, 16 }, { 136, 16 }, { 120, 16 }, { 104, 16 }, { 88, 16 }, { 72, 16 }, { 56, 16 }, { 40, 16 }, { 24, 16 }, { 4, 16 },
+ { 204, 32 }, { 188, 32 }, { 172, 32 }, { 156, 32 }, { 140, 32 }, { 124, 32 }, { 108, 32 }, { 92, 32 }, { 76, 32 }, { 60, 32 }, { 44, 32 }, { 28, 32 }, { 6, 32 }, { 210, 48 },
+ { 180, 48 }, { 164, 48 }, { 148, 48 }, { 132, 48 }, { 116, 48 }, { 100, 48 }, { 84, 48 }, { 68, 48 }, { 52, 48 }, { 20, 48 }, { 10, 48 }, { 222, 64 }, { 202, 64 }, { 182, 64 },
+ { 162, 64 }, { 102, 64 }, { 42, 64 }, { 22, 64 }, { 2, 64 }
+}, {
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1,
+ 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 1,
+ 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 1, 1, 1,
+ 1, 4, 1, 1, 1
+} };
+
#elif defined (dzrgb60_hhkb)
const is31_led g_is31_leds[DRIVER_LED_TOTAL] = {
{0, H_15, G_15, I_15},
@@ -194,70 +151,26 @@ const is31_led g_is31_leds[DRIVER_LED_TOTAL] = {
{0, K_16, J_16, L_16},
};
-rgb_led g_rgb_leds[DRIVER_LED_TOTAL] = {
- {{2|(12<<4)}, {16*14, 0}, 1},
- {{0|(13<<4)}, {16*13, 0}, 1},
- {{0|(12<<4)}, {16*12, 0}, 1},
- {{0|(11<<4)}, {16*11, 0}, 1},
- {{0|(10<<4)}, {16*10, 0}, 1},
- {{0|(9<<4)}, {16*9, 0}, 1},
- {{0|(8<<4)}, {16*8, 0}, 1},
- {{0|(7<<4)}, {16*7, 0}, 1},
- {{0|(6<<4)}, {16*6, 0}, 1},
- {{0|(5<<4)}, {16*5, 0}, 1},
- {{0|(4<<4)}, {16*4, 0}, 1},
- {{0|(3<<4)}, {16*3, 0}, 1},
- {{0|(2<<4)}, {16*2, 0}, 1},
- {{0|(1<<4)}, {16*1, 0}, 1},
- {{0|(0<<4)}, {16*0, 0}, 1},
- {{1|(13<<4)}, {16*13.75, 16}, 1},
- {{1|(12<<4)}, {16*12.5, 16}, 4},
- {{1|(11<<4)}, {16*11.5, 16}, 4},
- {{1|(10<<4)}, {16*10.5, 16}, 4},
- {{1|(9<<4)}, { 16*9.5, 16}, 4},
- {{1|(8<<4)}, { 16*8.5, 16}, 4},
- {{1|(7<<4)}, { 16*7.5, 16}, 4},
- {{1|(6<<4)}, { 16*6.5, 16}, 4},
- {{1|(5<<4)}, { 16*5.5, 16}, 4},
- {{1|(4<<4)}, { 16*4.5, 16}, 4},
- {{1|(3<<4)}, { 16*3.5, 16}, 4},
- {{1|(2<<4)}, { 16*2.5, 16}, 4},
- {{1|(1<<4)}, { 16*1.5, 16}, 4},
- {{1|(0<<4)}, { 16*0.25, 16}, 1},
- {{2|(13<<4)}, {16*12.75, 32}, 1},
- {{2|(11<<4)}, {16*11.75, 32}, 4},
- {{2|(10<<4)}, {16*10.75, 32}, 4},
- {{2|(9<<4)}, {16*9.75, 32}, 4},
- {{2|(8<<4)}, {16*8.75, 32}, 4},
- {{2|(7<<4)}, {16*7.75, 32}, 4},
- {{2|(6<<4)}, { 16*6.75, 32}, 4},
- {{2|(5<<4)}, { 16*5.75, 32}, 4},
- {{2|(4<<4)}, { 16*4.75, 32}, 4},
- {{2|(3<<4)}, { 16*3.75, 32}, 4},
- {{2|(2<<4)}, { 16*2.75, 32}, 4},
- {{2|(1<<4)}, { 16*1.75, 32}, 4},
- {{2|(0<<4)}, { 16*0.375, 32}, 1},
- {{3|(13<<4)}, {16*14, 48}, 1},
- {{3|(11<<4)}, {16*12.625, 48}, 4},
- {{3|(10<<4)}, {16*11.25, 48}, 4},
- {{3|(9<<4)}, {16*10.25, 48}, 4},
- {{3|(8<<4)}, {16*9.25, 48}, 4},
- {{3|(7<<4)}, {16*8.25, 48}, 4},
- {{3|(6<<4)}, {16*7.25, 48}, 4},
- {{3|(5<<4)}, {16*6.25, 48}, 4},
- {{3|(4<<4)}, {16*5.25, 48}, 4},
- {{3|(3<<4)}, {16*4.25, 48}, 4},
- {{3|(2<<4)}, {16*3.25, 48}, 4},
- {{3|(1<<4)}, {16*1.25, 48}, 4},
- {{3|(0<<4)}, {16*0.625, 48}, 1},
- {{4|(13<<4)}, {16*13.625, 64}, 1},
- {{4|(11<<4)}, {16*12.375, 64}, 1},
- {{4|(10<<4)}, {16*11.125, 64}, 1},
- {{4|(5<<4)}, { 16*7, 64}, 4},
- {{4|(2<<4)}, { 16*2.875, 64}, 1},
- {{4|(1<<4)}, { 16*1.625, 64}, 1},
- {{4|(0<<4)}, { 16*0.375, 64}, 1},
-};
+led_config_t g_led_config = { {
+ { 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1 },
+ { 28, 27, 26, 25, 24, 23, 22, 21, 20, 19, 18, 17, 16, 15 },
+ { 41, 40, 39, 38, 37, 36, 35, 34, 33, 32, 31, 30, 0, 29 },
+ { 54, 53, 52, 51, 50, 49, 48, 47, 46, 45, 44, 43, NO_LED, 42 },
+ { 61, 60, 59, NO_LED, NO_LED, 58, NO_LED, NO_LED, NO_LED, NO_LED, 57, 56, NO_LED, 55 }
+}, {
+ { 224, 0 }, { 208, 0 }, { 192, 0 }, { 176, 0 }, { 160, 0 }, { 144, 0 }, { 128, 0 }, { 112, 0 }, { 96, 0 }, { 80, 0 }, { 64, 0 }, { 48, 0 }, { 32, 0 }, { 16, 0 },
+ { 0, 0 }, { 220, 16 }, { 200, 16 }, { 184, 16 }, { 168, 16 }, { 152, 16 }, { 136, 16 }, { 120, 16 }, { 104, 16 }, { 88, 16 }, { 72, 16 }, { 56, 16 }, { 40, 16 }, { 24, 16 },
+ { 4, 16 }, { 204, 32 }, { 188, 32 }, { 172, 32 }, { 156, 32 }, { 140, 32 }, { 124, 32 }, { 108, 32 }, { 92, 32 }, { 76, 32 }, { 60, 32 }, { 44, 32 }, { 28, 32 }, { 6, 32 },
+ { 224, 48 }, { 202, 48 }, { 180, 48 }, { 164, 48 }, { 148, 48 }, { 132, 48 }, { 116, 48 }, { 100, 48 }, { 84, 48 }, { 68, 48 }, { 52, 48 }, { 20, 48 }, { 10, 48 }, { 218, 64 },
+ { 198, 64 }, { 178, 64 }, { 112, 64 }, { 46, 64 }, { 26, 64 }, { 6, 64 }
+}, {
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
+ 1, 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1,
+ 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 1,
+ 1, 1, 4, 1, 1, 1
+} };
+
#elif defined (dzrgb60_hhkb_iso)
const is31_led g_is31_leds[DRIVER_LED_TOTAL] = {
{0, H_15, G_15, I_15},
@@ -324,70 +237,26 @@ const is31_led g_is31_leds[DRIVER_LED_TOTAL] = {
{0, K_16, J_16, L_16},
};
-rgb_led g_rgb_leds[DRIVER_LED_TOTAL] = {
- {{2|(12<<4)}, {16*14, 0}, 1},
- {{0|(13<<4)}, {16*13, 0}, 1},
- {{0|(12<<4)}, {16*12, 0}, 1},
- {{0|(11<<4)}, {16*11, 0}, 1},
- {{0|(10<<4)}, {16*10, 0}, 1},
- {{0|(9<<4)}, {16*9, 0}, 1},
- {{0|(8<<4)}, {16*8, 0}, 1},
- {{0|(7<<4)}, {16*7, 0}, 1},
- {{0|(6<<4)}, {16*6, 0}, 1},
- {{0|(5<<4)}, {16*5, 0}, 1},
- {{0|(4<<4)}, {16*4, 0}, 1},
- {{0|(3<<4)}, {16*3, 0}, 1},
- {{0|(2<<4)}, {16*2, 0}, 1},
- {{0|(1<<4)}, {16*1, 0}, 1},
- {{0|(0<<4)}, {16*0, 0}, 1},
- {{2|(13<<4)}, {16*13.75, 24}, 1},
- {{1|(12<<4)}, {16*12.5, 16}, 4},
- {{1|(11<<4)}, {16*11.5, 16}, 4},
- {{1|(10<<4)}, {16*10.5, 16}, 4},
- {{1|(9<<4)}, { 16*9.5, 16}, 4},
- {{1|(8<<4)}, { 16*8.5, 16}, 4},
- {{1|(7<<4)}, { 16*7.5, 16}, 4},
- {{1|(6<<4)}, { 16*6.5, 16}, 4},
- {{1|(5<<4)}, { 16*5.5, 16}, 4},
- {{1|(4<<4)}, { 16*4.5, 16}, 4},
- {{1|(3<<4)}, { 16*3.5, 16}, 4},
- {{1|(2<<4)}, { 16*2.5, 16}, 4},
- {{1|(1<<4)}, { 16*1.5, 16}, 4},
- {{1|(0<<4)}, { 16*0.25, 16}, 1},
- {{1|(13<<4)}, {16*12.75, 32}, 1},
- {{2|(11<<4)}, {16*11.75, 32}, 4},
- {{2|(10<<4)}, {16*10.75, 32}, 4},
- {{2|(9<<4)}, {16*9.75, 32}, 4},
- {{2|(8<<4)}, {16*8.75, 32}, 4},
- {{2|(7<<4)}, {16*7.75, 32}, 4},
- {{2|(6<<4)}, { 16*6.75, 32}, 4},
- {{2|(5<<4)}, { 16*5.75, 32}, 4},
- {{2|(4<<4)}, { 16*4.75, 32}, 4},
- {{2|(3<<4)}, { 16*3.75, 32}, 4},
- {{2|(2<<4)}, { 16*2.75, 32}, 4},
- {{2|(1<<4)}, { 16*1.75, 32}, 4},
- {{2|(0<<4)}, { 16*0.375, 32}, 1},
- {{3|(13<<4)}, {16*14, 48}, 1},
- {{3|(11<<4)}, {16*12.625, 48}, 4},
- {{3|(10<<4)}, {16*11.25, 48}, 4},
- {{3|(9<<4)}, {16*10.25, 48}, 4},
- {{3|(8<<4)}, {16*9.25, 48}, 4},
- {{3|(7<<4)}, {16*8.25, 48}, 4},
- {{3|(6<<4)}, {16*7.25, 48}, 4},
- {{3|(5<<4)}, {16*6.25, 48}, 4},
- {{3|(4<<4)}, {16*5.25, 48}, 4},
- {{3|(3<<4)}, {16*4.25, 48}, 4},
- {{3|(2<<4)}, {16*3.25, 48}, 4},
- {{3|(1<<4)}, {16*1.25, 48}, 4},
- {{3|(0<<4)}, {16*0.625, 48}, 1},
- {{4|(13<<4)}, {16*13.625, 64}, 1},
- {{4|(11<<4)}, {16*12.375, 64}, 1},
- {{4|(10<<4)}, {16*11.125, 64}, 1},
- {{4|(5<<4)}, { 16*7, 64}, 4},
- {{4|(2<<4)}, { 16*2.875, 64}, 1},
- {{4|(1<<4)}, { 16*1.625, 64}, 1},
- {{4|(0<<4)}, { 16*0.375, 64}, 1},
-};
+led_config_t g_led_config = { {
+ { 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1 },
+ { 28, 27, 26, 25, 24, 23, 22, 21, 20, 19, 18, 17, 16, 29 },
+ { 41, 40, 39, 38, 37, 36, 35, 34, 33, 32, 31, 30, 0, 15 },
+ { 54, 53, 52, 51, 50, 49, 48, 47, 46, 45, 44, 43, NO_LED, 42 },
+ { 61, 60, 59, NO_LED, NO_LED, 58, NO_LED, NO_LED, NO_LED, NO_LED, 57, 56, NO_LED, 55 }
+}, {
+ { 224, 0 }, { 208, 0 }, { 192, 0 }, { 176, 0 }, { 160, 0 }, { 144, 0 }, { 128, 0 }, { 112, 0 }, { 96, 0 }, { 80, 0 }, { 64, 0 }, { 48, 0 }, { 32, 0 }, { 16, 0 },
+ { 0, 0 }, { 220, 24 }, { 200, 16 }, { 184, 16 }, { 168, 16 }, { 152, 16 }, { 136, 16 }, { 120, 16 }, { 104, 16 }, { 88, 16 }, { 72, 16 }, { 56, 16 }, { 40, 16 }, { 24, 16 },
+ { 4, 16 }, { 204, 32 }, { 188, 32 }, { 172, 32 }, { 156, 32 }, { 140, 32 }, { 124, 32 }, { 108, 32 }, { 92, 32 }, { 76, 32 }, { 60, 32 }, { 44, 32 }, { 28, 32 }, { 6, 32 },
+ { 224, 48 }, { 202, 48 }, { 180, 48 }, { 164, 48 }, { 148, 48 }, { 132, 48 }, { 116, 48 }, { 100, 48 }, { 84, 48 }, { 68, 48 }, { 52, 48 }, { 20, 48 }, { 10, 48 }, { 218, 64 },
+ { 198, 64 }, { 178, 64 }, { 112, 64 }, { 46, 64 }, { 26, 64 }, { 6, 64 }
+}, {
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
+ 1, 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1,
+ 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 1,
+ 1, 1, 4, 1, 1, 1
+} };
+
#elif defined (dzrgb60_ansi)
const is31_led g_is31_leds[DRIVER_LED_TOTAL] = {
{0, K_14, J_14, L_14},
@@ -453,69 +322,26 @@ const is31_led g_is31_leds[DRIVER_LED_TOTAL] = {
{0, K_16, J_16, L_16},
};
-rgb_led g_rgb_leds[DRIVER_LED_TOTAL] = {
- {{0|(13<<4)}, {16*13.5, 0}, 1},
- {{0|(12<<4)}, {16*12, 0}, 1},
- {{0|(11<<4)}, {16*11, 0}, 1},
- {{0|(10<<4)}, {16*10, 0}, 1},
- {{0|(9<<4)}, {16*9, 0}, 1},
- {{0|(8<<4)}, {16*8, 0}, 1},
- {{0|(7<<4)}, {16*7, 0}, 1},
- {{0|(6<<4)}, {16*6, 0}, 1},
- {{0|(5<<4)}, {16*5, 0}, 1},
- {{0|(4<<4)}, {16*4, 0}, 1},
- {{0|(3<<4)}, {16*3, 0}, 1},
- {{0|(2<<4)}, {16*2, 0}, 1},
- {{0|(1<<4)}, {16*1, 0}, 1},
- {{0|(0<<4)}, {16*0, 0}, 1},
- {{1|(13<<4)}, {16*13.75, 16}, 1},
- {{1|(12<<4)}, {16*12.5, 16}, 4},
- {{1|(11<<4)}, {16*11.5, 16}, 4},
- {{1|(10<<4)}, {16*10.5, 16}, 4},
- {{1|(9<<4)}, { 16*9.5, 16}, 4},
- {{1|(8<<4)}, { 16*8.5, 16}, 4},
- {{1|(7<<4)}, { 16*7.5, 16}, 4},
- {{1|(6<<4)}, { 16*6.5, 16}, 4},
- {{1|(5<<4)}, { 16*5.5, 16}, 4},
- {{1|(4<<4)}, { 16*4.5, 16}, 4},
- {{1|(3<<4)}, { 16*3.5, 16}, 4},
- {{1|(2<<4)}, { 16*2.5, 16}, 4},
- {{1|(1<<4)}, { 16*1.5, 16}, 4},
- {{1|(0<<4)}, { 16*0.25, 16}, 1},
- {{2|(13<<4)}, {16*13.375, 24}, 1},
- {{2|(11<<4)}, {16*11.75, 32}, 4},
- {{2|(10<<4)}, {16*10.75, 32}, 4},
- {{2|(9<<4)}, {16*9.75, 32}, 4},
- {{2|(8<<4)}, {16*8.75, 32}, 4},
- {{2|(7<<4)}, {16*7.75, 32}, 4},
- {{2|(6<<4)}, { 16*6.75, 32}, 4},
- {{2|(5<<4)}, { 16*5.75, 32}, 4},
- {{2|(4<<4)}, { 16*4.75, 32}, 4},
- {{2|(3<<4)}, { 16*3.75, 32}, 4},
- {{2|(2<<4)}, { 16*2.75, 32}, 4},
- {{2|(1<<4)}, { 16*1.75, 32}, 4},
- {{2|(0<<4)}, { 16*0.375, 32}, 1},
- {{3|(11<<4)}, {16*13.125, 48}, 1},
- {{3|(10<<4)}, {16*11.25, 48}, 4},
- {{3|(9<<4)}, {16*10.25, 48}, 4},
- {{3|(8<<4)}, {16*9.25, 48}, 4},
- {{3|(7<<4)}, {16*8.25, 48}, 4},
- {{3|(6<<4)}, {16*7.25, 48}, 4},
- {{3|(5<<4)}, {16*6.25, 48}, 4},
- {{3|(4<<4)}, {16*5.25, 48}, 4},
- {{3|(3<<4)}, {16*4.25, 48}, 4},
- {{3|(2<<4)}, {16*3.25, 48}, 4},
- {{3|(1<<4)}, {16*1.25, 48}, 4},
- {{3|(0<<4)}, {16*0.625, 48}, 1},
- {{4|(13<<4)}, {16*13.875, 64}, 1},
- {{4|(11<<4)}, {16*12.625, 64}, 1},
- {{4|(10<<4)}, {16*11.375, 64}, 1},
- {{4|(9<<4)}, {16*10.125, 64}, 1},
- {{4|(5<<4)}, { 16*6.375, 64}, 4},
- {{4|(2<<4)}, { 16*2.625, 64}, 1},
- {{4|(1<<4)}, { 16*1.375, 64}, 1},
- {{4|(0<<4)}, { 16*0.125, 64}, 1},
-};
+led_config_t g_led_config = { {
+ { 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0 },
+ { 27, 26, 25, 24, 23, 22, 21, 20, 19, 18, 17, 16, 15, 14 },
+ { 40, 39, 38, 37, 36, 35, 34, 33, 32, 31, 30, 29, NO_LED, 28 },
+ { 52, 51, 50, 49, 48, 47, 46, 45, 44, 43, 42, 41, NO_LED, NO_LED },
+ { 60, 59, 58, NO_LED, NO_LED, 57, NO_LED, NO_LED, NO_LED, 56, 55, 54, NO_LED, 53 }
+}, {
+ { 216, 0 }, { 192, 0 }, { 176, 0 }, { 160, 0 }, { 144, 0 }, { 128, 0 }, { 112, 0 }, { 96, 0 }, { 80, 0 }, { 64, 0 }, { 48, 0 }, { 32, 0 }, { 16, 0 }, { 0, 0 },
+ { 220, 16 }, { 200, 16 }, { 184, 16 }, { 168, 16 }, { 152, 16 }, { 136, 16 }, { 120, 16 }, { 104, 16 }, { 88, 16 }, { 72, 16 }, { 56, 16 }, { 40, 16 }, { 24, 16 }, { 4, 16 },
+ { 214, 24 }, { 188, 32 }, { 172, 32 }, { 156, 32 }, { 140, 32 }, { 124, 32 }, { 108, 32 }, { 92, 32 }, { 76, 32 }, { 60, 32 }, { 44, 32 }, { 28, 32 }, { 6, 32 }, { 210, 48 },
+ { 180, 48 }, { 164, 48 }, { 148, 48 }, { 132, 48 }, { 116, 48 }, { 100, 48 }, { 84, 48 }, { 68, 48 }, { 52, 48 }, { 20, 48 }, { 10, 48 }, { 222, 64 }, { 202, 64 }, { 182, 64 },
+ { 162, 64 }, { 102, 64 }, { 42, 64 }, { 22, 64 }, { 2, 64 }
+}, {
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1,
+ 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 1,
+ 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 1, 1, 1,
+ 1, 4, 1, 1, 1
+} };
+
#else
const is31_led g_is31_leds[DRIVER_LED_TOTAL] = {
{0, K_14, J_14, L_14},
@@ -583,71 +409,26 @@ const is31_led g_is31_leds[DRIVER_LED_TOTAL] = {
{0, K_16, J_16, L_16},
};
-rgb_led g_rgb_leds[DRIVER_LED_TOTAL] = {
- {{0|(13<<4)}, {17.23*13, 0}, 1},
- {{0|(12<<4)}, {17.23*12, 0}, 1},
- {{0|(11<<4)}, {17.23*11, 0}, 1},
- {{0|(10<<4)}, {17.23*10, 0}, 1},
- {{0|(9<<4)}, {17.23*9, 0}, 1},
- {{0|(8<<4)}, {17.23*8, 0}, 1},
- {{0|(7<<4)}, {17.23*7, 0}, 1},
- {{0|(6<<4)}, { 17.23*6, 0}, 1},
- {{0|(5<<4)}, { 17.23*5, 0}, 1},
- {{0|(4<<4)}, { 17.23*4, 0}, 1},
- {{0|(3<<4)}, { 17.23*3, 0}, 1},
- {{0|(2<<4)}, { 17.23*2, 0}, 1},
- {{0|(1<<4)}, { 17.23*1, 0}, 1},
- {{0|(0<<4)}, { 17.23*0, 0}, 1},
- {{1|(13<<4)}, {17.23*13, 16}, 1},
- {{1|(12<<4)}, {17.23*12, 16}, 4},
- {{1|(11<<4)}, {17.23*11, 16}, 4},
- {{1|(10<<4)}, {17.23*10, 16}, 4},
- {{1|(9<<4)}, {17.23*9, 16}, 4},
- {{1|(8<<4)}, {17.23*8, 16}, 4},
- {{1|(7<<4)}, {17.23*7, 16}, 4},
- {{1|(6<<4)}, { 17.23*6, 16}, 4},
- {{1|(5<<4)}, { 17.23*5, 16}, 4},
- {{1|(4<<4)}, { 17.23*4, 16}, 4},
- {{1|(3<<4)}, { 17.23*3, 16}, 4},
- {{1|(2<<4)}, { 17.23*2, 16}, 4},
- {{1|(1<<4)}, { 17.23*1, 16}, 4},
- {{1|(0<<4)}, { 17.23*0, 16}, 1},
- {{2|(13<<4)}, {17.23*13, 32}, 1},
- {{2|(11<<4)}, {17.23*11, 32}, 4},
- {{2|(10<<4)}, {17.23*10, 32}, 4},
- {{2|(9<<4)}, {17.23*9, 32}, 4},
- {{2|(8<<4)}, {17.23*8, 32}, 4},
- {{2|(7<<4)}, {17.23*7, 32}, 4},
- {{2|(6<<4)}, { 17.23*6, 32}, 4},
- {{2|(5<<4)}, { 17.23*5, 32}, 4},
- {{2|(4<<4)}, { 17.23*4, 32}, 4},
- {{2|(3<<4)}, { 17.23*3, 32}, 4},
- {{2|(2<<4)}, { 17.23*2, 32}, 4},
- {{2|(1<<4)}, { 17.23*1, 32}, 4},
- {{2|(0<<4)}, { 17.23*0, 32}, 1},
- {{3|(13<<4)}, {17.23*13, 48}, 1},
- {{3|(11<<4)}, {17.23*11, 48}, 4},
- {{3|(10<<4)}, {17.23*10, 48}, 4},
- {{3|(9<<4)}, {17.23*9, 48}, 4},
- {{3|(8<<4)}, {17.23*8, 48}, 4},
- {{3|(7<<4)}, {17.23*7, 48}, 4},
- {{3|(6<<4)}, { 17.23*6, 48}, 4},
- {{3|(5<<4)}, { 17.23*5, 48}, 4},
- {{3|(4<<4)}, { 17.23*4, 48}, 4},
- {{3|(3<<4)}, { 17.23*3, 48}, 4},
- {{3|(2<<4)}, { 17.23*2, 48}, 4},
- {{3|(1<<4)}, { 17.23*1, 48}, 4},
- {{3|(0<<4)}, { 17.23*0, 48}, 1},
- {{4|(13<<4)}, {17.23*13, 64}, 1},
- {{4|(11<<4)}, {17.23*11, 64}, 1},
- {{4|(10<<4)}, {17.23*10, 64}, 1},
- {{4|(9<<4)}, {17.23*9, 64}, 1},
- {{4|(8<<4)}, {17.23*8, 64}, 1},
- {{4|(5<<4)}, { 17.23*5, 64}, 4},
- {{4|(2<<4)}, { 17.23*2, 64}, 1},
- {{4|(1<<4)}, { 17.23*1, 64}, 1},
- {{4|(0<<4)}, { 17.23*0, 64}, 1},
-};
+led_config_t g_led_config = { {
+ { 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0 },
+ { 27, 26, 25, 24, 23, 22, 21, 20, 19, 18, 17, 16, 15, 14 },
+ { 40, 39, 38, 37, 36, 35, 34, 33, 32, 31, 30, 29, NO_LED, 28 },
+ { 53, 52, 51, 50, 49, 48, 47, 46, 45, 44, 43, 42, NO_LED, 41 },
+ { 62, 61, 60, NO_LED, NO_LED, 59, NO_LED, NO_LED, 58, 57, 56, 55, NO_LED, 54 }
+}, {
+ { 223, 0 }, { 206, 0 }, { 189, 0 }, { 172, 0 }, { 155, 0 }, { 137, 0 }, { 120, 0 }, { 103, 0 }, { 86, 0 }, { 68, 0 }, { 51, 0 }, { 34, 0 }, { 17, 0 }, { 0, 0 },
+ { 223, 16 }, { 206, 16 }, { 189, 16 }, { 172, 16 }, { 155, 16 }, { 137, 16 }, { 120, 16 }, { 103, 16 }, { 86, 16 }, { 68, 16 }, { 51, 16 }, { 34, 16 }, { 17, 16 }, { 0, 16 },
+ { 223, 32 }, { 189, 32 }, { 172, 32 }, { 155, 32 }, { 137, 32 }, { 120, 32 }, { 103, 32 }, { 86, 32 }, { 68, 32 }, { 51, 32 }, { 34, 32 }, { 17, 32 }, { 0, 32 }, { 223, 48 },
+ { 189, 48 }, { 172, 48 }, { 155, 48 }, { 137, 48 }, { 120, 48 }, { 103, 48 }, { 86, 48 }, { 68, 48 }, { 51, 48 }, { 34, 48 }, { 17, 48 }, { 0, 48 }, { 223, 64 }, { 189, 64 },
+ { 172, 64 }, { 155, 64 }, { 137, 64 }, { 86, 64 }, { 34, 64 }, { 17, 64 }, { 0, 64 }
+}, {
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1,
+ 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 1,
+ 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 1, 1,
+ 1, 1, 1, 4, 1, 1, 1
+} };
+
#endif
void matrix_init_kb(void) {
diff --git a/keyboards/dztech/dz60rgb/keymaps/ansi/keymap.c b/keyboards/dztech/dz60rgb/keymaps/ansi/keymap.c
index 741fc55fb9..584f035ef4 100644
--- a/keyboards/dztech/dz60rgb/keymaps/ansi/keymap.c
+++ b/keyboards/dztech/dz60rgb/keymaps/ansi/keymap.c
@@ -38,11 +38,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TRNS, KC_TRNS, KC_TRNS, TO(0), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
};
+extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
- rgb_led led;
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
- led = g_rgb_leds[i];
- if (HAS_FLAGS(led.flags, LED_FLAG_MODIFIER)) {
+ if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
rgb_matrix_set_color( i, red, green, blue );
}
}
diff --git a/keyboards/dztech/dz60rgb/keymaps/hhkb/keymap.c b/keyboards/dztech/dz60rgb/keymaps/hhkb/keymap.c
index 1f3807c3b7..5a7a56801a 100644
--- a/keyboards/dztech/dz60rgb/keymaps/hhkb/keymap.c
+++ b/keyboards/dztech/dz60rgb/keymaps/hhkb/keymap.c
@@ -39,11 +39,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
};
+extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
- rgb_led led;
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
- led = g_rgb_leds[i];
- if (HAS_FLAGS(led.flags, LED_FLAG_MODIFIER)) {
+ if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
rgb_matrix_set_color( i, red, green, blue );
}
}
diff --git a/keyboards/dztech/dz60rgb/keymaps/hhkb_iso/keymap.c b/keyboards/dztech/dz60rgb/keymaps/hhkb_iso/keymap.c
index 4575eb19d5..34c1752ffa 100644
--- a/keyboards/dztech/dz60rgb/keymaps/hhkb_iso/keymap.c
+++ b/keyboards/dztech/dz60rgb/keymaps/hhkb_iso/keymap.c
@@ -39,11 +39,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TRNS, KC_TRNS, KC_TRNS, TO(0), KC_TRNS, KC_TRNS, KC_TRNS),
};
+extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
- rgb_led led;
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
- led = g_rgb_leds[i];
- if (HAS_FLAGS(led.flags, LED_FLAG_MODIFIER)) {
+ if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
rgb_matrix_set_color( i, red, green, blue );
}
}
diff --git a/keyboards/dztech/dz60rgb/keymaps/iso/keymap.c b/keyboards/dztech/dz60rgb/keymaps/iso/keymap.c
index 5e38848035..3a90d2f335 100644
--- a/keyboards/dztech/dz60rgb/keymaps/iso/keymap.c
+++ b/keyboards/dztech/dz60rgb/keymaps/iso/keymap.c
@@ -38,11 +38,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TRNS, KC_TRNS, KC_TRNS, TO(0), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
};
+extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
- rgb_led led;
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
- led = g_rgb_leds[i];
- if (HAS_FLAGS(led.flags, LED_FLAG_MODIFIER)) {
+ if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
rgb_matrix_set_color( i, red, green, blue );
}
}
diff --git a/keyboards/dztech/dz60rgb/keymaps/mekanist/keymap.c b/keyboards/dztech/dz60rgb/keymaps/mekanist/keymap.c
index 3dfa783744..a6d1e226bd 100644
--- a/keyboards/dztech/dz60rgb/keymaps/mekanist/keymap.c
+++ b/keyboards/dztech/dz60rgb/keymaps/mekanist/keymap.c
@@ -50,40 +50,36 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
-void rgb_matrix_layer_helper(uint8_t red, uint8_t green, uint8_t blue, bool default_layer)
-{
- rgb_led led;
-
- for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
- led = g_rgb_leds[i];
-
- if (HAS_FLAGS(led.flags, LED_FLAG_MODIFIER)) {
- rgb_matrix_set_color( i, red, green, blue );
- }
- }
+extern led_config_t g_led_config;
+void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
+ for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
+ if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
+ rgb_matrix_set_color( i, red, green, blue );
+ }
+ }
}
void rgb_matrix_indicators_user(void)
{
uint8_t this_led = host_keyboard_leds();
-
+
if (!g_suspend_state) {
switch (biton32(layer_state)) {
case _LAYER1:
rgb_matrix_layer_helper(0xFF, 0x00, 0x00, false); break;
-
+
case _LAYER2:
rgb_matrix_layer_helper(0x00, 0xFF, 0x00, false); break;
-
+
case _LAYER4:
rgb_matrix_layer_helper(0xFF, 0xFF, 0x00, false); break;
}
}
-
+
if (this_led & (1 << USB_LED_CAPS_LOCK)) {
rgb_matrix_set_color(40, 0xFF, 0xFF, 0xFF);
}
-
+
switch (biton32(layer_state)) {
case _LAYER3:
if (this_led & (1 << USB_LED_NUM_LOCK)) {
@@ -91,7 +87,7 @@ void rgb_matrix_indicators_user(void)
} else {
rgb_matrix_set_color(13, 0x00, 0x00, 0x00);
}
-
+
rgb_matrix_set_color(0, 0x00, 0xFF, 0x00);
rgb_matrix_set_color(1, 0x00, 0x00, 0x00);
rgb_matrix_set_color(1, 0x00, 0xFF, 0x00);