2
0

config.h 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. /*
  2. Copyright 2012 Jun Wako <wakojun@gmail.com>
  3. Copyright 2015 Jack Humbert
  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. 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. You should have received a copy of the GNU General Public License
  13. along with this program. If not, see <http://www.gnu.org/licenses/>.
  14. */
  15. #pragma once
  16. /* USB Device descriptor parameter */
  17. #define VENDOR_ID 0xFEED
  18. #define PRODUCT_ID 0x9991
  19. #define DEVICE_VER 0x0001
  20. #define MANUFACTURER monksoffunk
  21. #define PRODUCT zinc rev.A
  22. #define DESCRIPTION A split keyboard
  23. #define PREVENT_STUCK_MODIFIERS
  24. #define TAPPING_FORCE_HOLD
  25. #define TAPPING_TERM 100
  26. /* Use I2C or Serial */
  27. //#define USE_I2C
  28. #define USE_SERIAL
  29. //#define USE_MATRIX_I2C
  30. /* Select hand configuration */
  31. #define MASTER_LEFT
  32. //#define MASTER_RIGHT
  33. //#define EE_HANDS
  34. /* key matrix size */
  35. // Rows are doubled-up
  36. #define MATRIX_ROWS 8
  37. #define MATRIX_ROW_PINS { D4, C6, D7, E6 }
  38. // wiring of each half
  39. #define MATRIX_COLS 6
  40. #define MATRIX_COL_PINS { F4, F5, F6, F7, B1, B3}
  41. /* define if matrix has ghost */
  42. //#define MATRIX_HAS_GHOST
  43. /* number of backlight levels */
  44. // #define BACKLIGHT_LEVELS 3
  45. /* Set 0 if debouncing isn't needed */
  46. #define DEBOUNCING_DELAY 5
  47. /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
  48. //#define LOCKING_SUPPORT_ENABLE
  49. /* Locking resynchronize hack */
  50. //#define LOCKING_RESYNC_ENABLE
  51. /* ws2812 RGB LED */
  52. #define RGB_DI_PIN D3
  53. #define RGBLIGHT_TIMER
  54. //#define RGBLED_NUM 24 // Number of LEDs. see ./keymaps/default/config.h
  55. #define ws2812_PORTREG PORTD
  56. #define ws2812_DDRREG DDRD
  57. // RGB LED support
  58. //#define RGBLIGHT_ANIMATIONS : see ./rules.mk: LED_ANIMATIONS = yes or no
  59. // see ./rules.mk: LED_BACK_ENABLE or LED_UNDERGLOW_ENABLE set yes
  60. #ifdef RGBLED_BACK
  61. #define RGBLED_NUM 24
  62. #else
  63. #define RGBLED_NUM 6
  64. #endif
  65. #ifndef IOS_DEVICE_ENABLE
  66. #if RGBLED_NUM <= 6
  67. #define RGBLIGHT_LIMIT_VAL 255
  68. #else
  69. #if RGBLED_NUM <= 16
  70. #define RGBLIGHT_LIMIT_VAL 130
  71. #else
  72. #define RGBLIGHT_LIMIT_VAL 120
  73. #endif
  74. #endif
  75. #define RGBLIGHT_VAL_STEP 17
  76. #else
  77. #if RGBLED_NUM <= 6
  78. #define RGBLIGHT_LIMIT_VAL 90
  79. #else
  80. #if RGBLED_NUM <= 16
  81. #define RGBLIGHT_LIMIT_VAL 45
  82. #else
  83. #define RGBLIGHT_LIMIT_VAL 35
  84. #endif
  85. #endif
  86. #define RGBLIGHT_VAL_STEP 4
  87. #endif
  88. #define RGBLIGHT_HUE_STEP 10
  89. #define RGBLIGHT_SAT_STEP 17
  90. #if defined(RGBLIGHT_ENABLE) && !defined(IOS_DEVICE_ENABLE)
  91. // USB_MAX_POWER_CONSUMPTION value
  92. // 120 RGBoff
  93. // 330 RGB 6
  94. // 300 RGB 32
  95. #define USB_MAX_POWER_CONSUMPTION 400
  96. #else
  97. // fix iPhone and iPad power adapter issue
  98. // iOS device need lessthan 100
  99. #define USB_MAX_POWER_CONSUMPTION 100
  100. #endif
  101. /*
  102. * Feature disable options
  103. * These options are also useful to firmware size reduction.
  104. */
  105. /* disable debug print */
  106. // #define NO_DEBUG
  107. /* disable print */
  108. // #define NO_PRINT
  109. /* disable action features */
  110. //#define NO_ACTION_LAYER
  111. //#define NO_ACTION_TAPPING
  112. //#define NO_ACTION_ONESHOT
  113. //#define NO_ACTION_MACRO
  114. //#define NO_ACTION_FUNCTION