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.

144 lines
4.1 KiB

5 years ago
  1. /*
  2. * Copyright 2018 Jack Humbert <jack.humb@gmail.com>
  3. *
  4. * This program is free software: you can redistribute it and/or modify
  5. * it under the terms of the GNU General Public License as published by
  6. * the Free Software Foundation, either version 2 of the License, or
  7. * (at your option) any later version.
  8. *
  9. * This program is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. * GNU General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU General Public License
  15. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  16. */
  17. #pragma once
  18. /* USB Device descriptor parameter */
  19. #define DEVICE_VER 0x0000
  20. #undef MATRIX_ROWS
  21. #undef MATRIX_COLS
  22. /* key matrix size */
  23. #define MATRIX_ROWS 8
  24. #define MATRIX_COLS 6
  25. /*
  26. * Keyboard Matrix Assignments
  27. *
  28. * Change this to how you wired your keyboard
  29. * COLS: AVR pins used for columns, left to right
  30. * ROWS: AVR pins used for rows, top to bottom
  31. * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
  32. * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
  33. *
  34. */
  35. #undef MATRIX_ROW_PINS
  36. #undef MATRIX_COL_PINS
  37. #define MATRIX_ROW_PINS { A10, A9, A8, B15, C13, C14, C15, A2 }
  38. #define MATRIX_COL_PINS { B11, B10, B2, B1, A7, B0 }
  39. #define NUMBER_OF_ENCODERS 1
  40. #define ENCODERS_PAD_A { B12 }
  41. #define ENCODERS_PAD_B { B13 }
  42. #define MUSIC_MAP
  43. #undef AUDIO_VOICES
  44. #undef C6_AUDIO
  45. #define A5_AUDIO
  46. #define DAC_OFF_VALUE 4095
  47. /* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
  48. #define DEBOUNCE 6
  49. /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
  50. //#define LOCKING_SUPPORT_ENABLE
  51. /* Locking resynchronize hack */
  52. //#define LOCKING_RESYNC_ENABLE
  53. /*
  54. * Force NKRO
  55. *
  56. * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
  57. * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
  58. * makefile for this to work.)
  59. *
  60. * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
  61. * until the next keyboard reset.
  62. *
  63. * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
  64. * fully operational during normal computer usage.
  65. *
  66. * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
  67. * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
  68. * bootmagic, NKRO mode will always be enabled until it is toggled again during a
  69. * power-up.
  70. *
  71. */
  72. //#define FORCE_NKRO
  73. /*
  74. * Feature disable options
  75. * These options are also useful to firmware size reduction.
  76. */
  77. /* disable debug print */
  78. //#define NO_DEBUG
  79. /* disable print */
  80. //#define NO_PRINT
  81. /* disable action features */
  82. //#define NO_ACTION_LAYER
  83. //#define NO_ACTION_TAPPING
  84. //#define NO_ACTION_ONESHOT
  85. //#define NO_ACTION_MACRO
  86. //#define NO_ACTION_FUNCTION
  87. /*
  88. * MIDI options
  89. */
  90. /* Prevent use of disabled MIDI features in the keymap */
  91. //#define MIDI_ENABLE_STRICT 1
  92. /* enable basic MIDI features:
  93. - MIDI notes can be sent when in Music mode is on
  94. */
  95. //#define MIDI_BASIC
  96. /* enable advanced MIDI features:
  97. - MIDI notes can be added to the keymap
  98. - Octave shift and transpose
  99. - Virtual sustain, portamento, and modulation wheel
  100. - etc.
  101. */
  102. //#define MIDI_ADVANCED
  103. /* override number of MIDI tone keycodes (each octave adds 12 keycodes and allocates 12 bytes) */
  104. //#define MIDI_TONE_KEYCODE_OCTAVES 1
  105. // #define WS2812_LED_N 2
  106. // #define RGBLED_NUM WS2812_LED_N
  107. // #define WS2812_TIM_N 2
  108. // #define WS2812_TIM_CH 2
  109. // #define PORT_WS2812 GPIOA
  110. // #define PIN_WS2812 1
  111. // #define WS2812_DMA_STREAM STM32_DMA1_STREAM2 // DMA stream for TIMx_UP (look up in reference manual under DMA Channel selection)
  112. //#define WS2812_DMA_CHANNEL 7 // DMA channel for TIMx_UP
  113. //#define WS2812_EXTERNAL_PULLUP
  114. #define DRIVER_ADDR_1 0b1010000
  115. #define DRIVER_ADDR_2 0b1010000 // this is here for compliancy reasons.
  116. #define DRIVER_COUNT 1
  117. #define DRIVER_1_LED_TOTAL 47
  118. #define DRIVER_LED_TOTAL DRIVER_1_LED_TOTAL
  119. #define RGB_MATRIX_KEYPRESSES