Compare commits
27 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
71436db957 | ||
|
93871ba3e9 | ||
|
a139ad9db3 | ||
|
8a7dac1a97 | ||
|
48a992f1c0 | ||
|
170de1273c | ||
|
6d6d91c834 | ||
|
ce122c4981 | ||
|
cd3518b802 | ||
|
7ff4faf3be | ||
|
b8a0d3de3d | ||
|
132c44bab1 | ||
|
87faf55b01 | ||
|
f1612b7fa1 | ||
|
5dd4b2af53 | ||
|
7551e0bbc7 | ||
|
32ff7be266 | ||
|
df8e417032 | ||
|
c7e1b53913 | ||
|
e9a67f8fde | ||
|
265eca0f7c | ||
|
2e0c63e0af | ||
|
e11e4a91ac | ||
|
7d8f680b50 | ||
|
63852e7a68 | ||
|
fa1e674bbb | ||
|
0ad753d65a |
2
Makefile
2
Makefile
@ -578,7 +578,7 @@ lib/%:
|
||||
|
||||
git-submodule:
|
||||
git submodule sync --recursive
|
||||
git submodule update --init --recursive
|
||||
git submodule update --init --recursive --progress
|
||||
|
||||
ifdef SKIP_VERSION
|
||||
SKIP_GIT := yes
|
||||
|
@ -227,6 +227,11 @@ ifeq ($(strip $(HD44780_ENABLE)), yes)
|
||||
OPT_DEFS += -DHD44780_ENABLE
|
||||
endif
|
||||
|
||||
ifeq ($(strip $(DYNAMIC_KEYMAP_ENABLE)), yes)
|
||||
OPT_DEFS += -DDYNAMIC_KEYMAP_ENABLE
|
||||
SRC += $(QUANTUM_DIR)/dynamic_keymap.c
|
||||
endif
|
||||
|
||||
QUANTUM_SRC:= \
|
||||
$(QUANTUM_DIR)/quantum.c \
|
||||
$(QUANTUM_DIR)/keymap_common.c \
|
||||
|
@ -79,20 +79,23 @@ Your RGB lighting can be configured by placing these `#define`s in your `config.
|
||||
|
||||
## Animations
|
||||
|
||||
Not only can this lighting be whatever color you want, if `RGBLIGHT_ANIMATIONS` is defined, you also have a number of animation modes at your disposal:
|
||||
|
||||
|Mode |Description |
|
||||
|-----|---------------------|
|
||||
|1 |Solid color |
|
||||
|2-5 |Solid color breathing|
|
||||
|6-8 |Cycling rainbow |
|
||||
|9-14 |Swirling rainbow |
|
||||
|15-20|Snake |
|
||||
|21-23|Knight |
|
||||
|24 |Christmas |
|
||||
|25-34|Static gradient |
|
||||
|35 |RGB Test |
|
||||
|36 |Alternating |
|
||||
Not only can this lighting be whatever color you want,
|
||||
if `RGBLIGHT_EFFECT_xxxx` or `RGBLIGHT_ANIMATIONS` is defined, you also have a number of animation modes at your disposal:
|
||||
|
||||
|Mode number symbol |Additional number |Description |
|
||||
|-----------------------------|-------------------|---------------------------------------|
|
||||
|`RGBLIGHT_MODE_STATIC_LIGHT` | *None* |Solid color (this mode is always enabled) |
|
||||
|`RGBLIGHT_MODE_BREATHING` | 0,1,2,3 |Solid color breathing |
|
||||
|`RGBLIGHT_MODE_RAINBOW_MOOD` | 0,1,2 |Cycling rainbow |
|
||||
|`RGBLIGHT_MODE_RAINBOW_SWIRL`| 0,1,2,3,4,5 |Swirling rainbow |
|
||||
|`RGBLIGHT_MODE_SNAKE` | 0,1,2,3,4,5 |Snake |
|
||||
|`RGBLIGHT_MODE_KNIGHT` | 0,1,2 |Knight |
|
||||
|`RGBLIGHT_MODE_CHRISTMAS` | *None* |Christmas |
|
||||
|`RGBLIGHT_MODE_STATIC_GRADIENT`| 0,1,..,9 |Static gradient |
|
||||
|`RGBLIGHT_MODE_RGB_TEST` | *None* |RGB Test |
|
||||
|`RGBLIGHT_MODE_ALTERNATING` | *None* |Alternating |
|
||||
|
||||
|
||||
Check out [this video](https://youtube.com/watch?v=VKrpPAHlisY) for a demonstration.
|
||||
|
||||
@ -100,7 +103,16 @@ The following options can be used to tweak the various animations:
|
||||
|
||||
|Define |Default |Description |
|
||||
|------------------------------------|-------------|-------------------------------------------------------------------------------------|
|
||||
|`RGBLIGHT_ANIMATIONS` |*Not defined*|If defined, enables additional animation modes |
|
||||
|`RGBLIGHT_EFFECT_BREATHING` |*Not defined*|If defined, enable breathing animation mode. |
|
||||
|`RGBLIGHT_EFFECT_RAINBOW_MOOD` |*Not defined*|If defined, enable rainbow mood animation mode. |
|
||||
|`RGBLIGHT_EFFECT_RAINBOW_SWIRL` |*Not defined*|If defined, enable rainbow swirl animation mode. |
|
||||
|`RGBLIGHT_EFFECT_SNAKE` |*Not defined*|If defined, enable snake animation mode. |
|
||||
|`RGBLIGHT_EFFECT_KNIGHT` |*Not defined*|If defined, enable knight animation mode. |
|
||||
|`RGBLIGHT_EFFECT_CHRISTMAS` |*Not defined*|If defined, enable christmas animation mode. |
|
||||
|`RGBLIGHT_EFFECT_STATIC_GRADIENT` |*Not defined*|If defined, enable static gradient mode. |
|
||||
|`RGBLIGHT_EFFECT_RGB_TEST` |*Not defined*|If defined, enable RGB test animation mode. |
|
||||
|`RGBLIGHT_EFFECT_ALTERNATING` |*Not defined*|If defined, enable alternating animation mode. |
|
||||
|`RGBLIGHT_ANIMATIONS` |*Not defined*|If defined, enables all additional animation modes |
|
||||
|`RGBLIGHT_EFFECT_BREATHE_CENTER` |`1.85` |Used to calculate the curve for the breathing animation. Valid values are 1.0 to 2.7 |
|
||||
|`RGBLIGHT_EFFECT_BREATHE_MAX` |`255` |The maximum brightness for the breathing mode. Valid values are 1 to 255 |
|
||||
|`RGBLIGHT_EFFECT_SNAKE_LENGTH` |`4` |The number of LEDs to light up for the "Snake" animation |
|
||||
|
@ -22,6 +22,20 @@ Start by navigating to the `keymaps` folder for your keyboard.
|
||||
|
||||
Once you have the `keymaps` folder open you will want to create a copy of the `default` folder. We highly recommend you name your folder the same as your GitHub username, but you can use any name you want as long as it contains only lower case letters, numbers, and the underscore character.
|
||||
|
||||
To automate the process, you also have the option to run the `new_keymap.sh` script.
|
||||
|
||||
Navigate to the `qmk_firmware/util` directory and type the following:
|
||||
|
||||
```
|
||||
./new_keymap.sh <keyboard path> <username>
|
||||
```
|
||||
|
||||
For example, for a user named John, trying to make a new keymap for the 1up60hse, they would type in
|
||||
|
||||
```
|
||||
./new_keymap.sh 1upkeyboards/1up60hse john
|
||||
```
|
||||
|
||||
## Open `keymap.c` In Your Favorite Text Editor
|
||||
|
||||
Open up your `keymap.c`. Inside this file you'll find the structure that controls how your keyboard behaves. At the top of `keymap.c` there may be some defines and enums that make the keymap easier to read. Farther down you'll find a line that looks like this:
|
||||
|
@ -43,7 +43,11 @@ static const I2CConfig i2cconfig = {
|
||||
|
||||
void i2c_init(void)
|
||||
{
|
||||
palSetGroupMode(GPIOB, GPIOB_PIN6 | GPIOB_PIN7, 0, PAL_MODE_INPUT); // Try releasing special pins for a short time
|
||||
//palSetGroupMode(GPIOB, GPIOB_PIN6 | GPIOB_PIN7, 0, PAL_MODE_INPUT); // Try releasing special pins for a short time
|
||||
|
||||
palSetPadMode(GPIOB, 6, PAL_MODE_INPUT);
|
||||
palSetPadMode(GPIOB, 7, PAL_MODE_INPUT);
|
||||
|
||||
chThdSleepMilliseconds(10);
|
||||
|
||||
palSetPadMode(GPIOB, 6, PAL_MODE_ALTERNATE(4) | PAL_STM32_OTYPE_OPENDRAIN | PAL_STM32_PUPDR_PULLUP);
|
||||
|
@ -24,7 +24,7 @@
|
||||
*/
|
||||
|
||||
#include "ch.h"
|
||||
#include <hal.h>
|
||||
#include "hal.h"
|
||||
|
||||
#ifndef I2C_DRIVER
|
||||
#define I2C_DRIVER I2CD1
|
||||
|
@ -77,7 +77,7 @@ uint8_t g_twi_transfer_buffer[20];
|
||||
uint8_t g_pwm_buffer[DRIVER_COUNT][192];
|
||||
bool g_pwm_buffer_update_required = false;
|
||||
|
||||
uint8_t g_led_control_registers[DRIVER_COUNT][24] = { { 0 }, { 0 } };
|
||||
uint8_t g_led_control_registers[DRIVER_COUNT][24] = { { 0 } };
|
||||
bool g_led_control_registers_update_required = false;
|
||||
|
||||
void IS31FL3733_write_register( uint8_t addr, uint8_t reg, uint8_t data )
|
||||
@ -159,7 +159,7 @@ void IS31FL3733_init( uint8_t addr )
|
||||
// Select PG3
|
||||
IS31FL3733_write_register( addr, ISSI_COMMANDREGISTER, ISSI_PAGE_FUNCTION );
|
||||
// Set global current to maximum.
|
||||
IS31FL3733_write_register( addr, ISSI_REG_GLOBALCURRENT, 0xFF );
|
||||
IS31FL3733_write_register( addr, ISSI_REG_GLOBALCURRENT, 0x03 );
|
||||
// Disable software shutdown.
|
||||
IS31FL3733_write_register( addr, ISSI_REG_CONFIGURATION, 0x01 );
|
||||
|
||||
|
@ -48,6 +48,166 @@ void IS31FL3733_set_led_control_register( uint8_t index, bool red, bool green, b
|
||||
void IS31FL3733_update_pwm_buffers( uint8_t addr1, uint8_t addr2 );
|
||||
void IS31FL3733_update_led_control_registers( uint8_t addr1, uint8_t addr2 );
|
||||
|
||||
#ifdef IS31FL3737
|
||||
|
||||
#define A_1 0x00
|
||||
#define A_2 0x01
|
||||
#define A_3 0x02
|
||||
#define A_4 0x03
|
||||
#define A_5 0x04
|
||||
#define A_6 0x05
|
||||
#define A_7 0x08
|
||||
#define A_8 0x09
|
||||
#define A_9 0x0A
|
||||
#define A_10 0x0B
|
||||
#define A_11 0x0C
|
||||
#define A_12 0x0D
|
||||
|
||||
#define B_1 0x10
|
||||
#define B_2 0x11
|
||||
#define B_3 0x12
|
||||
#define B_4 0x13
|
||||
#define B_5 0x14
|
||||
#define B_6 0x15
|
||||
#define B_7 0x18
|
||||
#define B_8 0x19
|
||||
#define B_9 0x1A
|
||||
#define B_10 0x1B
|
||||
#define B_11 0x1C
|
||||
#define B_12 0x1D
|
||||
|
||||
#define C_1 0x20
|
||||
#define C_2 0x21
|
||||
#define C_3 0x22
|
||||
#define C_4 0x23
|
||||
#define C_5 0x24
|
||||
#define C_6 0x25
|
||||
#define C_7 0x28
|
||||
#define C_8 0x29
|
||||
#define C_9 0x2A
|
||||
#define C_10 0x2B
|
||||
#define C_11 0x2C
|
||||
#define C_12 0x2D
|
||||
|
||||
#define D_1 0x30
|
||||
#define D_2 0x31
|
||||
#define D_3 0x32
|
||||
#define D_4 0x33
|
||||
#define D_5 0x34
|
||||
#define D_6 0x35
|
||||
#define D_7 0x38
|
||||
#define D_8 0x39
|
||||
#define D_9 0x3A
|
||||
#define D_10 0x3B
|
||||
#define D_11 0x3C
|
||||
#define D_12 0x3D
|
||||
|
||||
#define E_1 0x40
|
||||
#define E_2 0x41
|
||||
#define E_3 0x42
|
||||
#define E_4 0x43
|
||||
#define E_5 0x44
|
||||
#define E_6 0x45
|
||||
#define E_7 0x48
|
||||
#define E_8 0x49
|
||||
#define E_9 0x4A
|
||||
#define E_10 0x4B
|
||||
#define E_11 0x4C
|
||||
#define E_12 0x4D
|
||||
|
||||
#define F_1 0x50
|
||||
#define F_2 0x51
|
||||
#define F_3 0x52
|
||||
#define F_4 0x53
|
||||
#define F_5 0x54
|
||||
#define F_6 0x55
|
||||
#define F_7 0x58
|
||||
#define F_8 0x59
|
||||
#define F_9 0x5A
|
||||
#define F_10 0x5B
|
||||
#define F_11 0x5C
|
||||
#define F_12 0x5D
|
||||
|
||||
#define G_1 0x60
|
||||
#define G_2 0x61
|
||||
#define G_3 0x62
|
||||
#define G_4 0x63
|
||||
#define G_5 0x64
|
||||
#define G_6 0x65
|
||||
#define G_7 0x68
|
||||
#define G_8 0x69
|
||||
#define G_9 0x6A
|
||||
#define G_10 0x6B
|
||||
#define G_11 0x6C
|
||||
#define G_12 0x6D
|
||||
|
||||
#define H_1 0x70
|
||||
#define H_2 0x71
|
||||
#define H_3 0x72
|
||||
#define H_4 0x73
|
||||
#define H_5 0x74
|
||||
#define H_6 0x75
|
||||
#define H_7 0x78
|
||||
#define H_8 0x79
|
||||
#define H_9 0x7A
|
||||
#define H_10 0x7B
|
||||
#define H_11 0x7C
|
||||
#define H_12 0x7D
|
||||
|
||||
#define I_1 0x80
|
||||
#define I_2 0x81
|
||||
#define I_3 0x82
|
||||
#define I_4 0x83
|
||||
#define I_5 0x84
|
||||
#define I_6 0x85
|
||||
#define I_7 0x88
|
||||
#define I_8 0x89
|
||||
#define I_9 0x8A
|
||||
#define I_10 0x8B
|
||||
#define I_11 0x8C
|
||||
#define I_12 0x8D
|
||||
|
||||
#define J_1 0x90
|
||||
#define J_2 0x91
|
||||
#define J_3 0x92
|
||||
#define J_4 0x93
|
||||
#define J_5 0x94
|
||||
#define J_6 0x95
|
||||
#define J_7 0x98
|
||||
#define J_8 0x99
|
||||
#define J_9 0x9A
|
||||
#define J_10 0x9B
|
||||
#define J_11 0x9C
|
||||
#define J_12 0x9D
|
||||
|
||||
#define K_1 0xA0
|
||||
#define K_2 0xA1
|
||||
#define K_3 0xA2
|
||||
#define K_4 0xA3
|
||||
#define K_5 0xA4
|
||||
#define K_6 0xA5
|
||||
#define K_7 0xA8
|
||||
#define K_8 0xA9
|
||||
#define K_9 0xAA
|
||||
#define K_10 0xAB
|
||||
#define K_11 0xAC
|
||||
#define K_12 0xAD
|
||||
|
||||
#define L_1 0xB0
|
||||
#define L_2 0xB1
|
||||
#define L_3 0xB2
|
||||
#define L_4 0xB3
|
||||
#define L_5 0xB4
|
||||
#define L_6 0xB5
|
||||
#define L_7 0xB8
|
||||
#define L_8 0xB9
|
||||
#define L_9 0xBA
|
||||
#define L_10 0xBB
|
||||
#define L_11 0xBC
|
||||
#define L_12 0xBD
|
||||
|
||||
#else
|
||||
|
||||
#define A_1 0x00
|
||||
#define A_2 0x01
|
||||
#define A_3 0x02
|
||||
@ -252,4 +412,6 @@ void IS31FL3733_update_led_control_registers( uint8_t addr1, uint8_t addr2 );
|
||||
#define L_15 0xBE
|
||||
#define L_16 0xBF
|
||||
|
||||
#endif
|
||||
|
||||
#endif // IS31FL3733_DRIVER_H
|
||||
|
@ -10,6 +10,6 @@ Hardware Availability: [Geekhack GB](https://geekhack.org/index.php?topic=96616.
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make dc60:default
|
||||
make alf/dc60:default
|
||||
|
||||
See [build environment setup](https://docs.qmk.fm/build_environment_setup.html) then the [make instructions](https://docs.qmk.fm/make_instructions.html) for more information.
|
||||
See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs).
|
15
keyboards/alf/x2/readme.md
Normal file
15
keyboards/alf/x2/readme.md
Normal file
@ -0,0 +1,15 @@
|
||||
# X2
|
||||
|
||||
![x2](https://cdn.shopify.com/s/files/1/1674/0405/products/1_088c2862-1f68-4fdd-a346-965208c3a3de_1024x1024.png?v=1511296076)
|
||||
|
||||
A customizable 60% keyboard.
|
||||
|
||||
Keyboard Maintainer: QMK Community
|
||||
Hardware Supported: ALF X2 60%
|
||||
Hardware Availability: [zFrontier](https://en.zfrontier.com/products/group-buy-alf-x2-60)
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make alf/x2:default
|
||||
|
||||
See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs).
|
1
keyboards/alf/x2/x2.c
Normal file
1
keyboards/alf/x2/x2.c
Normal file
@ -0,0 +1 @@
|
||||
#include "x2.h"
|
@ -1,5 +1,5 @@
|
||||
#ifndef ALF_X2_H
|
||||
#define ALF_X2_H
|
||||
#ifndef X2_H
|
||||
#define X2_H
|
||||
|
||||
#include "quantum.h"
|
||||
|
||||
@ -95,4 +95,4 @@
|
||||
{ K400, K401, KC_NO, K403, K404, KC_NO, K406, KC_NO, K408, KC_NO, K410, K411, K412, K413, K414 } \
|
||||
}
|
||||
|
||||
#endif
|
||||
#endif
|
@ -1 +0,0 @@
|
||||
#include "alf_x2.h"
|
@ -1,15 +0,0 @@
|
||||
# ALF X2
|
||||
|
||||
![alf_x2](https://cdn.shopify.com/s/files/1/1674/0405/products/1_088c2862-1f68-4fdd-a346-965208c3a3de_1024x1024.png?v=1511296076)
|
||||
|
||||
A customizable 60% keyboard.
|
||||
|
||||
Keyboard Maintainer: QMK Community
|
||||
Hardware Supported: ALF X2 60%
|
||||
Hardware Availability: [zFrontier](https://en.zfrontier.com/products/group-buy-alf-x2-60)
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make alf_x2:default
|
||||
|
||||
See [build environment setup](https://docs.qmk.fm/build_environment_setup.html) then the [make instructions](https://docs.qmk.fm/make_instructions.html) for more information.
|
@ -1,15 +0,0 @@
|
||||
BananaSplit60
|
||||
===
|
||||
|
||||
A 60% PCB featuring a split spacebar.
|
||||
|
||||
Keyboard Maintainer: QMK Community
|
||||
Hardware Supported: BananaSplit60 PCB
|
||||
Hardware Availability: https://thevankeyboards.com/products/gb-bananasplit-60-keyboard-kit?variant=42149104910
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make bananasplit:default
|
||||
|
||||
See [build environment setup](https://docs.qmk.fm/build_environment_setup.html) then the [make instructions](https://docs.qmk.fm/make_instructions.html) for more information.
|
||||
|
7
keyboards/contra/keymaps/erovia/config.h
Normal file
7
keyboards/contra/keymaps/erovia/config.h
Normal file
@ -0,0 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#define AUTO_SHIFT_TIMEOUT 150
|
||||
#define NO_AUTO_SHIFT_SPECIAL
|
||||
#define NO_AUTO_SHIFT_NUMERIC
|
||||
|
||||
#define TAPPING_TERM 200
|
163
keyboards/contra/keymaps/erovia/keymap.c
Normal file
163
keyboards/contra/keymaps/erovia/keymap.c
Normal file
@ -0,0 +1,163 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
extern keymap_config_t keymap_config;
|
||||
|
||||
enum planck_layers {
|
||||
_QWERTY,
|
||||
_COLEMAK,
|
||||
_LOWER,
|
||||
_RAISE,
|
||||
_ADJUST
|
||||
};
|
||||
|
||||
enum planck_keycodes {
|
||||
QWERTY = SAFE_RANGE,
|
||||
COLEMAK,
|
||||
LOWER,
|
||||
RAISE
|
||||
};
|
||||
|
||||
enum {
|
||||
TD_SPACE_CADET_SHIFT = 0,
|
||||
TD_SPACE_CADET_ENTER = 1
|
||||
};
|
||||
|
||||
qk_tap_dance_action_t tap_dance_actions[] = {
|
||||
[TD_SPACE_CADET_SHIFT] = ACTION_TAP_DANCE_DOUBLE(KC_LSFT, KC_LPRN),
|
||||
[TD_SPACE_CADET_ENTER] = ACTION_TAP_DANCE_DOUBLE(KC_ENT, KC_RPRN)
|
||||
};
|
||||
|
||||
#define TD_SHFT TD(TD_SPACE_CADET_SHIFT)
|
||||
#define TD_ENTR TD(TD_SPACE_CADET_ENTER)
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
/* Qwerty
|
||||
* ,-----------------------------------------------------------------------------------.
|
||||
* | ` | Q | W | E | R | T | Y | U | I | O | P | Bksp |
|
||||
* |------+------+------+------+------+-------------+------+------+------+------+------|
|
||||
* | Esc | A | S | D | F | G | H | J | K | L | ; | ' |
|
||||
* |------+------+------+------+------+------|------+------+------+------+------+------|
|
||||
* | Shift| Z | X | C | V | B | N | M | , | . | / |Enter |
|
||||
* |------+------+------+------+------+------+------+------+------+------+------+------|
|
||||
* | Ctrl | GUI | Alt | GUI |Lower | Tab |Space |Raise | Left | Down | Up |Right |
|
||||
* `-----------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_QWERTY] = LAYOUT_ortho_4x12(
|
||||
KC_GRV, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC,
|
||||
KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT,
|
||||
TD_SHFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, TD_ENTR,
|
||||
KC_LCTL, KC_LGUI, KC_LALT, KC_LGUI, LOWER, KC_TAB, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
|
||||
),
|
||||
|
||||
/* Colemak
|
||||
* ,-----------------------------------------------------------------------------------.
|
||||
* | ` | Q | W | F | P | B | J | L | U | Y | ; | Bksp |
|
||||
* |------+------+------+------+------+-------------+------+------+------+------+------|
|
||||
* | Ctrl | A | R | S | T | G | M | N | E | I | O | ' |
|
||||
* |------+------+------+------+------+------|------+------+------+------+------+------|
|
||||
* | Shift| Z | X | C | D | V | K | H | , | . | / |Enter |
|
||||
* |------+------+------+------+------+------+------+------+------+------+------+------|
|
||||
* | Ctrl | GUI | Alt | GUI |Lower | Tab |Space |Raise | Left | Down | Up |Right |
|
||||
* `-----------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_COLEMAK] = LAYOUT_ortho_4x12(
|
||||
KC_GRV, KC_Q, KC_W, KC_F, KC_P, KC_B, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_BSPC,
|
||||
KC_ESC, KC_A, KC_R, KC_S, KC_T, KC_G, KC_M, KC_N, KC_E, KC_I, KC_O, KC_QUOT,
|
||||
TD(TD_SPACE_CADET_SHIFT), KC_Z, KC_X, KC_C, KC_D, KC_V, KC_K, KC_H, KC_COMM, KC_DOT, KC_SLSH, TD(TD_SPACE_CADET_ENTER),
|
||||
KC_LCTL, KC_LGUI, KC_LALT, KC_LGUI, LOWER, KC_TAB, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
|
||||
),
|
||||
|
||||
/* Lower
|
||||
* ,-----------------------------------------------------------------------------------.
|
||||
* | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp |
|
||||
* |------+------+------+------+------+-------------+------+------+------+------+------|
|
||||
* | Del | F1 | F2 | F3 | F4 | F5 | F6 | _ | + | { | } | | |
|
||||
* |------+------+------+------+------+------|------+------+------+------+------+------|
|
||||
* | | F7 | F8 | F9 | F10 | F11 | F12 |ISO ~ |ISO | | Home | End | |
|
||||
* |------+------+------+------+------+------+------+------+------+------+------+------|
|
||||
* | | | | | | | | Next | Vol- | Vol+ | Play |
|
||||
* `-----------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_LOWER] = LAYOUT_ortho_4x12(
|
||||
KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC,
|
||||
KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE,
|
||||
_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, S(KC_NUHS), S(KC_NUBS), KC_HOME, KC_END, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY
|
||||
),
|
||||
|
||||
/* Raise
|
||||
* ,-----------------------------------------------------------------------------------.
|
||||
* | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
|
||||
* |------+------+------+------+------+-------------+------+------+------+------+------|
|
||||
* | Del | F1 | F2 | F3 | F4 | F5 | F6 | - | = | [ | ] | \ |
|
||||
* |------+------+------+------+------+------|------+------+------+------+------+------|
|
||||
* | | F7 | F8 | F9 | F10 | F11 | F12 |ISO # |ISO / |Pg Up |Pg Dn | |
|
||||
* |------+------+------+------+------+------+------+------+------+------+------+------|
|
||||
* | | | | | | | | Prev | Vol- | Mute | Stop |
|
||||
* `-----------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_RAISE] = LAYOUT_ortho_4x12(
|
||||
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC,
|
||||
KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS,
|
||||
_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NUHS, KC_NUBS, KC_PGUP, KC_PGDN, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, KC_MPRV, KC_VOLD, KC_MUTE, KC_MSTP
|
||||
),
|
||||
|
||||
/* Adjust (Lower + Raise)
|
||||
* ,-----------------------------------------------------------------------------------.
|
||||
* | | | | | | | | | | | | |
|
||||
* |------+------+------+------+------+-------------+------+------+------+------+------|
|
||||
* | | | | | | | |Qwerty|Colemk| | | |
|
||||
* |------+------+------+------+------+------|------+------+------+------+------+------|
|
||||
* | | | | | | | | | | | | |
|
||||
* |------+------+------+------+------+------+------+------+------+------+------+------|
|
||||
* | | | | | | | | | | | AuSh |
|
||||
* `-----------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_ADJUST] = LAYOUT_ortho_4x12(
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, QWERTY, COLEMAK, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_ASTG
|
||||
)
|
||||
|
||||
};
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
switch (keycode) {
|
||||
case QWERTY:
|
||||
if (record->event.pressed) {
|
||||
set_single_persistent_default_layer(_QWERTY);
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case COLEMAK:
|
||||
if (record->event.pressed) {
|
||||
set_single_persistent_default_layer(_COLEMAK);
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case LOWER:
|
||||
if (record->event.pressed) {
|
||||
layer_on(_LOWER);
|
||||
update_tri_layer(_LOWER, _RAISE, _ADJUST);
|
||||
} else {
|
||||
layer_off(_LOWER);
|
||||
update_tri_layer(_LOWER, _RAISE, _ADJUST);
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case RAISE:
|
||||
if (record->event.pressed) {
|
||||
layer_on(_RAISE);
|
||||
update_tri_layer(_LOWER, _RAISE, _ADJUST);
|
||||
} else {
|
||||
layer_off(_RAISE);
|
||||
update_tri_layer(_LOWER, _RAISE, _ADJUST);
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user