qmk_firmware

QMK firmware for my keyboards (Corne, Sweep Ferris) and trackball (Ploopy Adept)
Log | Files | Refs | Submodules | LICENSE

config.h (5006B)


      1 /* Copyright 2021 3araht
      2  *
      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  *
      8  * This program is distributed in the hope that it will be useful,
      9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
     10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     11  * GNU General Public License for more details.
     12  *
     13  * You should have received a copy of the GNU General Public License
     14  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
     15  */
     16 #pragma once
     17 
     18 #define MASTER_RIGHT
     19 #ifndef MASTER_RIGHT
     20 //  SPLIT_HAND_MATRIX_GRID was initially designed to use with left hand side diode D35 mounted and not pressing K7 on the right hand side during boot. However when a USB cable is reconnected immediately, it fails. Decided to use "MASTER_RIGHT" to make it more reliable.
     21 #   define SPLIT_HAND_MATRIX_GRID B5, D0
     22 #   define SPLIT_HAND_MATRIX_GRID_LOW_IS_LEFT
     23 #endif
     24 
     25 #define SPLIT_USB_DETECT
     26 
     27 #ifdef RGB_MATRIX_ENABLE
     28 //  for all fingers used at once.
     29 #   define LED_HITS_TO_REMEMBER 10
     30 
     31 // the max brightness setting has no effect on rgb_matrix_set_color().
     32 // Use darker colors instead.
     33 /*              RGB darker COLORS             */
     34 #   define RGB_DARKWHITE 0x33, 0x33, 0x33
     35 #   define RGB_DARKRED 0x33, 0x0, 0x0
     36 #   define RGB_DARKCORAL 0x33, 0x18, 0xF
     37 #   define RGB_DARKORANGE 0x33, 0x19, 0x0
     38 #   define RGB_DARKGOLDENROD 0x2B, 0x21, 0x6
     39 #   define RGB_DARKGOLD 0x33, 0x2B, 0x0
     40 #   define RGB_DARKYELLOW 0x33, 0x33, 0x0
     41 #   define RGB_DARKCHARTREUSE 0x19, 0x33, 0x0
     42 #   define RGB_DARKGREEN 0x0, 0x33, 0x0
     43 #   define RGB_DARKSPRINGGREEN 0x0, 0x33, 0x19
     44 #   define RGB_DARKTURQUOISE 0xE, 0x16, 0x15
     45 #   define RGB_DARKTEAL 0x0, 0x19, 0x19
     46 #   define RGB_DARKCYAN 0x0, 0x33, 0x33
     47 #   define RGB_DARKAZURE 0x1E, 0x31, 0x33
     48 #   define RGB_DARKBLUE 0x0, 0x0, 0x33
     49 #   define RGB_DARKPURPLE 0x18, 0x0, 0x33
     50 #   define RGB_DARKMAGENTA 0x33, 0x0, 0x33
     51 #   define RGB_DARKPINK 0x33, 0x19, 0x26
     52 
     53 //  https://docs.qmk.fm/#/feature_rgb_matrix
     54 
     55 #   ifdef CONSOLE_ENABLE
     56 #       define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
     57 #   else
     58 // #define ENABLE_RGB_MATRIX_ALPHAS_MODS
     59 #       define ENABLE_RGB_MATRIX_GRADIENT_UP_DOWN
     60 #       define ENABLE_RGB_MATRIX_BREATHING
     61 #       define ENABLE_RGB_MATRIX_BAND_SAT
     62 #       define ENABLE_RGB_MATRIX_BAND_PINWHEEL_SAT
     63 #       define ENABLE_RGB_MATRIX_BAND_SPIRAL_SAT
     64 #       define ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT
     65 #       define ENABLE_RGB_MATRIX_RAINBOW_PINWHEELS
     66 // #define ENABLE_RGB_MATRIX_TYPING_HEATMAP
     67 #       define ENABLE_RGB_MATRIX_DIGITAL_RAIN
     68 #       define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
     69 #       define ENABLE_RGB_MATRIX_SOLID_REACTIVE
     70 #       define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
     71 #       define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
     72 #       define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS
     73 #       define ENABLE_RGB_MATRIX_SPLASH
     74 #       define ENABLE_RGB_MATRIX_SOLID_SPLASH
     75 //  RAINDROPS don't match well with layer LED indicator (oc) using rgb_matrix_set_color().
     76 // #define ENABLE_RGB_MATRIX_RAINDROPS
     77 // #define ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS
     78 #       define ENABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT
     79 #       define ENABLE_RGB_MATRIX_BAND_VAL
     80 #       define ENABLE_RGB_MATRIX_BAND_PINWHEEL_VAL
     81 #       define ENABLE_RGB_MATRIX_BAND_SPIRAL_VAL
     82 #       define ENABLE_RGB_MATRIX_CYCLE_ALL
     83 #       define ENABLE_RGB_MATRIX_CYCLE_UP_DOWN
     84 #       define ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON
     85 #       define ENABLE_RGB_MATRIX_CYCLE_OUT_IN
     86 #       define ENABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL
     87 #       define ENABLE_RGB_MATRIX_CYCLE_PINWHEEL
     88 #       define ENABLE_RGB_MATRIX_CYCLE_SPIRAL
     89 #       define ENABLE_RGB_MATRIX_DUAL_BEACON
     90 #       define ENABLE_RGB_MATRIX_RAINBOW_BEACON
     91 #       define ENABLE_RGB_MATRIX_HUE_BREATHING
     92 #       define ENABLE_RGB_MATRIX_HUE_PENDULUM
     93 #       define ENABLE_RGB_MATRIX_HUE_WAVE
     94 #       define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
     95 #       define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
     96 #       define ENABLE_RGB_MATRIX_MULTISPLASH
     97 #       define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH
     98 #       define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
     99 #   endif  // CONSOLE_ENABLE
    100 #endif  // RGB_MATRIX_ENABLE
    101 
    102 /*
    103  * Feature disable options
    104  *  These options are also useful to firmware size reduction.
    105  */
    106 
    107 /* disable debug print */
    108 //#define NO_DEBUG
    109 
    110 /* disable print */
    111 //#define NO_PRINT
    112 
    113 /* disable action features */
    114 //#define NO_ACTION_LAYER
    115 
    116 /* 2021/01/22 added to shrink firmware size */
    117 // NO_ACTION_TAPPING -1964 bytes, however, this disables Layer mods...
    118 // #define NO_ACTION_TAPPING
    119 // NO_ACTION_ONESHOT -388 bytes
    120 #define NO_ACTION_ONESHOT
    121 
    122 #ifdef MIDI_ENABLE
    123 #   define MIDI_ADVANCED
    124 // Initial velocity value (avoid using 127 since it is used as a special number in some sound sources.)
    125 #   define MIDI_INITIAL_VELOCITY 117
    126 #endif  //  MIDI_ENABLE