You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

52 lines
1.5 KiB

  1. #ifndef LIGHTING_H
  2. #define LIGHTING_H
  3. // rgb_sequence[RGBLED_NUM]
  4. //
  5. // Array used for sequential lighting effects.
  6. //
  7. // Example LFK78 RevC+ RGB Map:
  8. // 27 29 10 9 8 7 6
  9. // 26 5
  10. // 25 4
  11. // 24 3
  12. // 23 22 21 20 14 15 11 1 2
  13. //
  14. // const uint8_t rgb_sequence[] = {
  15. // 27, 29, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1,
  16. // 11, 15, 14, 20, 21, 22, 23, 24, 25, 26
  17. // };
  18. extern const uint8_t rgb_sequence[RGBLED_NUM];
  19. // switch_matrices[]
  20. //
  21. // The ISSI matrices for switch backlighting
  22. //
  23. // Example LFK78 RevC+ - ISSI Device 0, banks 0 and 1:
  24. // switch_matrices[] = {0, 1};
  25. extern const uint8_t switch_matrices[];
  26. // rgb_matrices[]
  27. // The ISSI matrices for RGB Underglow
  28. //
  29. // Example LFK78 RevC+ - ISSI Device 3, banks 0 and 1:
  30. // rgb_matrices[] = {6, 7};
  31. extern const uint8_t rgb_matrices[];
  32. // switch_leds[MATRIX_ROWS][MATRIX_COLS]
  33. // Maps switch LEDs from Row/Col to ISSI matrix.
  34. // Value breakdown:
  35. // Bit | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
  36. // | | ISSI Col | ISSI Row |
  37. // | |
  38. // Device
  39. extern const uint8_t switch_leds[MATRIX_ROWS][MATRIX_COLS];
  40. void led_test(void);
  41. void force_issi_refresh(void);
  42. void set_backlight(uint8_t level);
  43. void set_underglow(uint8_t red, uint8_t green, uint8_t blue);
  44. void set_rgb(uint8_t rgb_led, uint8_t red, uint8_t green, uint8_t blue);
  45. void set_backlight_by_keymap(uint8_t col, uint8_t row);
  46. #endif