Open HannesHasselbring opened 1 year ago
with this, probably too simple, change in line 140 file lib/python/qmk/commands.py
kb_folder = keyboard(keyboard_filesafe)
if not kb_folder.exists():
from qmk.importers import import_keyboard
import_keyboard(user_keymap['config'])
I was able to compile the following keymap.json, which passed all validations.
{
"keyboard": "banana_macropad",
"keymap": "hannes",
"layout": "LAYOUT",
"layers": [
["KC_1", "KC_2", "KC_3", "KC_4", "KC_5", "KC_6", "KC_7", "QK_BOOT"]
],
"encoders": [[{ "ccw": "KC_KB_VOLUME_UP", "cw": "KC_KB_VOLUME_DOWN" }]],
"config": {
"keyboard_name": "banana_macropad",
"url": "https://github.com/dbostian/banana",
"maintainer": "qmk",
"manufacturer": "3D print",
"usb": {
"vid": "0xFEED",
"pid": "0x0815",
"device_version": "0.0.1"
},
"processor": "atmega32u4",
"bootloader": "caterina",
"matrix_pins": {
"cols": ["D1", "D0", "D4", "C6", "D7", "E6", "B4", "B5"],
"rows": ["B2"]
},
"diode_direction": "COL2ROW",
"width": 8,
"height": 1,
"encoder": {
"rotary": [{ "pin_a": "F6", "pin_b": "F6" }],
"enabled": true
},
"features": {
"extrakey": true,
"encoder": true,
"encoder_map": true
},
"layouts": {
"LAYOUT": {
"layout": [
{ "label": "F1", "x": 0, "y": 0, "matrix": [0, 0] },
{ "label": "F2", "x": 1, "y": 0, "matrix": [0, 1] },
{ "label": "F3", "x": 2, "y": 0, "matrix": [0, 2] },
{ "label": "F4", "x": 3, "y": 0, "matrix": [0, 3] },
{ "label": "F5", "x": 4, "y": 0, "matrix": [0, 4] },
{ "label": "F6", "x": 5, "y": 0, "matrix": [0, 5] },
{ "label": "F7", "x": 6, "y": 0, "matrix": [0, 6] },
{ "label": "F8", "x": 7, "y": 0, "matrix": [0, 7] }
]
}
}
}
}
This issue has been automatically marked as stale because it has not had activity in the last 90 days. It will be closed in the next 30 days unless it is tagged properly or other activity occurs.
For maintainers: Please label with bug
, in progress
, on hold
, discussion
or to do
to prevent the issue from being re-flagged.
Feature Request Type
Description
I have a couple of handwired keyboards. I like the idea of building qmk with github userspace and a data driven keyboard configuration.
From my understanding the
keymap.json
could include a complete keyboard configuration, but it is not treated as such. Theqmk compile
command still needs the keyboard configuration folder.My current approach is to create a
info.json
useqmk import-keyboard
to create a keyboard directory and then compile the keyboard with ankeymap.json
.Is there a better way to do it? Would you be open for a enhancement to somehow specify a data driven keyboard config? I might be able to implement needed changes in qmk_cli