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.

43 lines
1.3 KiB

  1. #ifndef ARROW_PAD_H
  2. #define ARROW_PAD_H
  3. #include "quantum.h"
  4. #include "matrix.h"
  5. #include "keymap.h"
  6. #ifdef BACKLIGHT_ENABLE
  7. #include "backlight.h"
  8. #endif
  9. #include <avr/io.h>
  10. #include <stddef.h>
  11. // This is the 21-key keypad to 4x6 element matrix mapping
  12. #define LAYOUT( \
  13. KM_ESC, KM_TAB, KM_BSL, KM_ARR, \
  14. KM_NUM, KM_FSL, KM_AST, KM_MIN, \
  15. KM___7, KM___8, KM___9, KM_EQU, \
  16. KM___4, KM___5, KM___6, KM_PLS, \
  17. KM___1, KM___2, KM___3, ___ENT, \
  18. KM___0, _____0, KM_DOT, KM_ENT \
  19. ) { \
  20. { KM_ESC, KM_TAB, KM_BSL, KM_ARR }, \
  21. { KM_NUM, KM_FSL, KM_AST, KM_MIN }, \
  22. { KM___7, KM___8, KM___9, KM_EQU }, \
  23. { KM___4, KM___5, KM___6, KM_PLS }, \
  24. { KM___1, KM___2, KM___3, KC_NO }, \
  25. { KM___0, KC_NO, KM_DOT, KM_ENT } \
  26. }
  27. // This is the 21-key keypad to 2x11 element matrix mapping
  28. #define LAYOUT_pad21( \
  29. KM_ESC, KM_TAB, KM_BSL, KM_ARR, \
  30. KM_NUM, KM_FSL, KM_AST, KM_MIN, \
  31. KM___7, KM___8, KM___9, \
  32. KM___4, KM___5, KM___6, KM_PLS, \
  33. KM___1, KM___2, KM___3, \
  34. KM___0, KM_DOT, KM_ENT \
  35. ) { \
  36. { KM_ESC, KM_TAB, KM_BSL, KM_ARR, KM___7, KM___8, KM___9, KM_PLS, KM___1, KM___2, KM___3, }, \
  37. { KM_NUM, KM_FSL, KM_AST, KM_MIN, KM___4, KM___5, KM___6, KM_ENT, KC_NO, KM___0, KM_DOT, }, \
  38. }
  39. #endif