config.h 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. /*
  2. Copyright 2019 westfoxtrot
  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. This program is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  10. GNU General Public License for more details.
  11. You should have received a copy of the GNU General Public License
  12. along with this program. If not, see <http://www.gnu.org/licenses/>.
  13. */
  14. #pragma once
  15. #include "config_common.h"
  16. /* USB Device descriptor parameter */
  17. #define VENDOR_ID 0x21FF
  18. #define PRODUCT_ID 0xAA01
  19. #define DEVICE_VER 0x0001
  20. #define MANUFACTURER westfoxtrot
  21. #define PRODUCT aanzee
  22. #define DESCRIPTION QMK Firmware for the Aanzee PCB
  23. /* key matrix size */
  24. #define MATRIX_ROWS 5
  25. #define MATRIX_COLS 16
  26. // ROWS: Top to bottom, COLS: Left to right
  27. #define MATRIX_ROW_PINS {B4,D7,D6,D4,B3}
  28. #define MATRIX_COL_PINS {D2,D1,D0,D3,D5,C7,C6,B6,B5,F0,F1,F4,F5,F6,F7,B0}
  29. #define UNUSED_PINS
  30. /* COL2ROW or ROW2COL */
  31. #define DIODE_DIRECTION COL2ROW
  32. #define BACKLIGHT_PIN B7
  33. #define BACKLIGHT_BREATHING
  34. #define BACKLIGHT_LEVELS 5
  35. #define RGB_DI_PIN E6
  36. #ifdef RGB_DI_PIN
  37. #define RGBLED_NUM 9
  38. #define RGBLIGHT_HUE_STEP 12
  39. #define RGBLIGHT_SAT_STEP 25
  40. #define RGBLIGHT_VAL_STEP 12
  41. #define RGBLIGHT_LIMIT_VAL 255 /* The maximum brightness level */
  42. #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
  43. /*== all animations enable ==*/
  44. #define RGBLIGHT_ANIMATIONS
  45. /*== or choose animations ==*/
  46. // #define RGBLIGHT_EFFECT_BREATHING
  47. // #define RGBLIGHT_EFFECT_RAINBOW_MOOD
  48. // #define RGBLIGHT_EFFECT_RAINBOW_SWIRL
  49. // #define RGBLIGHT_EFFECT_SNAKE
  50. // #define RGBLIGHT_EFFECT_KNIGHT
  51. // #define RGBLIGHT_EFFECT_CHRISTMAS
  52. // #define RGBLIGHT_EFFECT_STATIC_GRADIENT
  53. // #define RGBLIGHT_EFFECT_RGB_TEST
  54. // #define RGBLIGHT_EFFECT_ALTERNATING
  55. #endif
  56. #define RGBW
  57. /* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
  58. #define DEBOUNCING_DELAY 5
  59. /* define if matrix has ghost (lacks anti-ghosting diodes) */
  60. //#define MATRIX_HAS_GHOST
  61. /* number of backlight levels */
  62. /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
  63. #define LOCKING_SUPPORT_ENABLE
  64. /* Locking resynchronize hack */
  65. #define LOCKING_RESYNC_ENABLE
  66. /* If defined, GRAVE_ESC will always act as ESC when CTRL is held.
  67. * This is userful for the Windows task manager shortcut (ctrl+shift+esc).
  68. */
  69. #define GRAVE_ESC_CTRL_OVERRIDE
  70. /*
  71. * Force NKRO
  72. *
  73. * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
  74. * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
  75. * makefile for this to work.)
  76. *
  77. * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
  78. * until the next keyboard reset.
  79. *
  80. * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
  81. * fully operational during normal computer usage.
  82. *
  83. * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
  84. * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
  85. * bootmagic, NKRO mode will always be enabled until it is toggled again during a
  86. * power-up.
  87. *
  88. */
  89. //#define FORCE_NKRO
  90. /*
  91. * Magic Key Options
  92. *
  93. * Magic keys are hotkey commands that allow control over firmware functions of
  94. * the keyboard. They are best used in combination with the HID Listen program,
  95. * found here: https://www.pjrc.com/teensy/hid_listen.html
  96. *
  97. * The options below allow the magic key functionality to be changed. This is
  98. * useful if your keyboard/keypad is missing keys and you want magic key support.
  99. *
  100. */
  101. //dynamic keymap and via support
  102. #define DYNAMIC_KEYMAP_LAYER_COUNT 4
  103. // EEPROM usage
  104. // TODO: refactor with new user EEPROM code (coming soon)
  105. #define EEPROM_MAGIC 0x451F
  106. #define EEPROM_MAGIC_ADDR 32
  107. // Bump this every time we change what we store
  108. // This will automatically reset the EEPROM with defaults
  109. // and avoid loading invalid data from the EEPROM
  110. #define EEPROM_VERSION 0x08
  111. #define EEPROM_VERSION_ADDR 34
  112. // Dynamic keymap starts after EEPROM version
  113. #define DYNAMIC_KEYMAP_EEPROM_ADDR 35
  114. // Dynamic macro starts after dynamic keymaps (35+(4*10*6*2)) = (35+480)
  115. #define DYNAMIC_KEYMAP_MACRO_EEPROM_ADDR 675 // **** CHANGE THIS BASED ON MATRIX_ROWS & MATRIX_COLS ****
  116. #define DYNAMIC_KEYMAP_MACRO_EEPROM_SIZE 349 // **** CHANGE THIS BASED ON 1024-DYNAMIC_KEYMAP_MACRO_EEPROM_ADDR ****
  117. #define DYNAMIC_KEYMAP_MACRO_COUNT 16