lfk78.h 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. #pragma once
  2. #include "quantum.h"
  3. #if defined(KEYBOARD_lfkeyboards_lfk78_revb)
  4. # include "revb.h"
  5. #elif defined(KEYBOARD_lfkeyboards_lfk78_revc)
  6. # include "revc.h"
  7. #elif defined(KEYBOARD_lfkeyboards_lfk78_revj)
  8. # include "revj.h"
  9. #endif
  10. typedef struct RGB_Color {
  11. uint16_t red;
  12. uint16_t green;
  13. uint16_t blue;
  14. } RGB_Color;
  15. typedef struct Layer_Info {
  16. uint32_t layer;
  17. uint32_t mask;
  18. RGB_Color color;
  19. } Layer_Info;
  20. extern const uint32_t layer_count;
  21. extern const Layer_Info layer_info[];
  22. enum action_functions {
  23. LFK_CLEAR = 0, // Resets all layers
  24. LFK_ESC_TILDE, // esc+lshift = ~
  25. LFK_SET_DEFAULT_LAYER, // changes and saves current base layer to eeprom
  26. LFK_CLICK_TOGGLE, // Adjusts click duration
  27. LFK_CLICK_FREQ_HIGHER, // Adjusts click frequency
  28. LFK_CLICK_FREQ_LOWER, // Adjusts click frequency
  29. LFK_CLICK_TIME_LONGER, // Adjusts click duration
  30. LFK_CLICK_TIME_SHORTER, // Adjusts click duration
  31. LFK_DEBUG_SETTINGS, // prints LED and click settings to HID
  32. LFK_LED_TEST // cycles through switch and RGB LEDs
  33. };
  34. #define CLICK_HZ 500
  35. #define CLICK_MS 2
  36. #define CLICK_ENABLED 0
  37. void reset_keyboard_kb(void);
  38. void click(uint16_t freq, uint16_t duration);