]> git.donarmstrong.com Git - qmk_firmware.git/blob - keyboards/helix/rev2/keymaps/froggy/config.h
Merge branch 'master' of github.com:qmk/qmk_firmware into hf/shinydox
[qmk_firmware.git] / keyboards / helix / rev2 / keymaps / froggy / config.h
1 /*
2 This is the c configuration file for the keymap
3
4 Copyright 2012 Jun Wako <wakojun@gmail.com>
5 Copyright 2015 Jack Humbert
6
7 This program is free software: you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation, either version 2 of the License, or
10 (at your option) any later version.
11
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 GNU General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program.  If not, see <http://www.gnu.org/licenses/>.
19 */
20
21 #ifndef CONFIG_USER_H
22 #define CONFIG_USER_H
23
24 #include "../../config.h"
25
26 /* Use I2C or Serial */
27
28 #define USE_I2C
29 #define USE_SERIAL
30 //#define USE_MATRIX_I2C
31
32 /* Select hand configuration */
33
34 #define MASTER_LEFT
35 // #define MASTER_RIGHT
36 // #define EE_HANDS
37
38 // Helix keyboard OLED support
39 //      see ./rules.mk: OLED_ENABLE=yes or no
40 #ifdef OLED_ENABLE
41   #define SSD1306OLED
42 #endif
43
44 /* Select rows configuration */
45 // Rows are 4 or 5
46 // #define HELIX_ROWS 5 see ./rules.mk
47
48 /* key matrix size */
49 // Rows are doubled-up
50 #if  HELIX_ROWS == 4
51   #define MATRIX_ROWS 8
52   #define MATRIX_COLS 7
53   #define MATRIX_ROW_PINS { D4, C6, D7, E6 }
54 #elif HELIX_ROWS == 5
55   #define MATRIX_ROWS 10
56   #define MATRIX_COLS 7
57   #define MATRIX_ROW_PINS { D4, C6, D7, E6, B4 }
58 #else
59   #error "expected HELIX_ROWS 4 or 5"
60 #endif
61
62 #define USE_SERIAL_PD2
63
64 #define PREVENT_STUCK_MODIFIERS
65 #define TAPPING_FORCE_HOLD
66 #define TAPPING_TERM 200
67 #define ONESHOT_TAP_TOGGLE 5  /* Tapping this number of times holds the key until tapped this number of times again. */
68 #define ONESHOT_TIMEOUT 5000  /* Time (in ms) before the one shot key is released */
69
70 // Helix keyboard RGB LED support
71 //#define RGBLIGHT_ANIMATIONS : see ./rules.mk: LED_ANIMATIONS = yes or no
72 //    see ./rules.mk: LED_BACK_ENABLE or LED_UNDERGLOW_ENABLE set yes
73 #ifdef RGBLED_BACK
74   #if HELIX_ROWS == 4
75     #define RGBLED_NUM 25
76   #elif HELIX_ROWS == 5
77     #define RGBLED_NUM 32
78   #endif
79 #else
80   #define RGBLED_NUM 6
81 #endif
82
83 #ifndef IOS_DEVICE_ENABLE
84   #if RGBLED_NUM <= 6
85     #define RGBLIGHT_LIMIT_VAL 255
86   #else
87     #if HELIX_ROWS == 5
88       #define RGBLIGHT_LIMIT_VAL 120
89     #else
90       #define RGBLIGHT_LIMIT_VAL 130
91     #endif
92   #endif
93   #define RGBLIGHT_VAL_STEP 17
94 #else
95   #if RGBLED_NUM <= 6
96     #define RGBLIGHT_LIMIT_VAL 90
97   #else
98     #if HELIX_ROWS == 5
99       #define RGBLIGHT_LIMIT_VAL 35
100     #else
101       #define RGBLIGHT_LIMIT_VAL 45
102     #endif
103   #endif
104   #define RGBLIGHT_VAL_STEP 4
105 #endif
106 #define RGBLIGHT_HUE_STEP 10
107 #define RGBLIGHT_SAT_STEP 17
108
109 #if defined(RGBLIGHT_ENABLE) && !defined(IOS_DEVICE_ENABLE)
110 // USB_MAX_POWER_CONSUMPTION value for Helix keyboard
111 //  120  RGBoff, OLEDoff
112 //  120  OLED
113 //  330  RGB 6
114 //  300  RGB 32
115 //  310  OLED & RGB 32
116   #define USB_MAX_POWER_CONSUMPTION 400
117 #else
118   // fix iPhone and iPad power adapter issue
119   // iOS device need lessthan 100
120   #define USB_MAX_POWER_CONSUMPTION 100
121 #endif
122
123 #endif /* CONFIG_USER_H */