Skip to content

Commit

Permalink
Optional layout with backlit
Browse files Browse the repository at this point in the history
  • Loading branch information
Marco Pelegrini committed Nov 24, 2024
1 parent a20661f commit 72dda14
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 12 deletions.
8 changes: 1 addition & 7 deletions keyboards/marcopad/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
"diode_direction": "ROW2COL",
"features": {
"bootmagic": true,
"rgblight": true,
"combo": true,
"command": false,
"console": false,
"extrakey": false,
"mousekey": false,
"nkro": false
"rgblight": false
},
"matrix_pins": {
"cols": ["GP4", "GP26", "GP27"],
Expand Down
26 changes: 26 additions & 0 deletions keyboards/marcopad/keymaps/backlit/keymap.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
// Copyright (c) 2022 Marco Pelegrini <[email protected]>
// SPDX-License-Identifier: GPL-2.0-or-later

#include QMK_KEYBOARD_H

const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/*
* ┌───┬───┬───┐
* │ 7 │ 8 │ 9 │
* ├───┼───┼───┤
* │ 4 │ 5 │ 6 │
* ├───┼───┼───┤
* │ 1 │ 2 │ 3 │
* └───┴───┴───┘
*/
[0] = LAYOUT_ortho_3x3(
KC_P7, KC_P8, KC_P9,
KC_P4, KC_P5, KC_P6,
KC_P1, KC_P2, KC_P3
)
};

const uint16_t PROGMEM backlight_combo[] = {KC_P7, KC_P8, COMBO_END};
combo_t key_combos[] = {
COMBO(backlight_combo, UG_NEXT)
};
5 changes: 5 additions & 0 deletions keyboards/marcopad/keymaps/backlit/rules.mk
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Copyright (c) 2022 Marco Pelegrini <[email protected]>
# SPDX-License-Identifier: GPL-2.0-or-later

RGBLIGHT_ENABLE = yes
COMBO_ENABLE = yes
5 changes: 0 additions & 5 deletions keyboards/marcopad/keymaps/default/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,4 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_P4, KC_P5, KC_P6,
KC_P1, KC_P2, KC_P3
)
};

const uint16_t PROGMEM backlight_combo[] = {KC_P7, KC_P8, COMBO_END};
combo_t key_combos[] = {
COMBO(backlight_combo, UG_NEXT)
};

0 comments on commit 72dda14

Please sign in to comment.