Skip to content

Commit

Permalink
refactor: projectcain/vault35
Browse files Browse the repository at this point in the history
  • Loading branch information
lesshonor committed Nov 28, 2023
1 parent 2450fe2 commit 5c9c8fb
Show file tree
Hide file tree
Showing 7 changed files with 141 additions and 110 deletions.
45 changes: 45 additions & 0 deletions keyboards/projectcain/vault35/atmega32u4/info.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
{
"bootloader": "atmel-dfu",
"build": {
"lto": true
},
"encoder": {
"rotary": [
{"pin_a": "D7", "pin_b": "D6", "resolution": 2}
]
},
"features": {
"bootmagic": true,
"extrakey": true,
"encoder": true,
"mousekey": true,
"nkro": true,
"rgblight": true
},
"matrix_pins": {
"cols": ["B1", "D3", "F0", "F1", "F4", "F5", "F6", "F7", "C6", "B6", "B5"],
"rows": ["B4", "D4", "B0", "C7"]
},
"processor": "atmega32u4",
"rgblight": {
"animations": {
"alternating": true,
"breathing": true,
"christmas": true,
"knight": true,
"rainbow_mood": true,
"rainbow_swirl": true,
"rgb_test": true,
"snake": true,
"static_gradient": true,
"twinkle": true
},
"brightness_steps": 8,
"led_count": 12,
"saturation_steps": 8,
"sleep": true
},
"ws2812": {
"pin": "D5"
}
}
1 change: 1 addition & 0 deletions keyboards/projectcain/vault35/atmega32u4/rules.mk
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# This file intentionally left blank
36 changes: 0 additions & 36 deletions keyboards/projectcain/vault35/config.h

This file was deleted.

113 changes: 69 additions & 44 deletions keyboards/projectcain/vault35/info.json
Original file line number Diff line number Diff line change
@@ -1,27 +1,22 @@
{
"keyboard_name": "Vault35",
"manufacturer": "projectcain",
"url": "",
"keyboard_name": "Vault35",
"maintainer": "projectcain",
"usb": {
"vid": "0xFEED",
"pid": "0x6060",
"device_version": "0.0.1"
},
"matrix_pins": {
"cols": ["B1", "D3", "F0", "F1", "F4", "F5", "F6", "F7", "C6", "B6", "B5"],
"rows": ["B4", "D4", "B0", "C7"]
},
"diode_direction": "COL2ROW",
"encoder": {
"rotary": [
{"pin_a": "D6", "pin_b": "D7", "resolution": 2}
]
"qmk": {
"locking": {
"enabled": true,
"resync": true
}
},
"url": "https://mechvault.net",
"usb": {
"device_version": "0.0.1",
"pid": "0x6060",
"vid": "0xFEED"
},
"processor": "atmega32u4",
"bootloader": "atmel-dfu",
"layouts": {
"LAYOUT_split_4space": {
"LAYOUT_all": {
"layout": [
{"matrix": [0, 0], "x": 0, "y": 0},
{"matrix": [0, 1], "x": 1, "y": 0},
Expand All @@ -33,8 +28,7 @@
{"matrix": [0, 7], "x": 7, "y": 0},
{"matrix": [0, 8], "x": 8, "y": 0},
{"matrix": [0, 9], "x": 9, "y": 0},
{"matrix": [0, 10], "x": 10, "y": 0},

{"matrix": [0, 10], "x": 10, "y": 0, "encoder": 0},
{"matrix": [1, 0], "x": 0, "y": 1, "w": 1.25},
{"matrix": [1, 1], "x": 1.25, "y": 1},
{"matrix": [1, 2], "x": 2.25, "y": 1},
Expand All @@ -45,7 +39,6 @@
{"matrix": [1, 7], "x": 7.25, "y": 1},
{"matrix": [1, 8], "x": 8.25, "y": 1},
{"matrix": [1, 9], "x": 9.25, "y": 1, "w": 1.75},

{"matrix": [2, 0], "x": 0, "y": 2, "w": 1.75},
{"matrix": [2, 1], "x": 1.75, "y": 2},
{"matrix": [2, 2], "x": 2.75, "y": 2},
Expand All @@ -56,16 +49,16 @@
{"matrix": [2, 7], "x": 7.75, "y": 2},
{"matrix": [2, 8], "x": 8.75, "y": 2},
{"matrix": [2, 9], "x": 9.75, "y": 2, "w": 1.25},

{"matrix": [3, 1], "x": 1.5, "y": 3},
{"matrix": [3, 2], "x": 2.5, "y": 3, "w": 1.25},
{"matrix": [3, 3], "x": 3.75, "y": 3, "w": 1.75},
{"matrix": [3, 5], "x": 5.5, "y": 3, "w": 1.75},
{"matrix": [3, 6], "x": 7.25, "y": 3, "w": 1.25},
{"matrix": [3, 7], "x": 8.5, "y": 3}
{"matrix": [3, 3], "x": 3.75, "y": 3, "w": 1.5},
{"matrix": [3, 4], "x": 5.25, "y": 3},
{"matrix": [3, 5], "x": 6.25, "y": 3, "w": 1.5},
{"matrix": [3, 6], "x": 7.75, "y": 3, "w": 1.25},
{"matrix": [3, 7], "x": 9, "y": 3}
]
},
"LAYOUT_split_3space": {
"LAYOUT_full_space": {
"layout": [
{"matrix": [0, 0], "x": 0, "y": 0},
{"matrix": [0, 1], "x": 1, "y": 0},
Expand All @@ -77,8 +70,7 @@
{"matrix": [0, 7], "x": 7, "y": 0},
{"matrix": [0, 8], "x": 8, "y": 0},
{"matrix": [0, 9], "x": 9, "y": 0},
{"matrix": [0, 10], "x": 10, "y": 0},

{"matrix": [0, 10], "x": 10, "y": 0, "encoder": 0},
{"matrix": [1, 0], "x": 0, "y": 1, "w": 1.25},
{"matrix": [1, 1], "x": 1.25, "y": 1},
{"matrix": [1, 2], "x": 2.25, "y": 1},
Expand All @@ -89,7 +81,6 @@
{"matrix": [1, 7], "x": 7.25, "y": 1},
{"matrix": [1, 8], "x": 8.25, "y": 1},
{"matrix": [1, 9], "x": 9.25, "y": 1, "w": 1.75},

{"matrix": [2, 0], "x": 0, "y": 2, "w": 1.75},
{"matrix": [2, 1], "x": 1.75, "y": 2},
{"matrix": [2, 2], "x": 2.75, "y": 2},
Expand All @@ -100,11 +91,8 @@
{"matrix": [2, 7], "x": 7.75, "y": 2},
{"matrix": [2, 8], "x": 8.75, "y": 2},
{"matrix": [2, 9], "x": 9.75, "y": 2, "w": 1.25},

{"matrix": [3, 1], "x": 1.5, "y": 3},
{"matrix": [3, 3], "x": 2.5, "y": 3, "w": 2.25},
{"matrix": [3, 4], "x": 4.75, "y": 3},
{"matrix": [3, 5], "x": 5.75, "y": 3, "w": 2.75},
{"matrix": [3, 4], "x": 2.5, "y": 3, "w": 6},
{"matrix": [3, 7], "x": 8.5, "y": 3}
]
},
Expand All @@ -120,8 +108,7 @@
{"matrix": [0, 7], "x": 7, "y": 0},
{"matrix": [0, 8], "x": 8, "y": 0},
{"matrix": [0, 9], "x": 9, "y": 0},
{"matrix": [0, 10], "x": 10, "y": 0},

{"matrix": [0, 10], "x": 10, "y": 0, "encoder": 0},
{"matrix": [1, 0], "x": 0, "y": 1, "w": 1.25},
{"matrix": [1, 1], "x": 1.25, "y": 1},
{"matrix": [1, 2], "x": 2.25, "y": 1},
Expand All @@ -132,7 +119,6 @@
{"matrix": [1, 7], "x": 7.25, "y": 1},
{"matrix": [1, 8], "x": 8.25, "y": 1},
{"matrix": [1, 9], "x": 9.25, "y": 1, "w": 1.75},

{"matrix": [2, 0], "x": 0, "y": 2, "w": 1.75},
{"matrix": [2, 1], "x": 1.75, "y": 2},
{"matrix": [2, 2], "x": 2.75, "y": 2},
Expand All @@ -143,14 +129,13 @@
{"matrix": [2, 7], "x": 7.75, "y": 2},
{"matrix": [2, 8], "x": 8.75, "y": 2},
{"matrix": [2, 9], "x": 9.75, "y": 2, "w": 1.25},

{"matrix": [3, 1], "x": 1.5, "y": 3},
{"matrix": [3, 3], "x": 2.5, "y": 3, "w": 3},
{"matrix": [3, 5], "x": 5.5, "y": 3, "w": 3},
{"matrix": [3, 7], "x": 8.5, "y": 3}
]
},
"LAYOUT_full_space": {
"LAYOUT_split_3space": {
"layout": [
{"matrix": [0, 0], "x": 0, "y": 0},
{"matrix": [0, 1], "x": 1, "y": 0},
Expand All @@ -162,8 +147,7 @@
{"matrix": [0, 7], "x": 7, "y": 0},
{"matrix": [0, 8], "x": 8, "y": 0},
{"matrix": [0, 9], "x": 9, "y": 0},
{"matrix": [0, 10], "x": 10, "y": 0},

{"matrix": [0, 10], "x": 10, "y": 0, "encoder": 0},
{"matrix": [1, 0], "x": 0, "y": 1, "w": 1.25},
{"matrix": [1, 1], "x": 1.25, "y": 1},
{"matrix": [1, 2], "x": 2.25, "y": 1},
Expand All @@ -174,7 +158,6 @@
{"matrix": [1, 7], "x": 7.25, "y": 1},
{"matrix": [1, 8], "x": 8.25, "y": 1},
{"matrix": [1, 9], "x": 9.25, "y": 1, "w": 1.75},

{"matrix": [2, 0], "x": 0, "y": 2, "w": 1.75},
{"matrix": [2, 1], "x": 1.75, "y": 2},
{"matrix": [2, 2], "x": 2.75, "y": 2},
Expand All @@ -185,9 +168,51 @@
{"matrix": [2, 7], "x": 7.75, "y": 2},
{"matrix": [2, 8], "x": 8.75, "y": 2},
{"matrix": [2, 9], "x": 9.75, "y": 2, "w": 1.25},

{"matrix": [3, 1], "x": 1.5, "y": 3},
{"matrix": [3, 4], "x": 2.5, "y": 3, "w": 6},
{"matrix": [3, 3], "x": 2.5, "y": 3, "w": 2.25},
{"matrix": [3, 4], "x": 4.75, "y": 3},
{"matrix": [3, 5], "x": 5.75, "y": 3, "w": 2.75},
{"matrix": [3, 7], "x": 8.5, "y": 3}
]
},
"LAYOUT_split_4space": {
"layout": [
{"matrix": [0, 0], "x": 0, "y": 0},
{"matrix": [0, 1], "x": 1, "y": 0},
{"matrix": [0, 2], "x": 2, "y": 0},
{"matrix": [0, 3], "x": 3, "y": 0},
{"matrix": [0, 4], "x": 4, "y": 0},
{"matrix": [0, 5], "x": 5, "y": 0},
{"matrix": [0, 6], "x": 6, "y": 0},
{"matrix": [0, 7], "x": 7, "y": 0},
{"matrix": [0, 8], "x": 8, "y": 0},
{"matrix": [0, 9], "x": 9, "y": 0},
{"matrix": [0, 10], "x": 10, "y": 0, "encoder": 0},
{"matrix": [1, 0], "x": 0, "y": 1, "w": 1.25},
{"matrix": [1, 1], "x": 1.25, "y": 1},
{"matrix": [1, 2], "x": 2.25, "y": 1},
{"matrix": [1, 3], "x": 3.25, "y": 1},
{"matrix": [1, 4], "x": 4.25, "y": 1},
{"matrix": [1, 5], "x": 5.25, "y": 1},
{"matrix": [1, 6], "x": 6.25, "y": 1},
{"matrix": [1, 7], "x": 7.25, "y": 1},
{"matrix": [1, 8], "x": 8.25, "y": 1},
{"matrix": [1, 9], "x": 9.25, "y": 1, "w": 1.75},
{"matrix": [2, 0], "x": 0, "y": 2, "w": 1.75},
{"matrix": [2, 1], "x": 1.75, "y": 2},
{"matrix": [2, 2], "x": 2.75, "y": 2},
{"matrix": [2, 3], "x": 3.75, "y": 2},
{"matrix": [2, 4], "x": 4.75, "y": 2},
{"matrix": [2, 5], "x": 5.75, "y": 2},
{"matrix": [2, 6], "x": 6.75, "y": 2},
{"matrix": [2, 7], "x": 7.75, "y": 2},
{"matrix": [2, 8], "x": 8.75, "y": 2},
{"matrix": [2, 9], "x": 9.75, "y": 2, "w": 1.25},
{"matrix": [3, 1], "x": 1.5, "y": 3},
{"matrix": [3, 2], "x": 2.5, "y": 3, "w": 1.25},
{"matrix": [3, 3], "x": 3.75, "y": 3, "w": 1.75},
{"matrix": [3, 5], "x": 5.5, "y": 3, "w": 1.75},
{"matrix": [3, 6], "x": 7.25, "y": 3, "w": 1.25},
{"matrix": [3, 7], "x": 8.5, "y": 3}
]
}
Expand Down
39 changes: 23 additions & 16 deletions keyboards/projectcain/vault35/keymaps/default/keymap.c
Original file line number Diff line number Diff line change
@@ -1,19 +1,18 @@

/* Copyright 2021 projectcain
*
* 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/>.
*/
/* Copyright 2021 projectcain
*
* 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
enum layers{
Expand Down Expand Up @@ -64,3 +63,11 @@ combo_t key_combos[] = {
[KL_SLSH] = COMBO(kl_combo, S(KC_SLSH)),
[JK_MINUS] = COMBO(jk_combo, KC_MINUS)
};

#if defined(ENCODER_MAP_ENABLE)
const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][NUM_DIRECTIONS] = {
[BASE] = { ENCODER_CCW_CW(KC_PGUP, KC_PGDN) },
[NUM] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) },
[SYM] = { ENCODER_CCW_CW(KC_TRNS, KC_TRNS) }
};
#endif
3 changes: 2 additions & 1 deletion keyboards/projectcain/vault35/keymaps/default/rules.mk
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
COMBO_ENABLE = yes
COMBO_ENABLE = yes
ENCODER_MAP_ENABLE = yes
14 changes: 1 addition & 13 deletions keyboards/projectcain/vault35/rules.mk
Original file line number Diff line number Diff line change
@@ -1,13 +1 @@
# Build Options
# change yes to no to disable
#
BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite
MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = no # Console for debug
COMMAND_ENABLE = no # Commands for debug and configuration
NKRO_ENABLE = no # Enable N-Key Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
AUDIO_ENABLE = no # Audio output
ENCODER_ENABLE = yes
DEFAULT_FOLDER = projectcain/vault35/atmega32u4

0 comments on commit 5c9c8fb

Please sign in to comment.