pico.h 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. #pragma once
  2. #include "helix.h"
  3. #ifndef SPLIT_KEYBOARD
  4. extern bool is_helix_master(void);
  5. #define is_keyboard_master() is_helix_master()
  6. #endif
  7. // Each keymap.c should use is_keyboard_master() instead of 'is_master', 'has_usb()'.
  8. // But keep 'is_master' for a while for backwards compatibility
  9. // for the old keymap.c.
  10. extern uint8_t is_master; // 'is_master' will be obsolete, it is recommended to use 'is_keyboard_master ()' instead.
  11. #define has_usb() is_keyboard_master()
  12. #ifndef FLIP_HALF
  13. // Standard Keymap
  14. // (TRRS jack on the left half is to the right, TRRS jack on the right half is to the left)
  15. #define LAYOUT( \
  16. L00, L01, L02, L03, L04, L05, R00, R01, R02, R03, R04, R05, \
  17. L10, L11, L12, L13, L14, L15, R10, R11, R12, R13, R14, R15, \
  18. L20, L21, L22, L23, L24, L25, R20, R21, R22, R23, R24, R25, \
  19. L30, L31, L32, L33, L34, L35, L36, R36, R30, R31, R32, R33, R34, R35 \
  20. ) { \
  21. { L00, L01, L02, L03, L04, L05, KC_NO }, \
  22. { L10, L11, L12, L13, L14, L15, KC_NO }, \
  23. { L20, L21, L22, L23, L24, L25, KC_NO }, \
  24. { L30, L31, L32, L33, L34, L35, L36 }, \
  25. { R05, R04, R03, R02, R01, R00, KC_NO }, \
  26. { R15, R14, R13, R12, R11, R10, KC_NO }, \
  27. { R25, R24, R23, R22, R21, R20, KC_NO }, \
  28. { R35, R34, R33, R32, R31, R30, R36 }, \
  29. }
  30. #else
  31. // Keymap with right side flipped
  32. // (TRRS jack on both halves are to the right)
  33. #define LAYOUT( \
  34. L00, L01, L02, L03, L04, L05, R00, R01, R02, R03, R04, R05, \
  35. L10, L11, L12, L13, L14, L15, R10, R11, R12, R13, R14, R15, \
  36. L20, L21, L22, L23, L24, L25, R20, R21, R22, R23, R24, R25, \
  37. L30, L31, L32, L33, L34, L35, L36, R36, R30, R31, R32, R33, R34, R35 \
  38. ) { \
  39. { L00, L01, L02, L03, L04, L05, KC_NO }, \
  40. { L10, L11, L12, L13, L14, L15, KC_NO }, \
  41. { L20, L21, L22, L23, L24, L25, KC_NO }, \
  42. { L30, L31, L32, L33, L34, L35, L36 }, \
  43. { KC_NO, R00, R01, R02, R03, R04, R05 }, \
  44. { KC_NO, R10, R11, R12, R13, R14, R15 }, \
  45. { KC_NO, R20, R21, R22, R23, R24, R25 }, \
  46. { R36, R30, R31, R32, R33, R34, R35 }, \
  47. }
  48. #endif