]> git.donarmstrong.com Git - qmk_firmware.git/blob - keyboards/zinc/rev1/config.h
Keyboard: Add new keyboard Zinc (#4245)
[qmk_firmware.git] / keyboards / zinc / rev1 / config.h
1 /*
2 Copyright 2012 Jun Wako <wakojun@gmail.com>
3 Copyright 2015 Jack Humbert
4
5 This program is free software: you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation, either version 2 of the License, or
8 (at your option) any later version.
9
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with this program.  If not, see <http://www.gnu.org/licenses/>.
17 */
18
19 #pragma once
20
21 //#ifndef REV1_CONFIG_H
22 //#define REV1_CONFIG_H
23
24 /* USB Device descriptor parameter */
25 #define VENDOR_ID       0xFEED
26 #define PRODUCT_ID      0x9991
27 #define DEVICE_VER      0x0001
28 #define MANUFACTURER    monksoffunk
29 #define PRODUCT         zinc rev.1
30 #define DESCRIPTION     A split keyboard 
31
32
33 #define PREVENT_STUCK_MODIFIERS
34 #define TAPPING_FORCE_HOLD
35 #define TAPPING_TERM 100
36
37 /* Use I2C or Serial */
38 //#define USE_I2C
39 #define USE_SERIAL
40 //#define USE_MATRIX_I2C
41
42 /* Select hand configuration */
43 #define MASTER_LEFT
44 //#define MASTER_RIGHT
45 //#define EE_HANDS
46
47
48 /* key matrix size */
49 // Rows are doubled-up
50   #define MATRIX_ROWS 8
51   #define MATRIX_ROW_PINS { F6, F7, B1, B3 }
52
53 // wiring of each half
54 #define MATRIX_COLS 6
55 #define MATRIX_COL_PINS { F4, D4, C6, D7, E6, B4 }
56
57 /* define if matrix has ghost */
58 //#define MATRIX_HAS_GHOST
59
60 /* number of backlight levels */
61 // #define BACKLIGHT_LEVELS 3
62
63 /* Set 0 if debouncing isn't needed */
64 #define DEBOUNCING_DELAY 5
65
66 /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
67 //#define LOCKING_SUPPORT_ENABLE
68 /* Locking resynchronize hack */
69 //#define LOCKING_RESYNC_ENABLE
70
71 /* key combination for command */
72 #define IS_COMMAND() ( \
73     keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
74 )
75
76 /* ws2812 RGB LED */
77 #define RGB_DI_PIN D3
78 #define RGBLIGHT_TIMER
79 //#define RGBLED_NUM 12    // Number of LEDs. see ./keymaps/default/config.h
80 #define ws2812_PORTREG  PORTD
81 #define ws2812_DDRREG   DDRD
82
83 // RGB LED support
84 //#define RGBLIGHT_ANIMATIONS : see ./rules.mk: LED_ANIMATIONS = yes or no
85 //    see ./rules.mk: LED_BACK_ENABLE or LED_UNDERGLOW_ENABLE set yes
86 #ifdef RGBLED_BACK
87   #define RGBLED_NUM 24
88 #else
89   #define RGBLED_NUM 6
90 #endif
91
92 #ifndef IOS_DEVICE_ENABLE
93   #if RGBLED_NUM <= 6
94     #define RGBLIGHT_LIMIT_VAL 255
95   #else
96     #if RGBLED_NUM <= 16
97       #define RGBLIGHT_LIMIT_VAL 130
98     #else
99       #define RGBLIGHT_LIMIT_VAL 120
100     #endif
101   #endif
102   #define RGBLIGHT_VAL_STEP 17
103 #else
104   #if RGBLED_NUM <= 6
105     #define RGBLIGHT_LIMIT_VAL 90
106   #else
107     #if RGBLED_NUM <= 16
108       #define RGBLIGHT_LIMIT_VAL 45
109     #else
110       #define RGBLIGHT_LIMIT_VAL 35
111     #endif
112   #endif
113   #define RGBLIGHT_VAL_STEP 4
114 #endif
115 #define RGBLIGHT_HUE_STEP 10
116 #define RGBLIGHT_SAT_STEP 17
117
118 #if defined(RGBLIGHT_ENABLE) && !defined(IOS_DEVICE_ENABLE)
119 // USB_MAX_POWER_CONSUMPTION value
120 //  120  RGBoff
121 //  330  RGB 6
122 //  300  RGB 32
123   #define USB_MAX_POWER_CONSUMPTION 400
124 #else
125   // fix iPhone and iPad power adapter issue
126   // iOS device need lessthan 100
127   #define USB_MAX_POWER_CONSUMPTION 100
128 #endif
129
130 /*
131  * Feature disable options
132  *  These options are also useful to firmware size reduction.
133  */
134
135 /* disable debug print */
136 // #define NO_DEBUG
137
138 /* disable print */
139 // #define NO_PRINT
140
141 /* disable action features */
142 //#define NO_ACTION_LAYER
143 //#define NO_ACTION_TAPPING
144 //#define NO_ACTION_ONESHOT
145 //#define NO_ACTION_MACRO
146 //#define NO_ACTION_FUNCTION
147
148
149 //#endif