Enable default LED indicators, move layer indicator to board LED
This commit is contained in:
parent
bf3e3b4d3e
commit
96a7967e0e
@ -11,14 +11,11 @@
|
|||||||
|
|
||||||
enum custom_keycodes {
|
enum custom_keycodes {
|
||||||
PLACEHOLDER = SAFE_RANGE, // can always be here
|
PLACEHOLDER = SAFE_RANGE, // can always be here
|
||||||
VRSN,
|
|
||||||
DYNAMIC_MACRO_RANGE
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#include "dynamic_macro.h"
|
|
||||||
|
|
||||||
// [Info]
|
// [Info]
|
||||||
// Meh = LCtrl + LAlt + LShift
|
// Meh = LCtrl + LAlt + LShift
|
||||||
|
// L_X = Layer X
|
||||||
|
|
||||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||||
/* Keymap 0: WORKMAN-D Basic layer
|
/* Keymap 0: WORKMAN-D Basic layer
|
||||||
@ -37,7 +34,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
|||||||
* ,-------------. ,-------------.
|
* ,-------------. ,-------------.
|
||||||
* |L_NUMB| ` | | Home | End |
|
* |L_NUMB| ` | | Home | End |
|
||||||
* ,------|------|------| |------+------+------.
|
* ,------|------|------| |------+------+------.
|
||||||
* | | | App | | PgUp | | |
|
* | | | Alt | | PgUp | | |
|
||||||
* | Space|Backsp|------| |------| Del |Enter |
|
* | Space|Backsp|------| |------| Del |Enter |
|
||||||
* | |ace | LCmd | | PgDn | | |
|
* | |ace | LCmd | | PgDn | | |
|
||||||
* `--------------------' `--------------------'
|
* `--------------------' `--------------------'
|
||||||
@ -79,7 +76,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
|||||||
* | | | | 0 | . | | | | | | |
|
* | | | | 0 | . | | | | | | |
|
||||||
* `-----------------------------------' `----------------------------------'
|
* `-----------------------------------' `----------------------------------'
|
||||||
* ,-------------. ,-------------
|
* ,-------------. ,-------------
|
||||||
* | | | | | |
|
* | |NLock | | | |
|
||||||
* ,------|------|------| |------+------+------.
|
* ,------|------|------| |------+------+------.
|
||||||
* | | | | | | | |
|
* | | | | | | | |
|
||||||
* | | |------| |------| | |
|
* | | |------| |------| | |
|
||||||
@ -94,7 +91,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
|||||||
_______,_______,_______,KC_KP_4,KC_KP_5,KC_KP_6,
|
_______,_______,_______,KC_KP_4,KC_KP_5,KC_KP_6,
|
||||||
_______,_______,_______,KC_KP_1,KC_KP_2,KC_KP_3,KC_KP_ENTER,
|
_______,_______,_______,KC_KP_1,KC_KP_2,KC_KP_3,KC_KP_ENTER,
|
||||||
_______,_______,_______,KC_KP_0,KC_KP_DOT,
|
_______,_______,_______,KC_KP_0,KC_KP_DOT,
|
||||||
_______,_______,
|
_______,KC_NUM_LOCK,
|
||||||
_______,
|
_______,
|
||||||
_______,_______,_______,
|
_______,_______,_______,
|
||||||
// right hand
|
// right hand
|
||||||
@ -152,30 +149,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const uint16_t PROGMEM fn_actions[] = {
|
/*
|
||||||
[1] = ACTION_LAYER_TAP_TOGGLE(NUMB), // FN1 - Momentary Layer 1 (Numbers)
|
// Following disables the default LED indicators:
|
||||||
};
|
bool led_update_user(led_t led_state) {
|
||||||
|
|
||||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|
||||||
if (!process_record_dynamic_macro(keycode, record)) {
|
|
||||||
return false;
|
return false;
|
||||||
}
|
|
||||||
switch (keycode) {
|
|
||||||
case VRSN:
|
|
||||||
if (record->event.pressed) {
|
|
||||||
SEND_STRING (" <[ Dejvino's Keyboard ]> ");
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
/**/
|
||||||
// Runs just one time when the keyboard initializes.
|
|
||||||
void matrix_init_user(void) {
|
|
||||||
//set_unicode_input_mode(UC_LINX);
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
// Runs constantly in the background, in a loop.
|
// Runs constantly in the background, in a loop.
|
||||||
void matrix_scan_user(void) {
|
void matrix_scan_user(void) {
|
||||||
@ -183,17 +162,13 @@ void matrix_scan_user(void) {
|
|||||||
uint8_t layer = biton32(layer_state);
|
uint8_t layer = biton32(layer_state);
|
||||||
|
|
||||||
ergodox_board_led_off();
|
ergodox_board_led_off();
|
||||||
ergodox_right_led_1_off();
|
|
||||||
ergodox_right_led_2_off();
|
|
||||||
ergodox_right_led_3_off();
|
|
||||||
|
|
||||||
|
|
||||||
switch (layer) {
|
switch (layer) {
|
||||||
case FNCK:
|
case FNCK:
|
||||||
ergodox_right_led_1_on();
|
ergodox_board_led_on();
|
||||||
break;
|
break;
|
||||||
case NUMB:
|
case NUMB:
|
||||||
ergodox_right_led_2_on();
|
ergodox_board_led_on();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
Loading…
Reference in New Issue
Block a user