config.h 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. /* Copyright 2018 Christon DeWan (xton)
  2. * Copyright 2017 IslandMan93
  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. #include "config_common.h"
  19. /* USB Device descriptor parameter */
  20. #define VENDOR_ID 0xFEED
  21. #define PRODUCT_ID 0x1256
  22. #define DEVICE_VER 0x0001
  23. #define MANUFACTURER UniKeyboard
  24. #define PRODUCT diverge tm2
  25. #define DESCRIPTION Split 46 key keyboard
  26. /* key matrix size */
  27. #define MATRIX_ROWS 8
  28. #define MATRIX_COLS 6
  29. /*
  30. * Keyboard Matrix Assignments
  31. *
  32. * Change this to how you wired your keyboard
  33. * COLS: AVR pins used for columns, left to right
  34. * ROWS: AVR pins used for rows, top to bottom
  35. * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
  36. * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
  37. *
  38. */
  39. #define MATRIX_ROW_PINS { D7, E6, B4, B5 }
  40. #define MATRIX_COL_PINS { F6, F7, B1, B3, B2, B6 }
  41. #define UNUSED_PINS
  42. /* COL2ROW, ROW2COL, or CUSTOM_MATRIX */
  43. #define DIODE_DIRECTION ROW2COL
  44. /* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
  45. #define DEBOUNCING_DELAY 5
  46. /* number of backlight levels */
  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. /*
  52. * Magic Key Options
  53. *
  54. * Magic keys are hotkey commands that allow control over firmware functions of
  55. * the keyboard. They are best used in combination with the HID Listen program,
  56. * found here: https://www.pjrc.com/teensy/hid_listen.html
  57. *
  58. * The options below allow the magic key functionality to be changed. This is
  59. * useful if your keyboard/keypad is missing keys and you want magic key support.
  60. *
  61. */
  62. /* key combination for magic key command */
  63. #define IS_COMMAND() ( \
  64. keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
  65. )