Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

keyboard.json schema: set minimum value for key_unit #23937

Merged
merged 3 commits into from
Jun 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion data/schemas/definitions.jsonschema
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@
"pattern": "^[0-9a-z_/\\-]+\\.json$"
},
"key_unit": {
"type": "number"
"type": "number",
"minimum": 0
},
"keyboard": {
"type": "string",
Expand Down
8 changes: 4 additions & 4 deletions data/schemas/keyboard.jsonschema
Original file line number Diff line number Diff line change
Expand Up @@ -515,8 +515,8 @@
"minimum": 0
}
},
"x": {"$ref": "qmk.definitions.v1#/key_unit"},
"y": {"$ref": "qmk.definitions.v1#/key_unit"},
"x": {"$ref": "qmk.definitions.v1#/unsigned_int"},
"y": {"$ref": "qmk.definitions.v1#/unsigned_int"},
"flags": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}
}
}
Expand Down Expand Up @@ -601,8 +601,8 @@
"minimum": 0
}
},
"x": {"$ref": "qmk.definitions.v1#/key_unit"},
"y": {"$ref": "qmk.definitions.v1#/key_unit"},
"x": {"$ref": "qmk.definitions.v1#/unsigned_int"},
"y": {"$ref": "qmk.definitions.v1#/unsigned_int"},
"flags": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}
}
}
Expand Down
3 changes: 3 additions & 0 deletions keyboards/hazel/bad_wings/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@

#pragma once

#define MATRIX_COLS 8
#define MATRIX_ROWS 5

#define SPI_SCK_PIN GP2
#define SPI_MOSI_PIN GP3
#define SPI_MISO_PIN GP4
Expand Down
4 changes: 0 additions & 4 deletions keyboards/hazel/bad_wings/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@
},
"processor": "RP2040",
"bootloader": "rp2040",
"matrix_size": {
"cols": 8,
"rows": 5
},
"diode_direction": "COL2ROW",
"features": {
"bootmagic": true,
Expand Down
3 changes: 3 additions & 0 deletions keyboards/keychron/q1v2/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@

#pragma once

#define MATRIX_COLS 16
#define MATRIX_ROWS 6

/* RGB Matrix Driver Configuration */
#define SNLED27351_I2C_ADDRESS_1 SNLED27351_I2C_ADDRESS_VDDIO
#define SNLED27351_I2C_ADDRESS_2 SNLED27351_I2C_ADDRESS_GND
Expand Down
4 changes: 0 additions & 4 deletions keyboards/keychron/q1v2/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,6 @@
"custom": true,
"custom_lite": true
},
"matrix_size": {
"cols": 16,
"rows": 6
},
"diode_direction": "ROW2COL",
"rgb_matrix": {
"driver": "snled27351",
Expand Down
7 changes: 7 additions & 0 deletions keyboards/mechlovin/olly/jf/rev1/config.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
// Copyright 2024 QMK
// SPDX-License-Identifier: GPL-2.0-or-later

#pragma once

#define MATRIX_COLS 19
#define MATRIX_ROWS 6
4 changes: 0 additions & 4 deletions keyboards/mechlovin/olly/jf/rev1/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,6 @@
"rows": ["D5", "D6", "A5", "A4", "A3", "A6"],
"custom_lite": true
},
"matrix_size": {
"cols": 19,
"rows": 6
},
"backlight": {
"pin": "D4",
"breathing": true
Expand Down
34 changes: 17 additions & 17 deletions keyboards/silverbullet44/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -92,29 +92,29 @@
{"matrix": [5, 1], "x": 16, "y": 1.75},
{"matrix": [5, 0], "x": 17, "y": 2.375},

{"matrix": [2, 0], "x": 12, "y": 2.5},
{"matrix": [2, 1], "x": 13, "y": 2.25},
{"matrix": [2, 2], "x": 14, "y": 2},
{"matrix": [2, 3], "x": 15, "y": 2.25},
{"matrix": [2, 4], "x": 16, "y": 2.75},
{"matrix": [2, 5], "x": 17, "y": 3.375},
{"matrix": [2, 0], "x": 0, "y": 3.375},
{"matrix": [2, 1], "x": 1, "y": 2.75},
{"matrix": [2, 2], "x": 2, "y": 2.25},
{"matrix": [2, 3], "x": 3, "y": 2},
{"matrix": [2, 4], "x": 4, "y": 2.25},
{"matrix": [2, 5], "x": 5, "y": 2.5},

{"matrix": [6, 5], "x": 0, "y": 3.375},
{"matrix": [6, 4], "x": 1, "y": 2.75},
{"matrix": [6, 3], "x": 2, "y": 2.25},
{"matrix": [6, 2], "x": 3, "y": 2},
{"matrix": [6, 1], "x": 4, "y": 2.25},
{"matrix": [6, 0], "x": 5, "y": 2.5},
{"matrix": [6, 5], "x": 12, "y": 2.5},
{"matrix": [6, 4], "x": 13, "y": 2.25},
{"matrix": [6, 3], "x": 14, "y": 2},
{"matrix": [6, 2], "x": 15, "y": 2.25},
{"matrix": [6, 1], "x": 16, "y": 2.75},
{"matrix": [6, 0], "x": 17, "y": 3.375},

{"matrix": [3, 2], "x": 4, "y": 3.25, "h": 1.25},
{"matrix": [3, 3], "x": 5, "y": 3.5},
{"matrix": [3, 4], "x": -0.5, "y": 3.5, "h": 1.5},
{"matrix": [3, 5], "x": 7, "y": 3.25, "h": 1.5},
{"matrix": [3, 4], "x": 6, "y": 3.25, "h": 1.5},
{"matrix": [3, 5], "x": 7, "y": 3.5, "h": 1.5},

{"matrix": [7, 5], "x": -3, "y": 3.5, "h": 1.5},
{"matrix": [7, 4], "x": -2, "y": 3.5, "h": 1.5},
{"matrix": [7, 5], "x": 10, "y": 3.5, "h": 1.5},
{"matrix": [7, 4], "x": 11, "y": 3.25, "h": 1.5},
{"matrix": [7, 3], "x": 12, "y": 3.5},
{"matrix": [7, 2], "x": 13, "y": 3.25, "w": 1.25}
{"matrix": [7, 2], "x": 13, "y": 3.25, "h": 1.25}
]
}
}
Expand Down
3 changes: 3 additions & 0 deletions keyboards/snes_macropad/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@

#pragma once

#define MATRIX_COLS 4
#define MATRIX_ROWS 6

#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_LED GP25
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U
Expand Down
4 changes: 0 additions & 4 deletions keyboards/snes_macropad/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,6 @@
"driver": "vendor"
},
"processor": "RP2040",
"matrix_size": {
"cols": 4,
"rows": 6
},
"url": "",
"usb": {
"device_version": "1.0.0",
Expand Down
3 changes: 3 additions & 0 deletions keyboards/zsa/voyager/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@

#pragma once

#define MATRIX_COLS 7
#define MATRIX_ROWS 12

#define IS31FL3731_I2C_ADDRESS_1 IS31FL3731_I2C_ADDRESS_GND
#define IS31FL3731_I2C_ADDRESS_2 IS31FL3731_I2C_ADDRESS_VCC

Expand Down
4 changes: 0 additions & 4 deletions keyboards/zsa/voyager/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@
"matrix": [0, 1]
},
"diode_direction": "ROW2COL",
"matrix_size": {
"cols": 7,
"rows": 12
},
"mousekey": {
"delay": 0,
"interval": 20,
Expand Down
Loading