Timber Wolf - updated via keymap, reduced eeprom writing from backlight code (#9876)
Co-authored-by: Ryan <fauxpark@gmail.com>
This commit is contained in:
parent
9758bcb28b
commit
08f31f664a
|
@ -62,7 +62,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
|
||||
/* Backlighting code used for caps lock indicator */
|
||||
#define BACKLIGHT_PIN C6
|
||||
#define BACKLIGHT_LEVELS 9
|
||||
#define BACKLIGHT_LEVELS 16
|
||||
|
||||
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
|
||||
// #define LOCKING_SUPPORT_ENABLE
|
||||
|
|
|
@ -19,10 +19,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
|||
/* Base */
|
||||
[0] = LAYOUT_all(
|
||||
KC_MUTE,KC_ESC ,KC_F1 ,KC_F2 ,KC_F3 ,KC_F4 ,KC_F5 ,KC_F6 ,KC_F7 ,KC_F8 ,KC_F9 ,KC_F10 ,KC_F11 ,KC_F12 ,KC_INS ,KC_HOME,KC_PGUP,
|
||||
RESET ,KC_GRV ,KC_1 ,KC_2 ,KC_3 ,KC_4 ,KC_5 ,KC_6 ,KC_7 ,KC_8 ,KC_9 ,KC_0 ,KC_MINS,KC_EQL ,KC_BSPC,KC_DEL ,KC_END ,KC_PGDN,
|
||||
BL_INC ,KC_TAB ,KC_Q ,KC_W ,KC_E ,KC_R ,KC_T ,KC_Y ,KC_U ,KC_I ,KC_O ,KC_P ,KC_LBRC,KC_RBRC,KC_BSLS ,KC_PSCR,KC_SLCK,
|
||||
BL_DEC ,KC_CAPS,KC_A ,KC_S ,KC_D ,KC_F ,KC_G ,KC_H ,KC_J ,KC_K ,KC_L ,KC_SCLN,KC_QUOT,KC_NUHS,KC_ENT ,KC_DEL ,KC_INS ,
|
||||
KC_F13 ,KC_LSFT,KC_NUBS,KC_Z ,KC_X ,KC_C ,KC_V ,KC_B ,KC_N ,KC_M ,KC_COMM,KC_DOT ,KC_SLSH,KC_RSFT,MO(1) ,KC_UP ,KC_UP ,KC_PENT,
|
||||
KC_F13 ,KC_GRV ,KC_1 ,KC_2 ,KC_3 ,KC_4 ,KC_5 ,KC_6 ,KC_7 ,KC_8 ,KC_9 ,KC_0 ,KC_MINS,KC_EQL ,KC_BSPC,KC_DEL ,KC_END ,KC_PGDN,
|
||||
KC_F14 ,KC_TAB ,KC_Q ,KC_W ,KC_E ,KC_R ,KC_T ,KC_Y ,KC_U ,KC_I ,KC_O ,KC_P ,KC_LBRC,KC_RBRC,KC_BSLS ,KC_DEL ,KC_PSCR,
|
||||
KC_F15 ,KC_CAPS,KC_A ,KC_S ,KC_D ,KC_F ,KC_G ,KC_H ,KC_J ,KC_K ,KC_L ,KC_SCLN,KC_QUOT,KC_NUHS,KC_ENT ,KC_DEL ,KC_PENT,
|
||||
KC_F16 ,KC_LSFT,KC_NUBS,KC_Z ,KC_X ,KC_C ,KC_V ,KC_B ,KC_N ,KC_M ,KC_COMM,KC_DOT ,KC_SLSH,KC_RSFT,MO(1) ,KC_UP ,KC_UP ,KC_PENT,
|
||||
MO(1) ,KC_LCTL,KC_LGUI,KC_LALT ,KC_SPC ,KC_RALT,KC_RGUI,KC_RCTL,KC_LEFT,KC_LEFT,KC_DOWN,KC_RGHT,KC_PENT
|
||||
),
|
||||
[1] = LAYOUT_all(
|
||||
|
@ -31,7 +31,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
|||
_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______ ,_______,_______,
|
||||
_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______ ,_______,_______,
|
||||
_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,
|
||||
MO(1) ,_______,_______,_______ ,_______ ,_______,_______,_______,_______,_______,_______,_______,_______
|
||||
_______,_______,_______,_______ ,_______ ,_______,_______,_______,_______,_______,_______,_______,_______
|
||||
),
|
||||
[2] = LAYOUT_all(
|
||||
_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______ ,_______,_______,_______,
|
||||
|
|
|
@ -25,11 +25,9 @@ SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
|
|||
NKRO_ENABLE = yes # USB Nkey Rollover
|
||||
BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
|
||||
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
|
||||
MIDI_ENABLE = no # MIDI support
|
||||
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
|
||||
AUDIO_ENABLE = no # Audio output on port C6
|
||||
FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
|
||||
HD44780_ENABLE = no # Enable support for HD44780 based LCDs
|
||||
BLUETOOTH_ENABLE = no # Enable Bluetooth
|
||||
AUDIO_ENABLE = no # Audio output
|
||||
ENCODER_ENABLE = yes # Enable encoder support
|
||||
LTO_ENABLE = yes
|
||||
|
||||
BACKLIGHT_DRIVER = pwm
|
||||
BACKLIGHT_DRIVER = pwm
|
||||
|
|
|
@ -18,10 +18,12 @@
|
|||
|
||||
bool led_update_kb(led_t led_state) {
|
||||
bool runDefault = led_update_user(led_state);
|
||||
if (led_state.caps_lock) {
|
||||
backlight_enable();
|
||||
} else {
|
||||
backlight_disable();
|
||||
}
|
||||
if(runDefault) {
|
||||
if (led_state.caps_lock) {
|
||||
backlight_level_noeeprom(get_backlight_level());
|
||||
} else {
|
||||
backlight_set(0);
|
||||
}
|
||||
}
|
||||
return runDefault;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue