This commit is contained in:
James Guillochon 2025-07-06 12:35:00 -07:00
parent ca905c988c
commit 983239aebe
15 changed files with 823 additions and 43 deletions

View File

@ -0,0 +1,20 @@
/* Copyright 2024 Glorious, LLC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#define DRIVER_2_LED_TOTAL (56)
#define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL)

View File

@ -0,0 +1,19 @@
/* Copyright 2024 Glorious, LLC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#define DYNAMIC_KEYMAP_LAYER_COUNT 4

View File

@ -16,4 +16,4 @@
#pragma once
#define DYNAMIC_KEYMAP_LAYER_COUNT 3
#define DYNAMIC_KEYMAP_LAYER_COUNT 5

View File

@ -36,25 +36,27 @@
// Each layer gets a name for readability, which is then used in the keymap matrix below.
// The underscores don't mean anything - you can have a layer called STUFF or any other name.
enum custom_layers {
_BL, // Base Layer
_FL, // Function Layer
WIN_BL, // Windows Base Layer
WIN_FL, // Windows Function Layer
MACOS_BL, // Mac OS Base Layer
MACOS_FL, // Mac OS Function Layer
_CL // Custom Layer
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Base Layer (Default Layer) */
[_BL] = LAYOUT(
/* Windows Base Layer (Default Layer) */
[WIN_BL] = LAYOUT(
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_PSCR, KC_SCRL, KC_PAUS, KC_MUTE,
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_INS, KC_HOME, KC_PGUP, KC_NUM, KC_PSLS, KC_PAST, KC_PMNS,
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_END, KC_PGDN, KC_P7, KC_P8, KC_P9, KC_PPLS,
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_ENT, KC_P4, KC_P5, KC_P6,
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_P1, KC_P2, KC_P3, KC_PENT,
KC_LCTL, KC_LWIN, KC_LALT, KC_SPC, KC_RALT, MO(_FL), KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT
KC_LCTL, KC_LWIN, KC_LALT, KC_SPC, KC_RALT, MO(WIN_FL), KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT
),
/* Function Layer */
[_FL] = LAYOUT(
/* Windows Function Layer */
[WIN_FL] = LAYOUT(
QK_BOOT, KC_MYCM, KC_WHOM, KC_CALC, KC_MSEL, KC_MPRV, KC_MNXT, KC_MPLY, KC_MSTP, KC_MUTE, KC_VOLD, KC_VOLU, KC_PSCR, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
@ -64,6 +66,28 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
_______, GU_TOGG, _______, _______, _______, _______, _______, _______, RGB_RMOD, RGB_VAD, RGB_MOD, _______, _______
),
/* Mac OS Base Layer (Default Layer) */
[MACOS_BL] = LAYOUT(
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_PSCR, KC_SCRL, KC_PAUS, KC_MUTE,
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_INS, KC_HOME, KC_PGUP, KC_NUM, KC_PSLS, KC_PAST, KC_PMNS,
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_END, KC_PGDN, KC_P7, KC_P8, KC_P9, KC_PPLS,
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_ENT, KC_P4, KC_P5, KC_P6,
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_P1, KC_P2, KC_P3, KC_PENT,
KC_LCTL, KC_LOPT, KC_LCMD, KC_SPC, KC_RCMD, MO(MACOS_FL), KC_ROPT, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT
),
/* Mac OS Function Layer */
[MACOS_FL] = LAYOUT(
_______, KC_MYCM, KC_WHOM, KC_CALC, KC_MSEL, KC_MPRV, KC_MNXT, KC_MPLY, KC_MSTP, KC_MUTE, KC_VOLD, KC_VOLU, KC_PSCR, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, RGB_SAD, RGB_SAI, RGB_SPD, RGB_SPI, _______, _______, _______, _______, _______, _______, _______, RGB_VAI, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, RGB_RMOD, RGB_VAD, RGB_MOD, _______, _______
),
/* Custom Layer */
[_CL] = LAYOUT(
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
@ -78,8 +102,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
#if defined(ENCODER_MAP_ENABLE)
const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][NUM_DIRECTIONS] = {
[_BL] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
[_FL] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
[WIN_BL] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
[WIN_FL] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
[MACOS_BL] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
[MACOS_FL] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
[_CL] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
};
#endif // ENCODER_MAP_ENABLE
@ -125,3 +151,21 @@ void via_custom_value_command_kb(uint8_t *data, uint8_t length) {
}
#endif // VIA_ENABLE
#ifdef DIP_SWITCH_ENABLE
bool dip_switch_update_user(uint8_t index, bool active) {
if (index == 0) {
if (active){
layer_off(MACOS_BL);
layer_on(WIN_BL);
} else {
layer_off(WIN_BL);
layer_on(MACOS_BL);
}
}
return true;
}
#endif

View File

@ -35,8 +35,6 @@
#define AW20216S_EN_PIN C13
#define DRIVER_1_LED_TOTAL (67)
#define DRIVER_2_LED_TOTAL (56)
#define MATRIX_ROWS 17
#define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL)
#define DIP_SWITCH_PINS { A13 }

View File

@ -0,0 +1,20 @@
/* Copyright 2024 Glorious, LLC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#define DRIVER_2_LED_TOTAL (57) // ISO has one more LED than ANSI
#define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL)

View File

@ -146,20 +146,18 @@ const aw20216s_led_t PROGMEM g_aw20216s_leds[AW20216S_LED_COUNT] = {
{1, SW7_CS13, SW7_CS14, SW7_CS15}, // 111 SLED7
{1, SW8_CS13, SW8_CS14, SW8_CS15}, // 112 SLED8
{1, SW9_CS13, SW9_CS14, SW9_CS15}, // 113 SLED9
{1, SW10_CS13, SW10_CS14, SW10_CS15}, // 114 SLED10
{1, SW1_CS16, SW1_CS17, SW1_CS18}, // 115 SLED11
{1, SW2_CS16, SW2_CS17, SW2_CS18}, // 116 SLED12
{1, SW3_CS16, SW3_CS17, SW3_CS18}, // 117 SLED13
{1, SW4_CS16, SW4_CS17, SW4_CS18}, // 118 SLED14
{1, SW5_CS16, SW5_CS17, SW5_CS18}, // 119 SLED15
{1, SW6_CS16, SW6_CS17, SW6_CS18}, // 120 SLED16
{1, SW7_CS16, SW7_CS17, SW7_CS18}, // 121 SLED17
{1, SW8_CS16, SW8_CS17, SW8_CS18}, // 122 SLED18
{1, SW9_CS16, SW9_CS17, SW9_CS18}, // 123 SLED19
{1, SW10_CS16, SW10_CS17, SW10_CS18}, // 124 SLED20
{1, SW1_CS16, SW1_CS17, SW1_CS18}, // 114 SLED10
{1, SW2_CS16, SW2_CS17, SW2_CS18}, // 115 SLED11
{1, SW3_CS16, SW3_CS17, SW3_CS18}, // 116 SLED12
{1, SW4_CS16, SW4_CS17, SW4_CS18}, // 117 SLED13
{1, SW5_CS16, SW5_CS17, SW5_CS18}, // 118 SLED14
{1, SW6_CS16, SW6_CS17, SW6_CS18}, // 119 SLED15
{1, SW7_CS16, SW7_CS17, SW7_CS18}, // 120 SLED16
{1, SW8_CS16, SW8_CS17, SW8_CS18}, // 121 SLED17
{1, SW9_CS16, SW9_CS17, SW9_CS18}, // 122 SLED18
{1, SW10_CS1, SW10_CS2, SW10_CS3}, // 125 LOGO
{1, SW10_CS1, SW10_CS2, SW10_CS3}, // 123 LOGO
};
led_config_t g_led_config = {
@ -178,6 +176,9 @@ led_config_t g_led_config = {
{ 54, 71, 88, 57, 33, __, __, __},
{ 55, 72, 89, 103, 34, __, 52, __},
{ 56, 73, 90, 104, 35, 36, 91, __},
{ 105, 106, 107, 108, 109, 110, 111, 112},
{ 113, 114, 115, 116, 117, 118, 119, 120},
{ 121, 122, 123, __, __, __, __, __},
},
{
{0,0}, {21,0}, {31,0}, {42,0}, {52,0}, {68,0}, {78,0}, {89,0}, {99,0}, {115,0}, {125,0}, {136,0}, {146,0}, {159,0}, {169,0}, {180,0},
@ -187,8 +188,8 @@ led_config_t g_led_config = {
{1,52}, {12,52}, {23,52}, {34,52}, {44,52}, {55,52}, {65,52}, {76,52}, {86,52}, {96,52}, {107,52}, {117,52}, {137,52}, {169,52}, {193,52}, {203,52}, {214,52}, {224,58},
{1,64}, {14,64}, {27,64}, {66,64}, {105,64}, {118,64}, {131,64}, {145,64}, {159,64}, {169,64}, {180,64}, {198,64}, {214,64},
// Lef and right side lights
{0, 15}, {0, 20}, {0, 25}, {0, 30}, {0, 35}, {0, 40}, {0, 45}, {0, 50}, {0, 55}, {0, 60},
{224, 15}, {224, 20}, {224, 25}, {224, 30}, {224, 35}, {224, 40}, {224, 45}, {224, 50}, {224, 55}, {224, 60},
{0, 15}, {0, 20}, {0, 25}, {0, 30}, {0, 35}, {0, 40}, {0, 45}, {0, 50}, {0, 55},
{224, 15}, {224, 20}, {224, 25}, {224, 30}, {224, 35}, {224, 40}, {224, 45}, {224, 50}, {224, 55},
// logo
{214, 0},
},
@ -201,8 +202,8 @@ led_config_t g_led_config = {
4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
// Lef and right side lights
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2,
// Logo
8,
}

View File

@ -16,7 +16,7 @@
},
"matrix_pins": {
"cols": ["A0", "A1", "A2", "A3", "A4", "C1", "C2", "C3"],
"rows": ["B0", "B1", "B2", "B3", "B4", "B5", "C14", "C15", "B8", "B9", "B10", "C8", "C9", "A15"]
"rows": ["B0", "B1", "B2", "B3", "B4", "B5", "C14", "C15", "B8", "B9", "B10", "C8", "C9", "A15", "C4", "C5", "C6"]
},
"diode_direction": "COL2ROW",
"eeprom": {

View File

@ -0,0 +1,19 @@
/* Copyright 2024 Glorious, LLC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#define DYNAMIC_KEYMAP_LAYER_COUNT 4

View File

@ -0,0 +1,17 @@
RGB_MATRIX_EFFECT(DIRECT)
#ifdef RGB_MATRIX_CUSTOM_EFFECT_IMPLS
extern uint8_t color_buffer[RGB_MATRIX_LED_COUNT * 2];
extern uint8_t brightness_buffer[RGB_MATRIX_LED_COUNT];
static bool DIRECT(effect_params_t* params) {
RGB_MATRIX_USE_LIMITS(led_min, led_max);
for (uint8_t i = led_min; i < led_max; i++) {
RGB rgb = hsv_to_rgb((HSV){color_buffer[i * 2], color_buffer[i * 2 + 1], scale8(rgb_matrix_config.hsv.v, brightness_buffer[i])});
rgb_matrix_set_color(i, rgb.r, rgb.g, rgb.b);
}
return led_max < RGB_MATRIX_LED_COUNT;
}
#endif

View File

@ -0,0 +1,19 @@
/* Copyright 2024 Glorious, LLC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#define DYNAMIC_KEYMAP_LAYER_COUNT 5

View File

@ -0,0 +1,458 @@
{
"name": "GMMK3 100% ANSI",
"vendorId": "0x504B",
"productId": "0x320F",
"keycodes": [
"qmk_lighting"
],
"menus": [
{
"label": "Lighting",
"content": [
{
"label": "Backlight",
"content": [
{
"label": "Brightness",
"type": "range",
"options": [
0,
255
],
"content": [
"id_qmk_rgb_matrix_brightness",
3,
1
]
},
{
"label": "Effect",
"type": "dropdown",
"content": [
"id_qmk_rgb_matrix_effect",
3,
2
],
"options": [
[
"None",
0
],
[
"Solid Color",
1
],
[
"Breathing",
2
],
[
"Band Spiral Val",
3
],
[
"Cycle All",
4
],
[
"Cycle Left Right",
5
],
[
"Cycle Up Down",
6
],
[
"Rainbow Moving Chevron",
7
],
[
"Cycle Out In",
8
],
[
"Cycle Out In Dual",
9
],
[
"Cycle Pinwheel",
10
],
[
"Cycle Spiral",
11
],
[
"Dual Beacon",
12
],
[
"Rainbow Beacon",
13
],
[
"Jellybean Raindrops",
14
],
[
"Pixel Rain",
15
],
[
"Typing Heatmap",
16
],
[
"Digital Rain",
17
],
[
"Reactive Simple",
18
],
[
"Reactive Multiwide",
19
],
[
"Reactive Multinexus",
20
],
[
"Splash",
21
],
[
"Solid Splash",
22
],
[
"Direct",
23
]
]
},
{
"showIf": "{id_qmk_rgb_matrix_effect} > 1 && {id_qmk_rgb_matrix_effect} != 23",
"label": "Effect Speed",
"type": "range",
"options": [
0,
255
],
"content": [
"id_qmk_rgb_matrix_effect_speed",
3,
3
]
},
{
"showIf": "{id_qmk_rgb_matrix_effect} != 0 && {id_qmk_rgb_matrix_effect} != 23 && ( {id_qmk_rgb_matrix_effect} < 4 || {id_qmk_rgb_matrix_effect} == 18 || ({id_qmk_rgb_matrix_effect} > 17 && {id_qmk_rgb_matrix_effect} != 21) ) ",
"label": "Color",
"type": "color",
"content": [
"id_qmk_rgb_matrix_color",
3,
4
]
},
{
"showIf": "{id_qmk_rgb_matrix_effect} == 23",
"label": "Color Palette",
"type": "color-palette",
"content": [
"id_qmk_rgb_matrix_color",
3,
4
]
}
]
}
]
}
],
"matrix": {
"rows": 17,
"cols": 8
},
"layouts": {
"keymap": [
[
{
"c": "#777777"
},
"1,3\nl0",
{
"x": 1.0,
"c": "#cccccc"
},
"2,6\nl1",
"3,6\nl2",
"3,1\nl3",
"3,3\nl4",
{
"x": 0.5,
"c": "#777777"
},
"0,7\nl5",
"6,3\nl6",
"7,1\nl7",
"7,6\nl8",
{
"x": 0.5,
"c": "#cccccc"
},
"10,6\nl9",
"10,7\nl10",
"10,3\nl11",
"10,5\nl12",
{
"x": 0.25,
"c": "#777777"
},
"9,7\nl13",
"10,0\nl14",
"9,6\nl15",
{
"x": 3.25
},
"11,6\n\n\n\n\n\n\n\n\ne0"
],
[
{
"y": 0.25,
"c": "#cccccc"
},
"1,6\nl16",
"1,7\nl17",
"2,7\nl18",
"3,7\nl19",
"4,7\nl20",
"4,6\nl21",
"5,6\nl22",
"5,7\nl23",
"6,7\nl24",
"7,7\nl25",
"8,7\nl26",
"8,6\nl27",
"6,6\nl28",
{
"c": "#aaaaaa",
"w": 2
},
"10,1\nl29",
{
"x": 0.25,
"c": "#cccccc"
},
"7,5\nl30",
"0,2\nl31",
"1,5\nl32",
{
"x": 0.25
},
"11,4\nl33",
"12,4\nl34",
"13,4\nl35",
"13,5\nl36"
],
[
{
"c": "#aaaaaa",
"w": 1.5
},
"1,1\nl37",
{
"c": "#cccccc"
},
"1,0\nl38",
"2,0\nl39",
"3,0\nl40",
"4,0\nl41",
"4,1\nl42",
"5,1\nl43",
"5,0\nl44",
"6,0\nl45",
"7,0\nl46",
"8,0\nl47",
"8,1\nl48",
"6,1\nl49",
{
"w": 1.5
},
"10,2\nl50",
{
"x": 0.25
},
"6,5\nl51",
"12,6\nl52",
"2,5\nl53",
{
"x": 0.25
},
"11,0\nl54",
"12,0\nl55",
"13,0\nl56",
{
"h": 2
},
"11,3\nl57"
],
[
{
"c": "#aaaaaa",
"w": 1.75
},
"2,1\nl58",
{
"c": "#cccccc"
},
"1,2\nl59",
"2,2\nl60",
"3,2\nl61",
"4,2\nl62",
"4,3\nl63",
"5,3\nl64",
"5,2\nl65",
"6,2\nl66",
"7,2\nl67",
"8,2\nl68",
"8,3\nl69",
{
"c": "#777777",
"w": 2.25
},
"10,4\nl70",
{
"x": 3.5,
"c": "#cccccc"
},
"11,1\nl71",
"12,1\nl72",
"13,1\nl73"
],
[
{
"c": "#aaaaaa",
"w": 2.25
},
"0,0\nl74",
{
"c": "#cccccc"
},
"1,4\nl75",
"2,4\nl76",
"3,4\nl77",
"4,4\nl78",
"4,5\nl79",
"5,5\nl80",
"5,4\nl81",
"6,4\nl82",
"7,4\nl83",
"8,5\nl84",
{
"c": "#aaaaaa",
"w": 2.75
},
"9,1\nl85",
{
"x": 1.25,
"c": "#777777"
},
"3,5\nl86",
{
"x": 1.25,
"c": "#cccccc"
},
"11,2\nl87",
"12,2\nl88",
"13,2\nl89",
{
"h": 2
},
"13,6\nl90"
],
[
{
"c": "#aaaaaa",
"w": 1.25
},
"0,6\nl91",
{
"c": "#aaaaaa",
"w": 1.25
},
"9,0\nl92",
{
"c": "#aaaaaa",
"w": 1.25
},
"9,3\nl93",
{
"c": "#cccccc",
"w": 6.25
},
"9,4\nl94",
{
"c": "#aaaaaa",
"w": 1.25
},
"9,5\nl95",
{
"c": "#aaaaaa",
"w": 1.25
},
"9,2\nl96",
{
"c": "#aaaaaa",
"w": 1.25
},
"8,4\nl97",
{
"c": "#aaaaaa",
"w": 1.25
},
"0,4\nl98",
{
"x": 0.25,
"c": "#777777"
},
"0,3\nl99",
"7,3\nl100",
"0,5\nl101",
{
"x": 0.25,
"c": "#cccccc",
"w": 2
},
"12,3\nl102",
"13,3\nl103"
],
[
"14,0\nl104",
"14,1\nl105",
"14,2\nl106",
"14,3\nl107",
"14,4\nl108",
"14,5\nl109",
"14,6\nl110",
"14,7\nl111"
],
[
"15,0\nl112",
"15,2\nl113",
"15,3\nl114",
"15,4\nl115",
"15,5\nl116",
"15,6\nl117",
"15,7\nl118"
],
[
"16,0\nl119",
"16,1\nl120",
"16,2\nl121",
"16,3\nl122"
]
]
}
}

View File

@ -0,0 +1,160 @@
/* Copyright 2024 Glorious, LLC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include QMK_KEYBOARD_H
/*
*
* Esc F1 F2 F3 F4 F5 F6 F7 F8 F9 F10F11F12 PScScrPse Mut
*
*
* ` 1 2 3 4 5 6 7 8 9 0 - = Backsp InsHomPgU Num / * -
*
* Tab Q W E R T Y U I O P [ ] DelEndPgD 7 8 9
* Ent +
* Caps A S D F G H J K L ; ' # 4 5 6
*
* Shft \ Z X C V B N M , . / Shift 1 2 3
* Ent
* CtrlGUI Alt Alt Fn MenuCtrl 0 .
*
*/
// Each layer gets a name for readability, which is then used in the keymap matrix below.
// The underscores don't mean anything - you can have a layer called STUFF or any other name.
// Switching between Windows and Mac OS Base layers is done via DIP switch
enum custom_layers {
WIN_BL, // Windows Base Layer
WIN_FL, // Windows Function Layer
MACOS_BL, // Mac OS Base Layer
MACOS_FL // Mac OS Function Layer
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Windows Base Layer (Default Layer) */
[WIN_BL] = LAYOUT(
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_PSCR, KC_SCRL, KC_PAUS, KC_MUTE,
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_INS, KC_HOME, KC_PGUP, KC_NUM, KC_PSLS, KC_PAST, KC_PMNS,
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_DEL, KC_END, KC_PGDN, KC_P7, KC_P8, KC_P9, KC_PPLS,
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_P4, KC_P5, KC_P6,
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, KC_UP, KC_P1, KC_P2, KC_P3, KC_PENT,
KC_LCTL, KC_LWIN, KC_LALT, KC_SPC, KC_RALT, MO(WIN_FL), KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT
),
/* Windows Function Layer */
[WIN_FL] = LAYOUT(
_______, KC_MYCM, KC_WHOM, KC_CALC, KC_MSEL, KC_MPRV, KC_MNXT, KC_MPLY, KC_MSTP, KC_MUTE, KC_VOLD, KC_VOLU, KC_PSCR, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, RGB_SAD, RGB_SAI, RGB_SPD, RGB_SPI, _______, _______, _______, _______, _______, _______, _______, RGB_VAI, _______, _______, _______, _______,
_______, GU_TOGG, _______, _______, _______, _______, _______, _______, RGB_RMOD, RGB_VAD, RGB_MOD, _______, _______
),
/* Mac OS Base Layer (Default Layer) */
[MACOS_BL] = LAYOUT(
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_PSCR, KC_SCRL, KC_PAUS, KC_MUTE,
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_INS, KC_HOME, KC_PGUP, KC_NUM, KC_PSLS, KC_PAST, KC_PMNS,
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_DEL, KC_END, KC_PGDN, KC_P7, KC_P8, KC_P9, KC_PPLS,
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_P4, KC_P5, KC_P6,
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, KC_UP, KC_P1, KC_P2, KC_P3, KC_PENT,
KC_LCTL, KC_LOPT, KC_LCMD, KC_SPC, KC_RCMD, MO(MACOS_FL), KC_ROPT, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT
),
/* Mac OS Function Layer */
[MACOS_FL] = LAYOUT(
_______, KC_MYCM, KC_WHOM, KC_CALC, KC_MSEL, KC_MPRV, KC_MNXT, KC_MPLY, KC_MSTP, KC_MUTE, KC_VOLD, KC_VOLU, KC_PSCR, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, RGB_SAD, RGB_SAI, RGB_SPD, RGB_SPI, _______, _______, _______, _______, _______, _______, _______, RGB_VAI, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, RGB_RMOD, RGB_VAD, RGB_MOD, _______, _______
),
};
#if defined(ENCODER_MAP_ENABLE)
const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][NUM_DIRECTIONS] = {
[WIN_BL] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
[WIN_FL] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
[MACOS_BL] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
[MACOS_FL] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
[_CL] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
};
#endif // ENCODER_MAP_ENABLE
uint8_t color_buffer[RGB_MATRIX_LED_COUNT * 2] = {0};
uint8_t brightness_buffer[RGB_MATRIX_LED_COUNT] = {[0 ... RGB_MATRIX_LED_COUNT - 1] = 255};
#ifdef VIA_ENABLE
void via_custom_value_command_kb(uint8_t *data, uint8_t length) {
uint8_t channel_id = data[1];
if (channel_id != id_custom_channel) return;
uint8_t *command_id = &(data[0]);
uint8_t value_id = data[2];
uint8_t led_index = data[3];
uint8_t led_count = data[4];
switch (*command_id) {
case id_custom_set_value:
if (value_id == 1) {
memcpy(color_buffer + led_index * 2, data + 5, led_count * 2);
} else if (value_id == 2) {
memcpy(brightness_buffer + led_index, data + 5, led_count);
}
break;
case id_custom_get_value:
if (value_id == 1) {
memcpy(data + 5, color_buffer + led_index * 2, led_count * 2);
} else if (value_id == 2) {
memcpy(data + 5, brightness_buffer + led_index, led_count);
}
break;
case id_custom_save:
// optional: implement persistent save here
break;
default:
*command_id = id_unhandled;
break;
}
}
#endif // VIA_ENABLE
#ifdef DIP_SWITCH_ENABLE
bool dip_switch_update_user(uint8_t index, bool active) {
if (index == 0) {
if (active){
layer_off(MACOS_BL);
layer_on(WIN_BL);
} else {
layer_off(WIN_BL);
layer_on(MACOS_BL);
}
}
return true;
}
#endif

View File

@ -0,0 +1 @@
#include "animations/direct.h"

View File

@ -0,0 +1,4 @@
ENCODER_MAP_ENABLE = yes
VIA_ENABLE = yes
BOOTMAGIC_ENABLE = yes
RGB_MATRIX_CUSTOM_USER = yes