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.

84 lines
3.2 KiB

  1. /* Copyright 2021 3araht
  2. *
  3. * This program is free software: you can redistribute it and/or modify
  4. * it under the terms of the GNU General Public License as published by
  5. * the Free Software Foundation, either version 2 of the License, or
  6. * (at your option) any later version.
  7. *
  8. * This program is distributed in the hope that it will be useful,
  9. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. * GNU General Public License for more details.
  12. *
  13. * You should have received a copy of the GNU General Public License
  14. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  15. */
  16. #pragma once
  17. #include "quantum.h"
  18. /* This is a shortcut to help you visually see your layout.
  19. *
  20. * The first section contains all of the arguments representing the physical
  21. * layout of the board and position of the keys.
  22. *
  23. * The second converts the arguments into a two-dimensional array which
  24. * represents the switch matrix.
  25. */
  26. // oc: for Open Close selection pedal
  27. // fn: function layer
  28. #define LAYOUT( \
  29. l00, l01, l02, l03, l04, \
  30. l10, l11, l12, l13, l14, l15, l16, \
  31. l20, l21, l22, l23, l24, l25, l26, \
  32. l30, l31, l32, l33, l34, l35, l36, \
  33. l40, l41, l42, l43, l44, l45, l46, l47, \
  34. \
  35. oc, r00, r01, r02, r03, fn, \
  36. r10, r11, r12, r13, r14, ccw, cw,\
  37. r20, r21, r22, r23, r24, r25, \
  38. r30, r31, r32, r33, r34, r35, r36, r37, \
  39. r40, r41, r42, r43, r44, r45, r46, r47, \
  40. r50, r51, r52, r53, r54, r55, r56, r57, r58 \
  41. ) { \
  42. { l40, l00, l01, l02, l03, l04, KC_NO }, \
  43. { l10, l11, l12, l13, l14, l15, l16 }, \
  44. { l20, l21, l22, l23, l24, l25, l26 }, \
  45. { l30, l31, l32, l33, l34, l35, l36 }, \
  46. { l41, l42, l43, l44, l45, l46, l47 }, \
  47. { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, ccw, cw }, \
  48. { r50, r40, r31, r20, r10, r00, r30 }, \
  49. { r51, r41, r32, r21, r11, r01, oc }, \
  50. { r52, r42, r33, r22, r12, r02, fn }, \
  51. { r53, r43, r34, r23, r13, r03, r58 }, \
  52. { r54, r44, r35, r24, r14, r47, r57 }, \
  53. { r55, r45, r36, r25, r37, r46, r56 } \
  54. }
  55. // Uncomment below if a pedal used for Open/Close is normally-on type (such as Yamaha's.)
  56. // #define PEDAL_NORMALLY_CLOSED
  57. #ifdef PEDAL_NORMALLY_CLOSED
  58. # define MO_SWAP MO(_OPEN)
  59. # define DF_SWAP DF(_CLOSE)
  60. # define TG_SWAP TG(_OPEN)
  61. #else
  62. # define MO_SWAP MO(_CLOSE)
  63. # define DF_SWAP DF(_OPEN)
  64. # define TG_SWAP TG(_CLOSE)
  65. #endif
  66. // Long press: go to _FN layer, tap: MUTE
  67. #define FN_MUTE LT(_FN, KC_MUTE)
  68. #define DF_QWER DF(_QWERTY)
  69. #define MIS_EIS LT(_MISC,KC_LANG2)
  70. #define MIS_KAN LT(_MISC,KC_LANG1)
  71. // Overriding is_keyboard_left() in qmk_firmware/quantum/split_common/split_util.c to limit the handedness check only once.
  72. // reason: bandoMIneDonI has no space on right hand side to use "SPLIT_HAND_MATRIX_GRID".
  73. // However, It enables to decide the handedness by the HW by adding one condition: "not to press any keys (especially r30) dusing startup."
  74. bool is_keyboard_left(void);