]> git.donarmstrong.com Git - qmk_firmware.git/blob - keyboards/treadstone32/config.h
Replace DEBOUNCING_DELAY (deprecated) with DEBOUNCE (#5997)
[qmk_firmware.git] / keyboards / treadstone32 / config.h
1 /*
2 Copyright 2019 marksard
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
18 #pragma once
19
20 #include "config_common.h"
21
22 /* USB Device descriptor parameter */
23 #define VENDOR_ID       0xFEED
24 #define PRODUCT_ID      0xDFA5
25 #define DEVICE_VER      0x0010
26 #define MANUFACTURER    marksard
27 #define PRODUCT         treadstone32
28 #define DESCRIPTION     Minimal Symmetrical staggered 32-Key Keyboard
29
30 /* key matrix size */
31 #define MATRIX_ROWS 8
32 #define MATRIX_COLS 5
33
34 /*
35  * Keyboard Matrix Assignments
36  *
37  * Change this to how you wired your keyboard
38  * COLS: AVR pins used for columns, left to right
39  * ROWS: AVR pins used for rows, top to bottom
40  * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
41  *                  ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
42  *
43 */
44 #define MATRIX_ROW_PINS { F1, F0, E6, B2, B4, D7, D6, D4 }
45 #define MATRIX_COL_PINS { F4, F5, F6, F7, C7 }
46 #define UNUSED_PINS
47
48 /* COL2ROW, ROW2COL, or CUSTOM_MATRIX */
49 #define DIODE_DIRECTION COL2ROW
50
51 /* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
52 #define DEBOUNCE 5
53
54 /* define if matrix has ghost (lacks anti-ghosting diodes) */
55 //#define MATRIX_HAS_GHOST
56
57 /* ws2812 RGB LED */
58 #define RGB_DI_PIN D3
59 #define RGBLIGHT_TIMER
60 #define ws2812_PORTREG  PORTD
61 #define ws2812_DDRREG   DDRD
62
63 #define RGBLED_NUM 6
64
65 #ifndef IOS_DEVICE_ENABLE
66   #define RGBLIGHT_LIMIT_VAL 200
67   #define RGBLIGHT_VAL_STEP 17
68 #else
69   #define RGBLIGHT_LIMIT_VAL 50
70   #define RGBLIGHT_VAL_STEP 4
71 #endif
72 #define RGBLIGHT_HUE_STEP 10
73 #define RGBLIGHT_SAT_STEP 17
74
75 #if defined(RGBLIGHT_ENABLE) && !defined(IOS_DEVICE_ENABLE)
76 // USB_MAX_POWER_CONSUMPTION value for treadstone32 keyboard
77 //  120  RGBoff
78 //  330  RGB 6
79 //  300  RGB 32
80   #define USB_MAX_POWER_CONSUMPTION 400
81 #else
82   // fix iPhone and iPad power adapter issue
83   // iOS device need lessthan 100
84   #define USB_MAX_POWER_CONSUMPTION 100
85 #endif
86
87 /*
88  * Feature disable options
89  *  These options are also useful to firmware size reduction.
90  */
91
92 /* disable debug print */
93 //#define NO_DEBUG
94
95 /* disable print */
96 //#define NO_PRINT
97
98 /* disable action features */
99 //#define NO_ACTION_LAYER
100 //#define NO_ACTION_TAPPING
101 //#define NO_ACTION_ONESHOT
102 //#define NO_ACTION_MACRO
103 //#define NO_ACTION_FUNCTION