From d667eb193d3984e9a048cacceec7c270991e5e0b Mon Sep 17 00:00:00 2001 From: Buckwich Date: Mon, 11 Nov 2024 23:45:13 +0100 Subject: [PATCH 1/5] use valid json syntax for jsonschema --- data/schemas/keyboard.jsonschema | 7 +++++-- data/schemas/keycodes.jsonschema | 3 ++- data/schemas/user_repo_v0.jsonschema | 4 ++-- data/schemas/user_repo_v1.jsonschema | 2 +- data/schemas/user_repo_v1_1.jsonschema | 2 +- 5 files changed, 11 insertions(+), 7 deletions(-) diff --git a/data/schemas/keyboard.jsonschema b/data/schemas/keyboard.jsonschema index 7649a8e31b2..c76e2b27772 100644 --- a/data/schemas/keyboard.jsonschema +++ b/data/schemas/keyboard.jsonschema @@ -33,7 +33,10 @@ } }, "type": "object", - "not": {"required": ["vendorId", "productId"]}, // reject via keys... + "not": { + "$comment": "reject via keys...", + "required": ["vendorId", "productId"] + }, "properties": { "keyboard_name": {"$ref": "qmk.definitions.v1#/text_identifier"}, "keyboard_folder": {"$ref": "qmk.definitions.v1#/keyboard"}, @@ -351,7 +354,7 @@ "axis_resolution": {"$ref": "qmk.definitions.v1#/unsigned_int"}, "axes": { "type": "object", - "propertyNames": {"enum": ["x", "y", "z", "rx", "ry", "rz"]} + "propertyNames": {"enum": ["x", "y", "z", "rx", "ry", "rz"]}, "additionalProperties": { "oneOf": [ { diff --git a/data/schemas/keycodes.jsonschema b/data/schemas/keycodes.jsonschema index df6ce95a83b..e6418c42a83 100644 --- a/data/schemas/keycodes.jsonschema +++ b/data/schemas/keycodes.jsonschema @@ -33,7 +33,8 @@ "$ref": "qmk.definitions.v1#/hex_number_4d" }, "additionalProperties": { - "type": "object", // use 'qmk.definitions.v1#/keycode_decl' when problem keycodes are removed + "$comment": "use 'qmk.definitions.v1#/keycode_decl' when problem keycodes are removed", + "type": "object", "required": [ "key" ], diff --git a/data/schemas/user_repo_v0.jsonschema b/data/schemas/user_repo_v0.jsonschema index b18ac504284..58d955abe27 100644 --- a/data/schemas/user_repo_v0.jsonschema +++ b/data/schemas/user_repo_v0.jsonschema @@ -8,7 +8,7 @@ ], "properties": { "userspace_version": { - "type": "string", - }, + "type": "string" + } } } diff --git a/data/schemas/user_repo_v1.jsonschema b/data/schemas/user_repo_v1.jsonschema index 69a59bce007..88b50e8a726 100644 --- a/data/schemas/user_repo_v1.jsonschema +++ b/data/schemas/user_repo_v1.jsonschema @@ -9,7 +9,7 @@ {"$ref": "qmk.definitions.v1#/keyboard_keymap_tuple"}, {"$ref": "qmk.definitions.v1#/json_file_path"} ] - }, + } }, "required": [ "userspace_version", diff --git a/data/schemas/user_repo_v1_1.jsonschema b/data/schemas/user_repo_v1_1.jsonschema index 5a7ccce0633..173d8d26d63 100644 --- a/data/schemas/user_repo_v1_1.jsonschema +++ b/data/schemas/user_repo_v1_1.jsonschema @@ -10,7 +10,7 @@ {"$ref": "qmk.definitions.v1#/keyboard_keymap_env"}, {"$ref": "qmk.definitions.v1#/json_file_path"} ] - }, + } }, "required": [ "userspace_version", From 2e2ae506ce24e7246b1ed4c2874489e936ce3749 Mon Sep 17 00:00:00 2001 From: Buckwich Date: Mon, 11 Nov 2024 23:47:12 +0100 Subject: [PATCH 2/5] format keyboard.jsonschema with prettier --- data/schemas/keyboard.jsonschema | 1056 +++++++++++++++++++++++------- 1 file changed, 809 insertions(+), 247 deletions(-) diff --git a/data/schemas/keyboard.jsonschema b/data/schemas/keyboard.jsonschema index c76e2b27772..482134091d8 100644 --- a/data/schemas/keyboard.jsonschema +++ b/data/schemas/keyboard.jsonschema @@ -8,18 +8,30 @@ "properties": { "driver": { "type": "string", - "enum": ["custom", "quadrature"] + "enum": [ + "custom", + "quadrature" + ] }, "rotary": { "type": "array", "items": { "type": "object", "additionalProperties": false, - "required": ["pin_a", "pin_b"], + "required": [ + "pin_a", + "pin_b" + ], "properties": { - "pin_a": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "pin_b": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "resolution": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "pin_a": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "pin_b": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "resolution": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } } } } @@ -28,31 +40,65 @@ "dip_switch_config": { "type": "object", "properties": { - "pins": {"$ref": "qmk.definitions.v1#/mcu_pin_array"} + "pins": { + "$ref": "qmk.definitions.v1#/mcu_pin_array" + } } } }, "type": "object", "not": { "$comment": "reject via keys...", - "required": ["vendorId", "productId"] + "required": [ + "vendorId", + "productId" + ] }, "properties": { - "keyboard_name": {"$ref": "qmk.definitions.v1#/text_identifier"}, - "keyboard_folder": {"$ref": "qmk.definitions.v1#/keyboard"}, - "maintainer": {"$ref": "qmk.definitions.v1#/text_identifier"}, - "manufacturer": {"$ref": "qmk.definitions.v1#/text_identifier"}, + "keyboard_name": { + "$ref": "qmk.definitions.v1#/text_identifier" + }, + "keyboard_folder": { + "$ref": "qmk.definitions.v1#/keyboard" + }, + "maintainer": { + "$ref": "qmk.definitions.v1#/text_identifier" + }, + "manufacturer": { + "$ref": "qmk.definitions.v1#/text_identifier" + }, "url": { "type": "string", "format": "uri" }, "development_board": { "type": "string", - "enum": ["promicro", "elite_c", "elite_pi", "proton_c", "kb2040", "promicro_rp2040", "blok", "michi", "bit_c_pro", "stemcell", "bluepill", "blackpill_f401", "blackpill_f411", "bonsai_c4", "helios", "liatris", "imera"] + "enum": [ + "promicro", + "elite_c", + "elite_pi", + "proton_c", + "kb2040", + "promicro_rp2040", + "blok", + "michi", + "bit_c_pro", + "stemcell", + "bluepill", + "blackpill_f401", + "blackpill_f411", + "bonsai_c4", + "helios", + "liatris", + "imera" + ] }, "pin_compatible": { "type": "string", - "enum": ["promicro", "elite_c"] + "enum": [ + "promicro", + "elite_c" + ] }, "processor": { "type": "string", @@ -115,8 +161,12 @@ "type": "object", "additionalProperties": false, "properties": { - "data_pin": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "clock_pin": {"$ref": "qmk.definitions.v1#/mcu_pin"}, + "data_pin": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "clock_pin": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, "default_brightness": { "type": "integer", "minimum": 0, @@ -132,25 +182,44 @@ "type": "object", "additionalProperties": false, "properties": { - "on": {"type": "boolean"}, - "clicky": {"type": "boolean"} + "on": { + "type": "boolean" + }, + "clicky": { + "type": "boolean" + } } }, "driver": { "type": "string", - "enum": ["dac_additive", "dac_basic", "pwm_software", "pwm_hardware"] + "enum": [ + "dac_additive", + "dac_basic", + "pwm_software", + "pwm_hardware" + ] + }, + "macro_beep": { + "type": "boolean" + }, + "pins": { + "$ref": "qmk.definitions.v1#/mcu_pin_array" }, - "macro_beep": {"type": "boolean"}, - "pins": {"$ref": "qmk.definitions.v1#/mcu_pin_array"}, "power_control": { "type": "object", "additionalProperties": false, "properties": { - "on_state": {"$ref": "qmk.definitions.v1#/bit"}, - "pin": {"$ref": "qmk.definitions.v1#/mcu_pin"} + "on_state": { + "$ref": "qmk.definitions.v1#/bit" + }, + "pin": { + "$ref": "qmk.definitions.v1#/mcu_pin" + } } }, - "voices": {"type": "boolean"} + "voices": { + "type": "boolean" + } } }, "backlight": { @@ -159,29 +228,54 @@ "properties": { "driver": { "type": "string", - "enum": ["custom", "pwm", "software", "timer"] + "enum": [ + "custom", + "pwm", + "software", + "timer" + ] }, "default": { "type": "object", "additionalProperties": false, "properties": { - "on": {"type": "boolean"}, - "breathing": {"type": "boolean"}, - "brightness": {"$ref": "qmk.definitions.v1#/unsigned_int_8"} + "on": { + "type": "boolean" + }, + "breathing": { + "type": "boolean" + }, + "brightness": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + } } }, - "breathing": {"type": "boolean"}, - "breathing_period": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, + "breathing": { + "type": "boolean" + }, + "breathing_period": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, "levels": { "type": "integer", "minimum": 1, "maximum": 31 }, - "max_brightness": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "pin": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "pins": {"$ref": "qmk.definitions.v1#/mcu_pin_array"}, - "on_state": {"$ref": "qmk.definitions.v1#/bit"}, - "as_caps_lock": {"type": "boolean"} + "max_brightness": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "pin": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "pins": { + "$ref": "qmk.definitions.v1#/mcu_pin_array" + }, + "on_state": { + "$ref": "qmk.definitions.v1#/bit" + }, + "as_caps_lock": { + "type": "boolean" + } } }, "bluetooth": { @@ -190,15 +284,21 @@ "properties": { "driver": { "type": "string", - "enum": ["bluefruit_le", "custom", "rn42"] + "enum": [ + "bluefruit_le", + "custom", + "rn42" + ] } } }, - "bootmagic":{ + "bootmagic": { "type": "object", "additionalProperties": false, "properties": { - "enabled": {"type": "boolean"}, + "enabled": { + "type": "boolean" + }, "matrix": { "type": "array", "minItems": 2, @@ -251,46 +351,83 @@ "properties": { "debounce_type": { "type": "string", - "enum": ["asym_eager_defer_pk", "custom", "sym_defer_g", "sym_defer_pk", "sym_defer_pr", "sym_eager_pk", "sym_eager_pr"] + "enum": [ + "asym_eager_defer_pk", + "custom", + "sym_defer_g", + "sym_defer_pk", + "sym_defer_pr", + "sym_eager_pk", + "sym_eager_pr" + ] }, "firmware_format": { "type": "string", - "enum": ["bin", "hex", "uf2"] + "enum": [ + "bin", + "hex", + "uf2" + ] }, - "lto": {"type": "boolean"} + "lto": { + "type": "boolean" + } } }, "diode_direction": { "type": "string", - "enum": ["COL2ROW", "ROW2COL"] + "enum": [ + "COL2ROW", + "ROW2COL" + ] + }, + "debounce": { + "$ref": "qmk.definitions.v1#/unsigned_int" }, - "debounce": {"$ref": "qmk.definitions.v1#/unsigned_int"}, "caps_word": { "type": "object", "additionalProperties": false, "properties": { - "enabled": {"type": "boolean"}, - "both_shifts_turns_on": {"type": "boolean"}, - "double_tap_shift_turns_on": {"type": "boolean"}, - "idle_timeout": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "invert_on_shift": {"type": "boolean"} + "enabled": { + "type": "boolean" + }, + "both_shifts_turns_on": { + "type": "boolean" + }, + "double_tap_shift_turns_on": { + "type": "boolean" + }, + "idle_timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "invert_on_shift": { + "type": "boolean" + } } }, "combo": { "type": "object", "properties": { - "count": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "term": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "count": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "term": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } } }, "community_layouts": { "type": "array", - "items": {"$ref": "qmk.definitions.v1#/filename"} + "items": { + "$ref": "qmk.definitions.v1#/filename" + } }, "dip_switch": { "$ref": "#/definitions/dip_switch_config", "properties": { - "enabled": {"type": "boolean"}, + "enabled": { + "type": "boolean" + }, "matrix_grid": { "type": "array", "minItems": 1, @@ -308,17 +445,29 @@ }, "eeprom": { "properties": { - "driver": {"type": "string"}, + "driver": { + "type": "string" + }, "wear_leveling": { "type": "object", "additionalProperties": false, "properties": { "driver": { "type": "string", - "enum": ["custom", "embedded_flash", "legacy", "rp2040_flash", "spi_flash"] + "enum": [ + "custom", + "embedded_flash", + "legacy", + "rp2040_flash", + "spi_flash" + ] }, - "backing_size": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "logical_size": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "backing_size": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "logical_size": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } } } } @@ -326,78 +475,142 @@ "encoder": { "$ref": "#/definitions/encoder_config", "properties": { - "enabled": {"type": "boolean"} + "enabled": { + "type": "boolean" + } } }, "features": { "$ref": "qmk.definitions.v1#/boolean_array", - "propertyNames": {"$ref": "qmk.definitions.v1#/snake_case"}, - "not": {"required": ["lto"]} + "propertyNames": { + "$ref": "qmk.definitions.v1#/snake_case" + }, + "not": { + "required": [ + "lto" + ] + } }, "indicators": { "type": "object", "properties": { - "caps_lock": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "num_lock": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "scroll_lock": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "compose": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "kana": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "on_state": {"$ref": "qmk.definitions.v1#/bit"} + "caps_lock": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "num_lock": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "scroll_lock": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "compose": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "kana": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "on_state": { + "$ref": "qmk.definitions.v1#/bit" + } } }, "joystick": { "type": "object", "properties": { - "enabled": {"type": "boolean"}, - "driver": {"type": "string"}, - "button_count": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "axis_resolution": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "enabled": { + "type": "boolean" + }, + "driver": { + "type": "string" + }, + "button_count": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "axis_resolution": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, "axes": { "type": "object", - "propertyNames": {"enum": ["x", "y", "z", "rx", "ry", "rz"]}, + "propertyNames": { + "enum": [ + "x", + "y", + "z", + "rx", + "ry", + "rz" + ] + }, "additionalProperties": { "oneOf": [ { "type": "object", "properties": { - "input_pin": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "low": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "rest": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "high": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "input_pin": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "low": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "rest": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "high": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } } }, { "type": "string", - "enum": ["virtual"] + "enum": [ + "virtual" + ] } ] } } } }, - "keycodes": {"$ref": "qmk.definitions.v1#/keycode_decl_array"}, + "keycodes": { + "$ref": "qmk.definitions.v1#/keycode_decl_array" + }, "layout_aliases": { "type": "object", - "additionalProperties": {"$ref": "qmk.definitions.v1#/layout_macro"} + "additionalProperties": { + "$ref": "qmk.definitions.v1#/layout_macro" + } }, "layouts": { "type": "object", - "propertyNames": {"$ref": "qmk.definitions.v1#/layout_macro"}, + "propertyNames": { + "$ref": "qmk.definitions.v1#/layout_macro" + }, "additionalProperties": { "type": "object", "additionalProperties": false, "properties": { - "filename": {"type": "string"}, - "c_macro": {"type": "boolean"}, - "json_layout": {"type": "boolean"}, + "filename": { + "type": "string" + }, + "c_macro": { + "type": "boolean" + }, + "json_layout": { + "type": "boolean" + }, "layout": { "type": "array", "items": { "type": "object", "additionalProperties": false, - "required": ["x", "y"], + "required": [ + "x", + "y" + ], "properties": { - "encoder": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "encoder": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, "label": { "type": "string", "pattern": "^[^\\n]*$" @@ -411,13 +624,27 @@ "minimum": 0 } }, - "r": {"$ref": "qmk.definitions.v1#/signed_decimal"}, - "rx": {"$ref": "qmk.definitions.v1#/unsigned_decimal"}, - "ry": {"$ref": "qmk.definitions.v1#/unsigned_decimal"}, - "h": {"$ref": "qmk.definitions.v1#/key_unit"}, - "w": {"$ref": "qmk.definitions.v1#/key_unit"}, - "x": {"$ref": "qmk.definitions.v1#/key_unit"}, - "y": {"$ref": "qmk.definitions.v1#/key_unit"} + "r": { + "$ref": "qmk.definitions.v1#/signed_decimal" + }, + "rx": { + "$ref": "qmk.definitions.v1#/unsigned_decimal" + }, + "ry": { + "$ref": "qmk.definitions.v1#/unsigned_decimal" + }, + "h": { + "$ref": "qmk.definitions.v1#/key_unit" + }, + "w": { + "$ref": "qmk.definitions.v1#/key_unit" + }, + "x": { + "$ref": "qmk.definitions.v1#/key_unit" + }, + "y": { + "$ref": "qmk.definitions.v1#/key_unit" + } } } } @@ -429,51 +656,92 @@ "properties": { "driver": { "type": "string", - "enum": ["drv2605l", "solenoid"] + "enum": [ + "drv2605l", + "solenoid" + ] } } }, "leader_key": { "type": "object", "properties": { - "timing": {"type": "boolean"}, - "strict_processing": {"type": "boolean"}, - "timeout": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "timing": { + "type": "boolean" + }, + "strict_processing": { + "type": "boolean" + }, + "timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } } }, "matrix_pins": { "type": "object", "additionalProperties": false, "properties": { - "custom": {"type": "boolean"}, - "custom_lite": {"type": "boolean"}, - "ghost": {"type": "boolean"}, - "input_pressed_state": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "io_delay": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "custom": { + "type": "boolean" + }, + "custom_lite": { + "type": "boolean" + }, + "ghost": { + "type": "boolean" + }, + "input_pressed_state": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "io_delay": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, "direct": { "type": "array", - "items": {"$ref": "qmk.definitions.v1#/mcu_pin_array"} + "items": { + "$ref": "qmk.definitions.v1#/mcu_pin_array" + } }, - "cols": {"$ref": "qmk.definitions.v1#/mcu_pin_array"}, - "rows": {"$ref": "qmk.definitions.v1#/mcu_pin_array"} + "cols": { + "$ref": "qmk.definitions.v1#/mcu_pin_array" + }, + "rows": { + "$ref": "qmk.definitions.v1#/mcu_pin_array" + } } }, "mouse_key": { "type": "object", "properties": { - "enabled": {"type": "boolean"}, - "delay": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "interval": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "max_speed": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "time_to_max": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "wheel_delay": {"$ref": "qmk.definitions.v1#/unsigned_int_8"} + "enabled": { + "type": "boolean" + }, + "delay": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "interval": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "max_speed": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "time_to_max": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "wheel_delay": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + } } }, "oneshot": { "type": "object", "properties": { - "tap_toggle": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "timeout": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "tap_toggle": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } } }, "led_matrix": { @@ -481,17 +749,29 @@ "properties": { "animations": { "type": "object", - "propertyNames": {"$ref": "qmk.definitions.v1#/snake_case"}, - "additionalProperties": {"type": "boolean"} + "propertyNames": { + "$ref": "qmk.definitions.v1#/snake_case" + }, + "additionalProperties": { + "type": "boolean" + } }, "default": { "type": "object", "additionalProperties": false, "properties": { - "on": {"type": "boolean"}, - "animation": {"type": "string"}, - "val": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "speed": {"$ref": "qmk.definitions.v1#/unsigned_int_8"} + "on": { + "type": "boolean" + }, + "animation": { + "type": "string" + }, + "val": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "speed": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + } } }, "driver": { @@ -517,21 +797,41 @@ "type": "array", "minItems": 2, "maxItems": 2, - "items": {"$ref": "qmk.definitions.v1#/unsigned_int_8"} + "items": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + } + }, + "max_brightness": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "val_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "speed_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "led_flush_limit": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "led_process_limit": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "react_on_keyup": { + "type": "boolean" + }, + "sleep": { + "type": "boolean" }, - "max_brightness": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "timeout": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "val_steps": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "speed_steps": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "led_flush_limit": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "led_process_limit": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "react_on_keyup": {"type": "boolean"}, - "sleep": {"type": "boolean"}, "split_count": { "type": "array", "minItems": 2, "maxItems": 2, - "items": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "items": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } }, "layout": { "type": "array", @@ -548,9 +848,15 @@ "minimum": 0 } }, - "x": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "y": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "flags": {"$ref": "qmk.definitions.v1#/unsigned_int_8"} + "x": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "y": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "flags": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + } } } } @@ -561,19 +867,35 @@ "properties": { "animations": { "type": "object", - "propertyNames": {"$ref": "qmk.definitions.v1#/snake_case"}, - "additionalProperties": {"type": "boolean"} + "propertyNames": { + "$ref": "qmk.definitions.v1#/snake_case" + }, + "additionalProperties": { + "type": "boolean" + } }, "default": { "type": "object", "additionalProperties": false, "properties": { - "on": {"type": "boolean"}, - "animation": {"type": "string"}, - "hue": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "sat": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "val": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "speed": {"$ref": "qmk.definitions.v1#/unsigned_int_8"} + "on": { + "type": "boolean" + }, + "animation": { + "type": "string" + }, + "hue": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "sat": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "val": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "speed": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + } } }, "driver": { @@ -601,23 +923,47 @@ "type": "array", "minItems": 2, "maxItems": 2, - "items": {"$ref": "qmk.definitions.v1#/unsigned_int_8"} + "items": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + } + }, + "max_brightness": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "hue_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "sat_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "val_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "speed_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "led_flush_limit": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "led_process_limit": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "react_on_keyup": { + "type": "boolean" + }, + "sleep": { + "type": "boolean" }, - "max_brightness": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "timeout": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "hue_steps": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "sat_steps": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "val_steps": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "speed_steps": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "led_flush_limit": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "led_process_limit": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "react_on_keyup": {"type": "boolean"}, - "sleep": {"type": "boolean"}, "split_count": { "type": "array", "minItems": 2, "maxItems": 2, - "items": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "items": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } }, "layout": { "type": "array", @@ -634,9 +980,15 @@ "minimum": 0 } }, - "x": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "y": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "flags": {"$ref": "qmk.definitions.v1#/unsigned_int_8"} + "x": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "y": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "flags": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + } } } } @@ -648,48 +1000,84 @@ "properties": { "animations": { "type": "object", - "propertyNames": {"$ref": "qmk.definitions.v1#/snake_case"}, - "additionalProperties": {"type": "boolean"} + "propertyNames": { + "$ref": "qmk.definitions.v1#/snake_case" + }, + "additionalProperties": { + "type": "boolean" + } + }, + "brightness_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int" }, - "brightness_steps": {"$ref": "qmk.definitions.v1#/unsigned_int"}, "default": { "type": "object", "additionalProperties": false, "properties": { - "on": {"type": "boolean"}, - "animation": {"type": "string"}, - "hue": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "sat": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "val": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "speed": {"$ref": "qmk.definitions.v1#/unsigned_int_8"} + "on": { + "type": "boolean" + }, + "animation": { + "type": "string" + }, + "hue": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "sat": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "val": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "speed": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + } } }, "driver": { "type": "string", - "enum": ["apa102", "custom", "ws2812"] + "enum": [ + "apa102", + "custom", + "ws2812" + ] + }, + "hue_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int" }, - "hue_steps": {"$ref": "qmk.definitions.v1#/unsigned_int"}, "layers": { "type": "object", "additionalProperties": false, "properties": { - "blink": {"type": "boolean"}, - "enabled": {"type": "boolean"}, + "blink": { + "type": "boolean" + }, + "enabled": { + "type": "boolean" + }, "max": { "type": "integer", "minimum": 1, "maximum": 32 }, - "override_rgb": {"type": "boolean"} + "override_rgb": { + "type": "boolean" + } } }, - "led_count": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "led_count": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, "led_map": { "type": "array", "minItems": 2, - "items": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "items": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } + }, + "max_brightness": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" }, - "max_brightness": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, "pin": { "$ref": "qmk.definitions.v1#/mcu_pin", "$comment": "Deprecated: use ws2812.pin instead" @@ -698,14 +1086,22 @@ "type": "boolean", "$comment": "Deprecated: use ws2812.rgbw instead" }, - "saturation_steps": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "sleep": {"type": "boolean"}, - "split": {"type": "boolean"}, + "saturation_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "sleep": { + "type": "boolean" + }, + "split": { + "type": "boolean" + }, "split_count": { "type": "array", "minItems": 2, "maxItems": 2, - "items": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "items": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } } } }, @@ -713,9 +1109,15 @@ "type": "object", "additionalProperties": false, "properties": { - "enabled": {"type": "boolean"}, - "unlock_timeout": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "idle_timeout": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "enabled": { + "type": "boolean" + }, + "unlock_timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "idle_timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, "unlock_sequence": { "type": "array", "minItems": 1, @@ -736,10 +1138,16 @@ "type": "object", "additionalProperties": false, "properties": { - "enabled": {"type": "boolean"}, + "enabled": { + "type": "boolean" + }, "protocol": { "type": "string", - "enum": ["all", "geminipr", "txbolt"] + "enum": [ + "all", + "geminipr", + "txbolt" + ] } } }, @@ -747,13 +1155,26 @@ "type": "object", "additionalProperties": false, "properties": { - "enabled": {"type": "boolean"}, - "mouse_enabled": {"type": "boolean"}, - "clock_pin": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "data_pin": {"$ref": "qmk.definitions.v1#/mcu_pin"}, + "enabled": { + "type": "boolean" + }, + "mouse_enabled": { + "type": "boolean" + }, + "clock_pin": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "data_pin": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, "driver": { "type": "string", - "enum": ["busywait", "interrupt", "usart", "vendor"] + "enum": [ + "busywait", + "interrupt", + "usart", + "vendor" + ] } } }, @@ -761,8 +1182,10 @@ "type": "object", "additionalProperties": false, "properties": { - "enabled": {"type": "boolean"}, - "bootmagic":{ + "enabled": { + "type": "boolean" + }, + "bootmagic": { "type": "object", "additionalProperties": false, "properties": { @@ -787,11 +1210,19 @@ "properties": { "direct": { "type": "array", - "items": {"$ref": "qmk.definitions.v1#/mcu_pin_array"} + "items": { + "$ref": "qmk.definitions.v1#/mcu_pin_array" + } }, - "cols": {"$ref": "qmk.definitions.v1#/mcu_pin_array"}, - "rows": {"$ref": "qmk.definitions.v1#/mcu_pin_array"}, - "unused": {"$ref": "qmk.definitions.v1#/mcu_pin_array"} + "cols": { + "$ref": "qmk.definitions.v1#/mcu_pin_array" + }, + "rows": { + "$ref": "qmk.definitions.v1#/mcu_pin_array" + }, + "unused": { + "$ref": "qmk.definitions.v1#/mcu_pin_array" + } } } } @@ -818,7 +1249,9 @@ "type": "object", "additionalProperties": false, "properties": { - "pin": {"$ref": "qmk.definitions.v1#/mcu_pin"}, + "pin": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, "matrix_grid": { "$ref": "qmk.definitions.v1#/mcu_pin_array", "minItems": 2, @@ -841,9 +1274,15 @@ "properties": { "driver": { "type": "string", - "enum": ["bitbang", "usart", "vendor"] + "enum": [ + "bitbang", + "usart", + "vendor" + ] }, - "pin": {"$ref": "qmk.definitions.v1#/mcu_pin"} + "pin": { + "$ref": "qmk.definitions.v1#/mcu_pin" + } } }, "transport": { @@ -852,26 +1291,54 @@ "properties": { "protocol": { "type": "string", - "enum": ["custom", "i2c", "serial"] + "enum": [ + "custom", + "i2c", + "serial" + ] }, "sync": { "type": "object", "additionalProperties": false, "properties": { - "activity": {"type": "boolean"}, - "detected_os": {"type": "boolean"}, - "haptic": {"type": "boolean"}, - "layer_state": {"type": "boolean"}, - "indicators": {"type": "boolean"}, - "matrix_state": {"type": "boolean"}, - "modifiers": {"type": "boolean"}, - "oled": {"type": "boolean"}, - "st7565": {"type": "boolean"}, - "wpm": {"type": "boolean"} + "activity": { + "type": "boolean" + }, + "detected_os": { + "type": "boolean" + }, + "haptic": { + "type": "boolean" + }, + "layer_state": { + "type": "boolean" + }, + "indicators": { + "type": "boolean" + }, + "matrix_state": { + "type": "boolean" + }, + "modifiers": { + "type": "boolean" + }, + "oled": { + "type": "boolean" + }, + "st7565": { + "type": "boolean" + }, + "wpm": { + "type": "boolean" + } } }, - "watchdog": {"type": "boolean"}, - "watchdog_timeout": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "watchdog": { + "type": "boolean" + }, + "watchdog_timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, "sync_matrix_state": { "type": "boolean", "$comment": "Deprecated: use sync.matrix_state instead" @@ -886,42 +1353,82 @@ "type": "object", "additionalProperties": false, "properties": { - "enabled": {"type": "boolean"}, - "polling_interval": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "timeout": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "enabled": { + "type": "boolean" + }, + "polling_interval": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } } }, "main": { "type": "string", - "enum": ["eeprom", "left", "matrix_grid", "pin", "right"], + "enum": [ + "eeprom", + "left", + "matrix_grid", + "pin", + "right" + ], "$comment": "Deprecated: use config.h options for now" }, "matrix_grid": { "type": "array", - "items": {"$ref": "qmk.definitions.v1#/mcu_pin"}, + "items": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, "$comment": "Deprecated: use split.handedness.matrix_grid instead" } } }, "tags": { "type": "array", - "items": {"type": "string"} + "items": { + "type": "string" + } }, "tapping": { "type": "object", "properties": { - "force_hold": {"type": "boolean"}, - "force_hold_per_key": {"type": "boolean"}, - "ignore_mod_tap_interrupt": {"type": "boolean"}, - "hold_on_other_key_press": {"type": "boolean"}, - "hold_on_other_key_press_per_key": {"type": "boolean"}, - "permissive_hold": {"type": "boolean"}, - "permissive_hold_per_key": {"type": "boolean"}, - "retro": {"type": "boolean"}, - "retro_per_key": {"type": "boolean"}, - "term": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "term_per_key": {"type": "boolean"}, - "toggle": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "force_hold": { + "type": "boolean" + }, + "force_hold_per_key": { + "type": "boolean" + }, + "ignore_mod_tap_interrupt": { + "type": "boolean" + }, + "hold_on_other_key_press": { + "type": "boolean" + }, + "hold_on_other_key_press_per_key": { + "type": "boolean" + }, + "permissive_hold": { + "type": "boolean" + }, + "permissive_hold_per_key": { + "type": "boolean" + }, + "retro": { + "type": "boolean" + }, + "retro_per_key": { + "type": "boolean" + }, + "term": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "term_per_key": { + "type": "boolean" + }, + "toggle": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } } }, "usb": { @@ -932,38 +1439,70 @@ "$ref": "qmk.definitions.v1#/hex_number_4d", "$comment": "Deprecated: use device_version instead" }, - "device_version": {"$ref": "qmk.definitions.v1#/bcd_version"}, - "force_nkro": {"type": "boolean"}, - "pid": {"$ref": "qmk.definitions.v1#/hex_number_4d"}, - "vid": {"$ref": "qmk.definitions.v1#/hex_number_4d"}, - "max_power": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "no_startup_check": {"type": "boolean"}, - "polling_interval": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, + "device_version": { + "$ref": "qmk.definitions.v1#/bcd_version" + }, + "force_nkro": { + "type": "boolean" + }, + "pid": { + "$ref": "qmk.definitions.v1#/hex_number_4d" + }, + "vid": { + "$ref": "qmk.definitions.v1#/hex_number_4d" + }, + "max_power": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "no_startup_check": { + "type": "boolean" + }, + "polling_interval": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, "shared_endpoint": { "type": "object", "additionalProperties": false, "properties": { - "keyboard": {"type": "boolean"}, - "mouse": {"type": "boolean"} + "keyboard": { + "type": "boolean" + }, + "mouse": { + "type": "boolean" + } } }, - "suspend_wakeup_delay": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "wait_for_enumeration": {"type": "boolean"} + "suspend_wakeup_delay": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "wait_for_enumeration": { + "type": "boolean" + } } }, "qmk": { "type": "object", "additionalProperties": false, "properties": { - "keys_per_scan": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, - "tap_keycode_delay": {"$ref": "qmk.definitions.v1#/unsigned_int"}, - "tap_capslock_delay": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "keys_per_scan": { + "$ref": "qmk.definitions.v1#/unsigned_int_8" + }, + "tap_keycode_delay": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, + "tap_capslock_delay": { + "$ref": "qmk.definitions.v1#/unsigned_int" + }, "locking": { "type": "object", "additionalProperties": false, "properties": { - "enabled": {"type": "boolean"}, - "resync": {"type": "boolean"} + "enabled": { + "type": "boolean" + }, + "resync": { + "type": "boolean" + } } } } @@ -972,10 +1511,18 @@ "type": "object", "additionalProperties": false, "properties": { - "esc_output": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "esc_input": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "led": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "speaker": {"$ref": "qmk.definitions.v1#/mcu_pin"} + "esc_output": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "esc_input": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "led": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "speaker": { + "$ref": "qmk.definitions.v1#/mcu_pin" + } } }, "ws2812": { @@ -984,12 +1531,27 @@ "properties": { "driver": { "type": "string", - "enum": ["bitbang", "custom", "i2c", "pwm", "spi", "vendor"] + "enum": [ + "bitbang", + "custom", + "i2c", + "pwm", + "spi", + "vendor" + ] }, - "pin": {"$ref": "qmk.definitions.v1#/mcu_pin"}, - "rgbw": {"type": "boolean"}, - "i2c_address": {"$ref": "qmk.definitions.v1#/hex_number_2d"}, - "i2c_timeout": {"$ref": "qmk.definitions.v1#/unsigned_int"} + "pin": { + "$ref": "qmk.definitions.v1#/mcu_pin" + }, + "rgbw": { + "type": "boolean" + }, + "i2c_address": { + "$ref": "qmk.definitions.v1#/hex_number_2d" + }, + "i2c_timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int" + } } } } From 5d59e06f8df8bd280e2feaf17ce65a67fd535768 Mon Sep 17 00:00:00 2001 From: Buckwich Date: Tue, 12 Nov 2024 00:02:15 +0100 Subject: [PATCH 3/5] add description, default, and examples from `docs/reference_info_json.md` to json schema --- data/schemas/keyboard.jsonschema | 967 ++++++++++++++++++++++++------- 1 file changed, 751 insertions(+), 216 deletions(-) diff --git a/data/schemas/keyboard.jsonschema b/data/schemas/keyboard.jsonschema index 482134091d8..e970e83767b 100644 --- a/data/schemas/keyboard.jsonschema +++ b/data/schemas/keyboard.jsonschema @@ -24,16 +24,21 @@ ], "properties": { "pin_a": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the encoder's `A` pin." }, "pin_b": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the encoder's `B` pin." }, "resolution": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 4, + "description": "The number of edge transitions on both pins required to register an input." } } - } + }, + "description": "A list of encoder objects." } } }, @@ -56,20 +61,36 @@ }, "properties": { "keyboard_name": { - "$ref": "qmk.definitions.v1#/text_identifier" + "$ref": "qmk.definitions.v1#/text_identifier", + "description": "A free-form text string describing the keyboard. This will be used as the USB product string. Can include Unicode characters, escaped to ASCII eg. `\\u03A8` (Ψ).", + "examples": [ + "Clueboard 66%" + ] }, "keyboard_folder": { "$ref": "qmk.definitions.v1#/keyboard" }, "maintainer": { - "$ref": "qmk.definitions.v1#/text_identifier" + "$ref": "qmk.definitions.v1#/text_identifier", + "description": "GitHub username of the maintainer, or `qmk` for community maintained boards.", + "examples": [ + "skullydazed" + ] }, "manufacturer": { - "$ref": "qmk.definitions.v1#/text_identifier" + "$ref": "qmk.definitions.v1#/text_identifier", + "description": "A free-form text string describing the keyboard's manufacturer. This will be used as the USB manufacturer string. Can include Unicode characters, escaped to ASCII eg. `\\u03A8` (Ψ).", + "examples": [ + "Clueboard" + ] }, "url": { "type": "string", - "format": "uri" + "format": "uri", + "description": "A URL to the keyboard's product page, [QMK.fm/keyboards](https://qmk.fm/keyboards) page, or other page describing information about the keyboard.", + "examples": [ + "https://clueboard.co" + ] }, "development_board": { "type": "string", @@ -91,6 +112,10 @@ "helios", "liatris", "imera" + ], + "description": "The microcontroller development board, if applicable.", + "examples": [ + "promicro" ] }, "pin_compatible": { @@ -98,7 +123,8 @@ "enum": [ "promicro", "elite_c" - ] + ], + "description": "The form factor of the development board, if applicable. Must be one of `elite_c`, `promicro`." }, "processor": { "type": "string", @@ -155,22 +181,27 @@ "atmega328", "attiny85", "unknown" - ] + ], + "description": "The microcontroller in use on the keyboard. Required if `development_board` is not specified." }, "apa102": { "type": "object", "additionalProperties": false, "properties": { "data_pin": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to `DI` on the first LED in the chain." }, "clock_pin": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to `CI` on the first LED in the chain." }, "default_brightness": { "type": "integer", "minimum": 0, - "maximum": 31 + "maximum": 31, + "default": 31, + "description": "The initial global brightness level (independent of the RGB data), from 0 to 31." } } }, @@ -183,10 +214,14 @@ "additionalProperties": false, "properties": { "on": { - "type": "boolean" + "type": "boolean", + "default": true, + "description": "The default audio enabled state." }, "clicky": { - "type": "boolean" + "type": "boolean", + "default": true, + "description": "The default audio clicky enabled state." } } }, @@ -197,28 +232,37 @@ "dac_basic", "pwm_software", "pwm_hardware" - ] + ], + "description": "The driver to use. Must be one of `dac_additive`, `dac_basic`, `pwm_software`, `pwm_hardware`." }, "macro_beep": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Play a short beep for `\\a` (ASCII `BEL`) characters in Send String macros." }, "pins": { - "$ref": "qmk.definitions.v1#/mcu_pin_array" + "$ref": "qmk.definitions.v1#/mcu_pin_array", + "description": "The GPIO pin(s) connected to the speaker(s)." }, "power_control": { "type": "object", "additionalProperties": false, "properties": { "on_state": { - "$ref": "qmk.definitions.v1#/bit" + "$ref": "qmk.definitions.v1#/bit", + "default": "`1` (on = high)", + "description": "The logical GPIO state required to turn the speaker on." }, "pin": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to speaker power circuit." } } }, "voices": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Use multiple audio voices." } } }, @@ -233,48 +277,70 @@ "pwm", "software", "timer" - ] + ], + "default": "pwm", + "description": "The driver to use. Must be one of `custom`, `pwm`, `software`, `timer`." }, "default": { "type": "object", "additionalProperties": false, "properties": { "on": { - "type": "boolean" + "type": "boolean", + "default": true, + "description": "The default backlight enabled state." }, "breathing": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "The default backlight breathing state." }, "brightness": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": "`max_brightness`", + "description": "The default brightness level." } } }, "breathing": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Whether backlight breathing is enabled." }, "breathing_period": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": "`6` (6 seconds)", + "description": "The length of one backlight breathing cycle in seconds." }, "levels": { "type": "integer", "minimum": 1, - "maximum": 31 + "maximum": 31, + "default": 3, + "description": "The number of brightness levels (excluding off), from 1 to 31." }, "max_brightness": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 255, + "description": "The maximum PWM value which brightness is scaled to, from 0 to 255." }, "pin": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the backlight circuit." }, "pins": { - "$ref": "qmk.definitions.v1#/mcu_pin_array" + "$ref": "qmk.definitions.v1#/mcu_pin_array", + "description": "A list of GPIO pins connected to the backlight LEDs (`software` and `timer` drivers only)." }, "on_state": { - "$ref": "qmk.definitions.v1#/bit" + "$ref": "qmk.definitions.v1#/bit", + "default": "`1` (on = high)", + "description": "The logical GPIO state required to turn the LEDs on." }, "as_caps_lock": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Use the backlight as a Caps Lock indicator." } } }, @@ -288,7 +354,8 @@ "bluefruit_le", "custom", "rn42" - ] + ], + "description": "The driver to use. Must be one of `custom`, `bluefruit_le`, `rn42`." } } }, @@ -297,7 +364,9 @@ "additionalProperties": false, "properties": { "enabled": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enables the Bootmagic feature." }, "matrix": { "type": "array", @@ -306,14 +375,23 @@ "items": { "type": "integer", "minimum": 0 - } + }, + "default": [ + 0, + 0 + ], + "description": "The matrix position of the key to check during startup. This should generally be set to the (physically) top left key." } } }, "board": { "type": "string", "minLength": 2, - "pattern": "^[a-zA-Z_][0-9a-zA-Z_]*$" + "pattern": "^[a-zA-Z_][0-9a-zA-Z_]*$", + "description": "Override the default ChibiOS board name (ARM-based keyboards only).", + "examples": [ + "BLACKPILL_STM32_F411" + ] }, "bootloader": { "type": "string", @@ -339,11 +417,15 @@ "unknown", "usbasploader", "wb32-dfu" - ] + ], + "description": "The bootloader in use on the keyboard. Required if `development_board` is not specified." }, "bootloader_instructions": { "type": "string", - "description": "Instructions for putting the keyboard into a mode that allows for firmware flashing." + "description": "Instructions for putting the keyboard into a mode that allows for firmware flashing.", + "examples": [ + "Press the button marked RESET on the back of the PCB" + ] }, "build": { "type": "object", @@ -359,7 +441,8 @@ "sym_defer_pr", "sym_eager_pk", "sym_eager_pr" - ] + ], + "description": "The debounce algorithm to use. Must be one of `asym_eager_defer_pk`, `custom`, `sym_defer_g`, `sym_defer_pk`, `sym_defer_pr`, `sym_eager_pk`, `sym_eager_pr`." }, "firmware_format": { "type": "string", @@ -367,10 +450,13 @@ "bin", "hex", "uf2" - ] + ], + "description": "The format of the final output binary. Must be one of `bin`, `hex`, `uf2`." }, "lto": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enable Link-Time Optimization." } } }, @@ -379,29 +465,42 @@ "enum": [ "COL2ROW", "ROW2COL" - ] + ], + "description": "Which way the diodes are \"pointing\". Unused for `matrix_pins.direct`. Must be one of `COL2ROW`, `ROW2COL`." }, "debounce": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`5` (5 ms)", + "description": "The debounce time in milliseconds." }, "caps_word": { "type": "object", "additionalProperties": false, "properties": { "enabled": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enables the Caps Word feature." }, "both_shifts_turns_on": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Activate Caps Word by pressing both Shift keys." }, "double_tap_shift_turns_on": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Activate Caps Word by pressing Left Shift twice." }, "idle_timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`5000` (5 seconds)", + "description": "The amount of time before Caps Word automatically deactivates in milliseconds." }, "invert_on_shift": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Invert shift state instead of deactivating Caps Word when Shift is pressed." } } }, @@ -412,7 +511,9 @@ "$ref": "qmk.definitions.v1#/unsigned_int" }, "term": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`50` (50 ms)", + "description": "The amount of time to recognize a combo in milliseconds." } } }, @@ -420,13 +521,22 @@ "type": "array", "items": { "$ref": "qmk.definitions.v1#/filename" - } + }, + "description": "A list of community layouts supported by the keyboard.", + "examples": [ + [ + "60_ansi", + "60_iso" + ] + ] }, "dip_switch": { "$ref": "#/definitions/dip_switch_config", "properties": { "enabled": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enable the DIP Switches feature." }, "matrix_grid": { "type": "array", @@ -439,14 +549,36 @@ "type": "integer", "minimum": 0 } - } + }, + "description": "A list of matrix locations in the key matrix.", + "examples": [ + [ + [ + 0, + 6 + ], + [ + 1, + 6 + ], + [ + 2, + 6 + ] + ] + ] + }, + "pins": { + "description": "A list of GPIO pins connected to the MCU." } } }, "eeprom": { "properties": { "driver": { - "type": "string" + "type": "string", + "default": "vendor", + "description": "The EEPROM backend to use. Must be one of `custom`, `i2c`, `legacy_stm32_flash`, `spi`, `transient`, `vendor`, `wear_leveling`." }, "wear_leveling": { "type": "object", @@ -460,13 +592,16 @@ "legacy", "rp2040_flash", "spi_flash" - ] + ], + "description": "The driver to use. Must be one of `embedded_flash`, `legacy`, `rp2040_flash`, `spi_flash`, `custom`." }, "backing_size": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "Number of bytes used by the wear-leveling algorithm for its underlying storage, and needs to be a multiple of the logical size." }, "logical_size": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "Number of bytes “exposed” to the rest of QMK and denotes the size of the usable EEPROM." } } } @@ -489,28 +624,42 @@ "required": [ "lto" ] - } + }, + "description": "A dictionary of features to enable or disable.", + "examples": [ + { + "rgb_matrix": true, + "rgblight": false + } + ] }, "indicators": { "type": "object", "properties": { "caps_lock": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the Caps Lock LED." }, "num_lock": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the Num Lock LED." }, "scroll_lock": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the Scroll Lock LED." }, "compose": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the Compose LED." }, "kana": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the Kana LED." }, "on_state": { - "$ref": "qmk.definitions.v1#/bit" + "$ref": "qmk.definitions.v1#/bit", + "default": "`1` (on = high)", + "description": "The logical GPIO state required to turn the LEDs on." } } }, @@ -578,7 +727,14 @@ "type": "object", "additionalProperties": { "$ref": "qmk.definitions.v1#/layout_macro" - } + }, + "description": "A mapping of layout aliases to layout definitions.", + "examples": [ + { + "LAYOUT_ansi": "LAYOUT_60_ansi", + "LAYOUT_iso": "LAYOUT_60_iso" + } + ] }, "layouts": { "type": "object", @@ -609,11 +765,16 @@ ], "properties": { "encoder": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "The index of an encoder this key should be linked to" }, "label": { "type": "string", - "pattern": "^[^\\n]*$" + "pattern": "^[^\\n]*$", + "examples": [ + "Escape" + ], + "description": "What to name the key. This is *not* a key assignment as in the keymap, but should usually correspond to the keycode for the first layer of the default keymap." }, "matrix": { "type": "array", @@ -622,34 +783,49 @@ "items": { "type": "integer", "minimum": 0 - } + }, + "examples": [ + "`[0, 4]` (row 0, column 4)" + ], + "description": "The matrix position for the key." }, "r": { - "$ref": "qmk.definitions.v1#/signed_decimal" + "$ref": "qmk.definitions.v1#/signed_decimal", + "description": "The rotation angle in degrees. Currently not implemented." }, "rx": { - "$ref": "qmk.definitions.v1#/unsigned_decimal" + "$ref": "qmk.definitions.v1#/unsigned_decimal", + "description": "The absolute X position of the rotation axis. Currently not implemented." }, "ry": { - "$ref": "qmk.definitions.v1#/unsigned_decimal" + "$ref": "qmk.definitions.v1#/unsigned_decimal", + "description": "The absolute Y position of the rotation axis. Currently not implemented." }, "h": { - "$ref": "qmk.definitions.v1#/key_unit" + "$ref": "qmk.definitions.v1#/key_unit", + "description": "The height of the key, in key units.", + "default": "`1` (1u)" }, "w": { - "$ref": "qmk.definitions.v1#/key_unit" + "$ref": "qmk.definitions.v1#/key_unit", + "description": "The width of the key, in key units.", + "default": "`1` (1u)" }, "x": { - "$ref": "qmk.definitions.v1#/key_unit" + "$ref": "qmk.definitions.v1#/key_unit", + "description": "The absolute position of the key in the horizontal axis, in key units." }, "y": { - "$ref": "qmk.definitions.v1#/key_unit" + "$ref": "qmk.definitions.v1#/key_unit", + "description": "The absolute position of the key in the vertical axis, in key units." } } - } + }, + "description": "A list of key dictionaries comprising the layout. Each key dictionary contains:" } } - } + }, + "description": "A dictionary of layouts supported by the keyboard." }, "haptic": { "type": "object", @@ -667,13 +843,19 @@ "type": "object", "properties": { "timing": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Reset the `timeout` on each keypress." }, "strict_processing": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Do not extract the tap keycodes from Layer-Tap and Mod-Tap key events." }, "timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`300` (300 ms)", + "description": "The amount of time to complete a leader sequence in milliseconds." } } }, @@ -682,31 +864,77 @@ "additionalProperties": false, "properties": { "custom": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Whether to use a custom matrix scanning implementation." }, "custom_lite": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Whether to use a \"lite\" custom matrix scanning implementation." }, "ghost": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Whether the matrix has no anti-ghosting diodes." }, "input_pressed_state": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`0` (pressed = low)", + "description": "The logical GPIO state of the input pins when a key is pressed." }, "io_delay": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`30` (30 µs)", + "description": "The amount of time to wait between row/col selection and col/row pin reading, in microseconds." }, "direct": { "type": "array", "items": { "$ref": "qmk.definitions.v1#/mcu_pin_array" - } + }, + "description": "A 2-dimensional list of GPIO pins connected to each keyswitch, forming the \"matrix\" rows and columns.", + "examples": [ + [ + [ + "A0", + "A1", + "A2" + ], + [ + "B0", + "B1", + "B2" + ], + [ + "C0", + "C1", + "C2" + ] + ] + ] }, "cols": { - "$ref": "qmk.definitions.v1#/mcu_pin_array" + "$ref": "qmk.definitions.v1#/mcu_pin_array", + "description": "A list of GPIO pins connected to the matrix columns.", + "examples": [ + [ + "A0", + "A1", + "A2" + ] + ] }, "rows": { - "$ref": "qmk.definitions.v1#/mcu_pin_array" + "$ref": "qmk.definitions.v1#/mcu_pin_array", + "description": "A list of GPIO pins connected to the matrix rows.", + "examples": [ + [ + "B0", + "B1", + "B2" + ] + ] } } }, @@ -714,7 +942,9 @@ "type": "object", "properties": { "enabled": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enables the Mouse Keys feature." }, "delay": { "$ref": "qmk.definitions.v1#/unsigned_int_8" @@ -737,10 +967,12 @@ "type": "object", "properties": { "tap_toggle": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "The number of times to tap the key in order to hold it." }, "timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "The amount of time before the key is released in milliseconds." } } }, @@ -754,23 +986,39 @@ }, "additionalProperties": { "type": "boolean" - } + }, + "description": "A dictionary of effects to enable or disable. Effects which are absent default to `false`.", + "examples": [ + { + "alphas_mods": true, + "breathing": true, + "cycle_left_right": false + } + ] }, "default": { "type": "object", "additionalProperties": false, "properties": { "on": { - "type": "boolean" + "type": "boolean", + "default": true, + "description": "The default enabled state." }, "animation": { - "type": "string" + "type": "string", + "default": "solid", + "description": "The default effect. Must be one of `led_matrix.animations`" }, "val": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": "`max_brightness`", + "description": "The default brightness level." }, "speed": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 128, + "description": "The default animation speed." } } }, @@ -791,7 +1039,8 @@ "is31fl3745", "is31fl3746a", "snled27351" - ] + ], + "description": "The driver to use. Must be one of `custom`, `is31fl3218`, `is31fl3731`, `is31fl3733`, `is31fl3736`, `is31fl3737`, `is31fl3741`, `is31fl3742a`, `is31fl3743a`, `is31fl3745`, `is31fl3746a`, `snled27351`." }, "center_point": { "type": "array", @@ -799,31 +1048,52 @@ "maxItems": 2, "items": { "$ref": "qmk.definitions.v1#/unsigned_int_8" - } + }, + "default": [ + 112, + 32 + ], + "description": "The centroid (geometric center) of the LEDs. Used for certain effects." }, "max_brightness": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 255, + "description": "The maximum value which brightness is scaled to, from 0 to 255." }, "timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`0` (no timeout)", + "description": "The LED activity timeout in milliseconds." }, "val_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 8, + "description": "The number of brightness adjustment steps." }, "speed_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 16, + "description": "The number of speed adjustment steps." }, "led_flush_limit": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 16, + "description": "Limits in milliseconds how frequently an animation will update the LEDs." }, "led_process_limit": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`led_count / 5`", + "description": "Limits the number of LEDs to process in an animation per task run (increases keyboard responsiveness)." }, "react_on_keyup": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Animations react to keyup instead of keydown." }, "sleep": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Turn off the LEDs when the host goes to sleep." }, "split_count": { "type": "array", @@ -831,7 +1101,14 @@ "maxItems": 2, "items": { "$ref": "qmk.definitions.v1#/unsigned_int" - } + }, + "description": "For split keyboards, the number of LEDs on each half.", + "examples": [ + [ + 16, + 16 + ] + ] }, "layout": { "type": "array", @@ -858,7 +1135,8 @@ "$ref": "qmk.definitions.v1#/unsigned_int_8" } } - } + }, + "description": "List of LED configuration dictionaries. Each dictionary contains:" } } }, @@ -872,29 +1150,49 @@ }, "additionalProperties": { "type": "boolean" - } + }, + "description": "A dictionary of effects to enable or disable. Effects which are absent default to `false`.", + "examples": [ + { + "alphas_mods": true, + "breathing": true, + "cycle_left_right": false + } + ] }, "default": { "type": "object", "additionalProperties": false, "properties": { "on": { - "type": "boolean" + "type": "boolean", + "default": true, + "description": "The default enabled state." }, "animation": { - "type": "string" + "type": "string", + "default": "solid_color", + "description": "The default effect. Must be one of `rgb_matrix.animations`" }, "hue": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 0, + "description": "The default hue value." }, "sat": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 255, + "description": "The default saturation value." }, "val": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": "`max_brightness`", + "description": "The default brightness level." }, "speed": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 128, + "description": "The default animation speed." } } }, @@ -917,7 +1215,8 @@ "is31fl3746a", "snled27351", "ws2812" - ] + ], + "description": "The driver to use. Must be one of `aw20216s`, `custom`, `is31fl3218`, `is31fl3236`, `is31fl3729`, `is31fl3731`, `is31fl3733`, `is31fl3736`, `is31fl3737`, `is31fl3741`, `is31fl3742a`, `is31fl3743a`, `is31fl3745`, `is31fl3746a`, `snled27351`, `ws2812`." }, "center_point": { "type": "array", @@ -925,37 +1224,62 @@ "maxItems": 2, "items": { "$ref": "qmk.definitions.v1#/unsigned_int_8" - } + }, + "default": [ + 112, + 32 + ], + "description": "The centroid (geometric center) of the LEDs. Used for certain effects." }, "max_brightness": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 255, + "description": "The maximum value which the HSV \"V\" component is scaled to, from 0 to 255." }, "timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`0` (no timeout)", + "description": "The LED activity timeout in milliseconds." }, "hue_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 8, + "description": "The number of hue adjustment steps." }, "sat_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 16, + "description": "The number of saturation adjustment steps." }, "val_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 16, + "description": "The number of brightness adjustment steps." }, "speed_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 16, + "description": "The number of speed adjustment steps." }, "led_flush_limit": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 16, + "description": "Limits in milliseconds how frequently an animation will update the LEDs." }, "led_process_limit": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`led_count / 5`", + "description": "Limits the number of LEDs to process in an animation per task run (increases keyboard responsiveness)." }, "react_on_keyup": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Animations react to keyup instead of keydown." }, "sleep": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Turn off the LEDs when the host goes to sleep." }, "split_count": { "type": "array", @@ -963,7 +1287,14 @@ "maxItems": 2, "items": { "$ref": "qmk.definitions.v1#/unsigned_int" - } + }, + "description": "For split keyboards, the number of LEDs on each half.", + "examples": [ + [ + 16, + 16 + ] + ] }, "layout": { "type": "array", @@ -990,7 +1321,8 @@ "$ref": "qmk.definitions.v1#/unsigned_int_8" } } - } + }, + "description": "List of LED configuration dictionaries. Each dictionary contains:" } } }, @@ -1005,32 +1337,54 @@ }, "additionalProperties": { "type": "boolean" - } + }, + "description": "A dictionary of effects to enable or disable. Effects which are absent default to `false`.", + "examples": [ + { + "breathing": true, + "rainbow_mood": true, + "snake": false + } + ] }, "brightness_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 17, + "description": "The number of brightness adjustment steps." }, "default": { "type": "object", "additionalProperties": false, "properties": { "on": { - "type": "boolean" + "type": "boolean", + "default": true, + "description": "The default enabled state." }, "animation": { - "type": "string" + "type": "string", + "default": "static_light", + "description": "The default effect. Must be one of `rgblight.animations`" }, "hue": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 0, + "description": "The default hue value." }, "sat": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 255, + "description": "The default saturation value." }, "val": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": "`max_brightness`", + "description": "The default brightness level." }, "speed": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 0, + "description": "The default animation speed." } } }, @@ -1040,25 +1394,35 @@ "apa102", "custom", "ws2812" - ] + ], + "default": "ws2812", + "description": "The driver to use. Must be one of `apa102`, `custom`, `ws2812`." }, "hue_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 8, + "description": "The number of hue adjustment steps." }, "layers": { "type": "object", "additionalProperties": false, "properties": { "blink": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enable layer blinking API." }, "enabled": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enable RGB Lighting Layers." }, "max": { "type": "integer", "minimum": 1, - "maximum": 32 + "maximum": 32, + "default": 8, + "description": "The maximum layer count, from 1 to 32." }, "override_rgb": { "type": "boolean" @@ -1066,17 +1430,30 @@ } }, "led_count": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "The number of LEDs in the chain." }, "led_map": { "type": "array", "minItems": 2, "items": { "$ref": "qmk.definitions.v1#/unsigned_int" - } + }, + "description": "Remap LED indices.", + "examples": [ + [ + 4, + 3, + 2, + 1, + 0 + ] + ] }, "max_brightness": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 255, + "description": "The maximum value which the HSV \"V\" component is scaled to, from 0 to 255." }, "pin": { "$ref": "qmk.definitions.v1#/mcu_pin", @@ -1087,13 +1464,19 @@ "$comment": "Deprecated: use ws2812.rgbw instead" }, "saturation_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 17, + "description": "The number of saturation adjustment steps." }, "sleep": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Turn off the LEDs when the host goes to sleep." }, "split": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enable synchronization between split halves." }, "split_count": { "type": "array", @@ -1101,7 +1484,14 @@ "maxItems": 2, "items": { "$ref": "qmk.definitions.v1#/unsigned_int" - } + }, + "description": "When `rgblight.split` is enabled, the number of LEDs on each half.", + "examples": [ + [ + 10, + 10 + ] + ] } } }, @@ -1110,13 +1500,19 @@ "additionalProperties": false, "properties": { "enabled": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enable the Secure feature." }, "unlock_timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`5000` (5 seconds)", + "description": "Timeout for the user to perform the unlock sequence. Set to `0` to disable." }, "idle_timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`60000` (1 minute)", + "description": "Timeout while unlocked before returning to the locked state. Set to `0` to disable." }, "unlock_sequence": { "type": "array", @@ -1130,7 +1526,24 @@ "type": "integer", "minimum": 0 } - } + }, + "description": "A list of up to five matrix locations comprising the \"unlock sequence\".", + "examples": [ + [ + [ + 0, + 0 + ], + [ + 0, + 1 + ], + [ + 4, + 3 + ] + ] + ] } } }, @@ -1139,7 +1552,9 @@ "additionalProperties": false, "properties": { "enabled": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enable the Stenography feature." }, "protocol": { "type": "string", @@ -1147,7 +1562,9 @@ "all", "geminipr", "txbolt" - ] + ], + "default": "all", + "description": "The Steno protocol to use. Must be one of `all`, `geminipr`, `txbolt`." } } }, @@ -1156,16 +1573,22 @@ "additionalProperties": false, "properties": { "enabled": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enable the PS/2 feature." }, "mouse_enabled": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enable the PS/2 mouse handling." }, "clock_pin": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to `CLK` on the PS/2 device." }, "data_pin": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to `DATA` on the PS/2 device." }, "driver": { "type": "string", @@ -1174,7 +1597,9 @@ "interrupt", "usart", "vendor" - ] + ], + "default": "busywait", + "description": "The PS/2 driver to use. Must be one of `busywait`, `interrupt`, `usart`, `vendor`." } } }, @@ -1183,7 +1608,9 @@ "additionalProperties": false, "properties": { "enabled": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enable the Split Keyboard feature." }, "bootmagic": { "type": "object", @@ -1250,12 +1677,20 @@ "additionalProperties": false, "properties": { "pin": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to determine handedness." }, "matrix_grid": { "$ref": "qmk.definitions.v1#/mcu_pin_array", "minItems": 2, - "maxItems": 2 + "maxItems": 2, + "description": "The GPIO pins of the matrix position which determines the handedness.", + "examples": [ + [ + "A1", + "B5" + ] + ] } } }, @@ -1266,7 +1701,9 @@ "soft_serial_speed": { "type": "integer", "minimum": 0, - "maximum": 5 + "maximum": 5, + "default": 1, + "description": "The protocol speed, from `0` to `5` (`serial` transport protocol only)." }, "serial": { "type": "object", @@ -1278,10 +1715,13 @@ "bitbang", "usart", "vendor" - ] + ], + "default": "bitbang", + "description": "The driver to use. Must be one of `bitbang`, `usart`, `vendor`." }, "pin": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin to use for transmit and receive." } } }, @@ -1295,49 +1735,73 @@ "custom", "i2c", "serial" - ] + ], + "description": "The split transport protocol to use. Must be one of `custom`, `i2c`, `serial`." }, "sync": { "type": "object", "additionalProperties": false, "properties": { "activity": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Mirror the activity timestamps to the secondary half." }, "detected_os": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Mirror the [detected OS](features/os_detection) to the secondary half." }, "haptic": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Mirror the haptic state and process haptic feedback to the secondary half." }, "layer_state": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Mirror the layer state to the secondary half." }, "indicators": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Mirror the indicator state to the secondary half." }, "matrix_state": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Mirror the main/primary half's matrix state to the secondary half." }, "modifiers": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Mirror the modifier state to the secondary half." }, "oled": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Mirror the OLED on/off status to the secondary half." }, "st7565": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Mirror the ST7565 on/off status to the secondary half." }, "wpm": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Mirror the current WPM value to the secondary half." } } }, "watchdog": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Reboot the secondary half if it loses connection." }, "watchdog_timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "The amount of time to wait for communication from the primary half in milliseconds." }, "sync_matrix_state": { "type": "boolean", @@ -1354,13 +1818,18 @@ "additionalProperties": false, "properties": { "enabled": { - "type": "boolean" + "type": "boolean", + "description": "Detect USB connection when determining split half roles." }, "polling_interval": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`10` (10 ms)", + "description": "The polling frequency in milliseconds." }, "timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`2000` (2 seconds)", + "description": "The amount of time to wait for a USB connection in milliseconds." } } }, @@ -1388,7 +1857,15 @@ "type": "array", "items": { "type": "string" - } + }, + "description": "A list of tags describing the keyboard.", + "examples": [ + [ + "ortho", + "split", + "rgb" + ] + ] }, "tapping": { "type": "object", @@ -1403,31 +1880,40 @@ "type": "boolean" }, "hold_on_other_key_press": { - "type": "boolean" + "type": "boolean", + "default": false }, "hold_on_other_key_press_per_key": { - "type": "boolean" + "type": "boolean", + "default": false }, "permissive_hold": { - "type": "boolean" + "type": "boolean", + "default": false }, "permissive_hold_per_key": { - "type": "boolean" + "type": "boolean", + "default": false }, "retro": { - "type": "boolean" + "type": "boolean", + "default": false }, "retro_per_key": { - "type": "boolean" + "type": "boolean", + "default": false }, "term": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`200` (200 ms)" }, "term_per_key": { - "type": "boolean" + "type": "boolean", + "default": false }, "toggle": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 5 } } }, @@ -1440,43 +1926,71 @@ "$comment": "Deprecated: use device_version instead" }, "device_version": { - "$ref": "qmk.definitions.v1#/bcd_version" + "$ref": "qmk.definitions.v1#/bcd_version", + "description": "A BCD version number in the format `MM.m.r` (up to `99.9.9`).", + "examples": [ + "1.0.0" + ] }, "force_nkro": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Force NKRO to be active." }, "pid": { - "$ref": "qmk.definitions.v1#/hex_number_4d" + "$ref": "qmk.definitions.v1#/hex_number_4d", + "description": "The USB product ID as a four-digit hexadecimal number.", + "examples": [ + "0x23B0" + ] }, "vid": { - "$ref": "qmk.definitions.v1#/hex_number_4d" + "$ref": "qmk.definitions.v1#/hex_number_4d", + "description": "The USB vendor ID as a four-digit hexadecimal number.", + "examples": [ + "0xC1ED" + ] }, "max_power": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`500` (500 mA)", + "description": "The maximum current draw the host should expect from the device. This does not control the actual current usage." }, "no_startup_check": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Disable USB suspend check after keyboard startup." }, "polling_interval": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": "`1` (1 ms/1000 Hz)", + "description": "The frequency at which the host should poll the keyboard for reports." }, "shared_endpoint": { "type": "object", "additionalProperties": false, "properties": { "keyboard": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Send keyboard reports through the \"shared\" USB endpoint." }, "mouse": { - "type": "boolean" + "type": "boolean", + "default": true, + "description": "Send mouse reports through the \"shared\" USB endpoint." } } }, "suspend_wakeup_delay": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`0` (disabled)", + "description": "The amount of time to wait after sending a wakeup packet, in milliseconds." }, "wait_for_enumeration": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Force the keyboard to wait for USB enumeration before starting up." } } }, @@ -1488,20 +2002,28 @@ "$ref": "qmk.definitions.v1#/unsigned_int_8" }, "tap_keycode_delay": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`0` (no delay)", + "description": "The delay between keydown and keyup for tap events in milliseconds." }, "tap_capslock_delay": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`80` (80 ms)", + "description": "The delay between keydown and keyup for Caps Lock tap events in milliseconds." }, "locking": { "type": "object", "additionalProperties": false, "properties": { "enabled": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enable locking switch support." }, "resync": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Keep switch state consistent with keyboard LED state." } } } @@ -1512,16 +2034,20 @@ "additionalProperties": false, "properties": { "esc_output": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the designated \"exit bootloader\" key's column (if `COL2ROW`)." }, "esc_input": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the designated \"exit bootloader\" key's row (if `COL2ROW`)." }, "led": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to an LED to flash." }, "speaker": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to a speaker to click (can also be used for a second LED)." } } }, @@ -1538,19 +2064,28 @@ "pwm", "spi", "vendor" - ] + ], + "default": "bitbang", + "description": "The driver to use. Must be one of `bitbang`, `custom`, `i2c`, `pwm`, `spi`, `vendor`." }, "pin": { - "$ref": "qmk.definitions.v1#/mcu_pin" + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to `DI` on the first LED in the chain (`bitbang`, `pwm`, `spi` and `vendor` drivers only)." }, "rgbw": { - "type": "boolean" + "type": "boolean", + "default": false, + "description": "Enable RGBW LEDs." }, "i2c_address": { - "$ref": "qmk.definitions.v1#/hex_number_2d" + "$ref": "qmk.definitions.v1#/hex_number_2d", + "default": "0xB0", + "description": "The I²C address of the WS2812 controller (`i2c` driver only)." }, "i2c_timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int" + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`100` (100 ms)", + "description": "The I²C timeout in milliseconds (`i2c` driver only)." } } } From 9ba088133e94cd351a45642e755ce807f93d496e Mon Sep 17 00:00:00 2001 From: Buckwich Date: Wed, 13 Nov 2024 20:48:57 +0100 Subject: [PATCH 4/5] reformat --- data/schemas/keyboard.jsonschema | 290 ++++++------------------------- 1 file changed, 52 insertions(+), 238 deletions(-) diff --git a/data/schemas/keyboard.jsonschema b/data/schemas/keyboard.jsonschema index e970e83767b..bb82ccbe156 100644 --- a/data/schemas/keyboard.jsonschema +++ b/data/schemas/keyboard.jsonschema @@ -8,20 +8,14 @@ "properties": { "driver": { "type": "string", - "enum": [ - "custom", - "quadrature" - ] + "enum": ["custom", "quadrature"] }, "rotary": { "type": "array", "items": { "type": "object", "additionalProperties": false, - "required": [ - "pin_a", - "pin_b" - ], + "required": ["pin_a", "pin_b"], "properties": { "pin_a": { "$ref": "qmk.definitions.v1#/mcu_pin", @@ -54,18 +48,13 @@ "type": "object", "not": { "$comment": "reject via keys...", - "required": [ - "vendorId", - "productId" - ] + "required": ["vendorId", "productId"] }, "properties": { "keyboard_name": { "$ref": "qmk.definitions.v1#/text_identifier", "description": "A free-form text string describing the keyboard. This will be used as the USB product string. Can include Unicode characters, escaped to ASCII eg. `\\u03A8` (Ψ).", - "examples": [ - "Clueboard 66%" - ] + "examples": ["Clueboard 66%"] }, "keyboard_folder": { "$ref": "qmk.definitions.v1#/keyboard" @@ -73,24 +62,18 @@ "maintainer": { "$ref": "qmk.definitions.v1#/text_identifier", "description": "GitHub username of the maintainer, or `qmk` for community maintained boards.", - "examples": [ - "skullydazed" - ] + "examples": ["skullydazed"] }, "manufacturer": { "$ref": "qmk.definitions.v1#/text_identifier", "description": "A free-form text string describing the keyboard's manufacturer. This will be used as the USB manufacturer string. Can include Unicode characters, escaped to ASCII eg. `\\u03A8` (Ψ).", - "examples": [ - "Clueboard" - ] + "examples": ["Clueboard"] }, "url": { "type": "string", "format": "uri", "description": "A URL to the keyboard's product page, [QMK.fm/keyboards](https://qmk.fm/keyboards) page, or other page describing information about the keyboard.", - "examples": [ - "https://clueboard.co" - ] + "examples": ["https://clueboard.co"] }, "development_board": { "type": "string", @@ -114,16 +97,11 @@ "imera" ], "description": "The microcontroller development board, if applicable.", - "examples": [ - "promicro" - ] + "examples": ["promicro"] }, "pin_compatible": { "type": "string", - "enum": [ - "promicro", - "elite_c" - ], + "enum": ["promicro", "elite_c"], "description": "The form factor of the development board, if applicable. Must be one of `elite_c`, `promicro`." }, "processor": { @@ -272,12 +250,7 @@ "properties": { "driver": { "type": "string", - "enum": [ - "custom", - "pwm", - "software", - "timer" - ], + "enum": ["custom", "pwm", "software", "timer"], "default": "pwm", "description": "The driver to use. Must be one of `custom`, `pwm`, `software`, `timer`." }, @@ -350,11 +323,7 @@ "properties": { "driver": { "type": "string", - "enum": [ - "bluefruit_le", - "custom", - "rn42" - ], + "enum": ["bluefruit_le", "custom", "rn42"], "description": "The driver to use. Must be one of `custom`, `bluefruit_le`, `rn42`." } } @@ -376,10 +345,7 @@ "type": "integer", "minimum": 0 }, - "default": [ - 0, - 0 - ], + "default": [0, 0], "description": "The matrix position of the key to check during startup. This should generally be set to the (physically) top left key." } } @@ -389,9 +355,7 @@ "minLength": 2, "pattern": "^[a-zA-Z_][0-9a-zA-Z_]*$", "description": "Override the default ChibiOS board name (ARM-based keyboards only).", - "examples": [ - "BLACKPILL_STM32_F411" - ] + "examples": ["BLACKPILL_STM32_F411"] }, "bootloader": { "type": "string", @@ -423,9 +387,7 @@ "bootloader_instructions": { "type": "string", "description": "Instructions for putting the keyboard into a mode that allows for firmware flashing.", - "examples": [ - "Press the button marked RESET on the back of the PCB" - ] + "examples": ["Press the button marked RESET on the back of the PCB"] }, "build": { "type": "object", @@ -446,11 +408,7 @@ }, "firmware_format": { "type": "string", - "enum": [ - "bin", - "hex", - "uf2" - ], + "enum": ["bin", "hex", "uf2"], "description": "The format of the final output binary. Must be one of `bin`, `hex`, `uf2`." }, "lto": { @@ -462,10 +420,7 @@ }, "diode_direction": { "type": "string", - "enum": [ - "COL2ROW", - "ROW2COL" - ], + "enum": ["COL2ROW", "ROW2COL"], "description": "Which way the diodes are \"pointing\". Unused for `matrix_pins.direct`. Must be one of `COL2ROW`, `ROW2COL`." }, "debounce": { @@ -523,12 +478,7 @@ "$ref": "qmk.definitions.v1#/filename" }, "description": "A list of community layouts supported by the keyboard.", - "examples": [ - [ - "60_ansi", - "60_iso" - ] - ] + "examples": [["60_ansi", "60_iso"]] }, "dip_switch": { "$ref": "#/definitions/dip_switch_config", @@ -553,18 +503,9 @@ "description": "A list of matrix locations in the key matrix.", "examples": [ [ - [ - 0, - 6 - ], - [ - 1, - 6 - ], - [ - 2, - 6 - ] + [0, 6], + [1, 6], + [2, 6] ] ] }, @@ -621,9 +562,7 @@ "$ref": "qmk.definitions.v1#/snake_case" }, "not": { - "required": [ - "lto" - ] + "required": ["lto"] }, "description": "A dictionary of features to enable or disable.", "examples": [ @@ -681,14 +620,7 @@ "axes": { "type": "object", "propertyNames": { - "enum": [ - "x", - "y", - "z", - "rx", - "ry", - "rz" - ] + "enum": ["x", "y", "z", "rx", "ry", "rz"] }, "additionalProperties": { "oneOf": [ @@ -711,9 +643,7 @@ }, { "type": "string", - "enum": [ - "virtual" - ] + "enum": ["virtual"] } ] } @@ -759,10 +689,7 @@ "items": { "type": "object", "additionalProperties": false, - "required": [ - "x", - "y" - ], + "required": ["x", "y"], "properties": { "encoder": { "$ref": "qmk.definitions.v1#/unsigned_int", @@ -771,9 +698,7 @@ "label": { "type": "string", "pattern": "^[^\\n]*$", - "examples": [ - "Escape" - ], + "examples": ["Escape"], "description": "What to name the key. This is *not* a key assignment as in the keymap, but should usually correspond to the keycode for the first layer of the default keymap." }, "matrix": { @@ -784,9 +709,7 @@ "type": "integer", "minimum": 0 }, - "examples": [ - "`[0, 4]` (row 0, column 4)" - ], + "examples": ["`[0, 4]` (row 0, column 4)"], "description": "The matrix position for the key." }, "r": { @@ -832,10 +755,7 @@ "properties": { "driver": { "type": "string", - "enum": [ - "drv2605l", - "solenoid" - ] + "enum": ["drv2605l", "solenoid"] } } }, @@ -896,45 +816,21 @@ "description": "A 2-dimensional list of GPIO pins connected to each keyswitch, forming the \"matrix\" rows and columns.", "examples": [ [ - [ - "A0", - "A1", - "A2" - ], - [ - "B0", - "B1", - "B2" - ], - [ - "C0", - "C1", - "C2" - ] + ["A0", "A1", "A2"], + ["B0", "B1", "B2"], + ["C0", "C1", "C2"] ] ] }, "cols": { "$ref": "qmk.definitions.v1#/mcu_pin_array", "description": "A list of GPIO pins connected to the matrix columns.", - "examples": [ - [ - "A0", - "A1", - "A2" - ] - ] + "examples": [["A0", "A1", "A2"]] }, "rows": { "$ref": "qmk.definitions.v1#/mcu_pin_array", "description": "A list of GPIO pins connected to the matrix rows.", - "examples": [ - [ - "B0", - "B1", - "B2" - ] - ] + "examples": [["B0", "B1", "B2"]] } } }, @@ -1049,10 +945,7 @@ "items": { "$ref": "qmk.definitions.v1#/unsigned_int_8" }, - "default": [ - 112, - 32 - ], + "default": [112, 32], "description": "The centroid (geometric center) of the LEDs. Used for certain effects." }, "max_brightness": { @@ -1103,12 +996,7 @@ "$ref": "qmk.definitions.v1#/unsigned_int" }, "description": "For split keyboards, the number of LEDs on each half.", - "examples": [ - [ - 16, - 16 - ] - ] + "examples": [[16, 16]] }, "layout": { "type": "array", @@ -1225,10 +1113,7 @@ "items": { "$ref": "qmk.definitions.v1#/unsigned_int_8" }, - "default": [ - 112, - 32 - ], + "default": [112, 32], "description": "The centroid (geometric center) of the LEDs. Used for certain effects." }, "max_brightness": { @@ -1289,12 +1174,7 @@ "$ref": "qmk.definitions.v1#/unsigned_int" }, "description": "For split keyboards, the number of LEDs on each half.", - "examples": [ - [ - 16, - 16 - ] - ] + "examples": [[16, 16]] }, "layout": { "type": "array", @@ -1390,11 +1270,7 @@ }, "driver": { "type": "string", - "enum": [ - "apa102", - "custom", - "ws2812" - ], + "enum": ["apa102", "custom", "ws2812"], "default": "ws2812", "description": "The driver to use. Must be one of `apa102`, `custom`, `ws2812`." }, @@ -1440,15 +1316,7 @@ "$ref": "qmk.definitions.v1#/unsigned_int" }, "description": "Remap LED indices.", - "examples": [ - [ - 4, - 3, - 2, - 1, - 0 - ] - ] + "examples": [[4, 3, 2, 1, 0]] }, "max_brightness": { "$ref": "qmk.definitions.v1#/unsigned_int_8", @@ -1486,12 +1354,7 @@ "$ref": "qmk.definitions.v1#/unsigned_int" }, "description": "When `rgblight.split` is enabled, the number of LEDs on each half.", - "examples": [ - [ - 10, - 10 - ] - ] + "examples": [[10, 10]] } } }, @@ -1530,18 +1393,9 @@ "description": "A list of up to five matrix locations comprising the \"unlock sequence\".", "examples": [ [ - [ - 0, - 0 - ], - [ - 0, - 1 - ], - [ - 4, - 3 - ] + [0, 0], + [0, 1], + [4, 3] ] ] } @@ -1558,11 +1412,7 @@ }, "protocol": { "type": "string", - "enum": [ - "all", - "geminipr", - "txbolt" - ], + "enum": ["all", "geminipr", "txbolt"], "default": "all", "description": "The Steno protocol to use. Must be one of `all`, `geminipr`, `txbolt`." } @@ -1592,12 +1442,7 @@ }, "driver": { "type": "string", - "enum": [ - "busywait", - "interrupt", - "usart", - "vendor" - ], + "enum": ["busywait", "interrupt", "usart", "vendor"], "default": "busywait", "description": "The PS/2 driver to use. Must be one of `busywait`, `interrupt`, `usart`, `vendor`." } @@ -1685,12 +1530,7 @@ "minItems": 2, "maxItems": 2, "description": "The GPIO pins of the matrix position which determines the handedness.", - "examples": [ - [ - "A1", - "B5" - ] - ] + "examples": [["A1", "B5"]] } } }, @@ -1711,11 +1551,7 @@ "properties": { "driver": { "type": "string", - "enum": [ - "bitbang", - "usart", - "vendor" - ], + "enum": ["bitbang", "usart", "vendor"], "default": "bitbang", "description": "The driver to use. Must be one of `bitbang`, `usart`, `vendor`." }, @@ -1731,11 +1567,7 @@ "properties": { "protocol": { "type": "string", - "enum": [ - "custom", - "i2c", - "serial" - ], + "enum": ["custom", "i2c", "serial"], "description": "The split transport protocol to use. Must be one of `custom`, `i2c`, `serial`." }, "sync": { @@ -1835,13 +1667,7 @@ }, "main": { "type": "string", - "enum": [ - "eeprom", - "left", - "matrix_grid", - "pin", - "right" - ], + "enum": ["eeprom", "left", "matrix_grid", "pin", "right"], "$comment": "Deprecated: use config.h options for now" }, "matrix_grid": { @@ -1859,13 +1685,7 @@ "type": "string" }, "description": "A list of tags describing the keyboard.", - "examples": [ - [ - "ortho", - "split", - "rgb" - ] - ] + "examples": [["ortho", "split", "rgb"]] }, "tapping": { "type": "object", @@ -1928,9 +1748,7 @@ "device_version": { "$ref": "qmk.definitions.v1#/bcd_version", "description": "A BCD version number in the format `MM.m.r` (up to `99.9.9`).", - "examples": [ - "1.0.0" - ] + "examples": ["1.0.0"] }, "force_nkro": { "type": "boolean", @@ -1940,16 +1758,12 @@ "pid": { "$ref": "qmk.definitions.v1#/hex_number_4d", "description": "The USB product ID as a four-digit hexadecimal number.", - "examples": [ - "0x23B0" - ] + "examples": ["0x23B0"] }, "vid": { "$ref": "qmk.definitions.v1#/hex_number_4d", "description": "The USB vendor ID as a four-digit hexadecimal number.", - "examples": [ - "0xC1ED" - ] + "examples": ["0xC1ED"] }, "max_power": { "$ref": "qmk.definitions.v1#/unsigned_int", From 250c987bc88b341655f48f8dbc4df6ca867a63d9 Mon Sep 17 00:00:00 2001 From: Buckwich Date: Wed, 13 Nov 2024 21:53:29 +0100 Subject: [PATCH 5/5] condense --- data/schemas/keyboard.jsonschema | 3480 ++++++++++++++---------------- 1 file changed, 1660 insertions(+), 1820 deletions(-) diff --git a/data/schemas/keyboard.jsonschema b/data/schemas/keyboard.jsonschema index bb82ccbe156..b69fe629962 100644 --- a/data/schemas/keyboard.jsonschema +++ b/data/schemas/keyboard.jsonschema @@ -3,1905 +3,1745 @@ "$id": "qmk.keyboard.v1", "title": "Keyboard Information", "definitions": { - "encoder_config": { - "type": "object", - "properties": { - "driver": { - "type": "string", - "enum": ["custom", "quadrature"] + "encoder_config": { + "type": "object", + "properties": { + "driver": { + "type": "string", + "enum": ["custom", "quadrature"] + }, + "rotary": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": false, + "required": ["pin_a", "pin_b"], + "properties": { + "pin_a": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the encoder's `A` pin." }, - "rotary": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "required": ["pin_a", "pin_b"], - "properties": { - "pin_a": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to the encoder's `A` pin." - }, - "pin_b": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to the encoder's `B` pin." - }, - "resolution": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 4, - "description": "The number of edge transitions on both pins required to register an input." - } - } - }, - "description": "A list of encoder objects." + "pin_b": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the encoder's `B` pin." + }, + "resolution": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 4, + "description": "The number of edge transitions on both pins required to register an input." } - } - }, - "dip_switch_config": { - "type": "object", - "properties": { - "pins": { - "$ref": "qmk.definitions.v1#/mcu_pin_array" - } - } + } + }, + "description": "A list of encoder objects." + } } + }, + "dip_switch_config": { + "type": "object", + "properties": { + "pins": { + "$ref": "qmk.definitions.v1#/mcu_pin_array", + "description": "A list of GPIO pins connected to the MCU." + } + } + } }, "type": "object", "not": { - "$comment": "reject via keys...", - "required": ["vendorId", "productId"] + "$comment": "reject via keys...", + "required": ["vendorId", "productId"] }, "properties": { - "keyboard_name": { - "$ref": "qmk.definitions.v1#/text_identifier", - "description": "A free-form text string describing the keyboard. This will be used as the USB product string. Can include Unicode characters, escaped to ASCII eg. `\\u03A8` (Ψ).", - "examples": ["Clueboard 66%"] - }, - "keyboard_folder": { - "$ref": "qmk.definitions.v1#/keyboard" - }, - "maintainer": { - "$ref": "qmk.definitions.v1#/text_identifier", - "description": "GitHub username of the maintainer, or `qmk` for community maintained boards.", - "examples": ["skullydazed"] - }, - "manufacturer": { - "$ref": "qmk.definitions.v1#/text_identifier", - "description": "A free-form text string describing the keyboard's manufacturer. This will be used as the USB manufacturer string. Can include Unicode characters, escaped to ASCII eg. `\\u03A8` (Ψ).", - "examples": ["Clueboard"] - }, - "url": { + "keyboard_name": { + "$ref": "qmk.definitions.v1#/text_identifier", + "description": "A free-form text string describing the keyboard. This will be used as the USB product string. Can include Unicode characters, escaped to ASCII eg. `\\u03A8` (Ψ).", + "examples": ["Clueboard 66%"] + }, + "keyboard_folder": {"$ref": "qmk.definitions.v1#/keyboard"}, + "maintainer": { + "$ref": "qmk.definitions.v1#/text_identifier", + "description": "GitHub username of the maintainer, or `qmk` for community maintained boards.", + "examples": ["skullydazed"] + }, + "manufacturer": { + "$ref": "qmk.definitions.v1#/text_identifier", + "description": "A free-form text string describing the keyboard's manufacturer. This will be used as the USB manufacturer string. Can include Unicode characters, escaped to ASCII eg. `\\u03A8` (Ψ).", + "examples": ["Clueboard"] + }, + "url": { + "type": "string", + "format": "uri", + "description": "A URL to the keyboard's product page, [QMK.fm/keyboards](https://qmk.fm/keyboards) page, or other page describing information about the keyboard.", + "examples": ["https://clueboard.co"] + }, + "development_board": { + "type": "string", + "enum": [ + "promicro", + "elite_c", + "elite_pi", + "proton_c", + "kb2040", + "promicro_rp2040", + "blok", + "michi", + "bit_c_pro", + "stemcell", + "bluepill", + "blackpill_f401", + "blackpill_f411", + "bonsai_c4", + "helios", + "liatris", + "imera" + ], + "description": "The microcontroller development board, if applicable.", + "examples": ["promicro"] + }, + "pin_compatible": { + "type": "string", + "enum": ["promicro", "elite_c"], + "description": "The form factor of the development board, if applicable. Must be one of `elite_c`, `promicro`." + }, + "processor": { + "type": "string", + "enum": [ + "cortex-m0", + "cortex-m0plus", + "cortex-m3", + "cortex-m4", + "cortex-m7", + "cortex-m23", + "cortex-m33", + "cortex-m35p", + "cortex-m55", + "cortex-m85", + "MKL26Z64", + "MK20DX128", + "MK20DX256", + "MK64FX512", + "MK66FX1M0", + "RP2040", + "STM32F042", + "STM32F072", + "STM32F103", + "STM32F303", + "STM32F401", + "STM32F405", + "STM32F407", + "STM32F411", + "STM32F446", + "STM32G431", + "STM32G474", + "STM32H723", + "STM32H733", + "STM32L412", + "STM32L422", + "STM32L432", + "STM32L433", + "STM32L442", + "STM32L443", + "GD32VF103", + "WB32F3G71", + "WB32FQ95", + "atmega16u2", + "atmega32u2", + "atmega16u4", + "atmega32u4", + "at90usb162", + "at90usb646", + "at90usb647", + "at90usb1286", + "at90usb1287", + "atmega32a", + "atmega328p", + "atmega328", + "attiny85", + "unknown" + ], + "description": "The microcontroller in use on the keyboard. Required if `development_board` is not specified." + }, + "apa102": { + "type": "object", + "additionalProperties": false, + "properties": { + "data_pin": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to `DI` on the first LED in the chain." + }, + "clock_pin": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to `CI` on the first LED in the chain." + }, + "default_brightness": { + "type": "integer", + "minimum": 0, + "maximum": 31, + "default": 31, + "description": "The initial global brightness level (independent of the RGB data), from 0 to 31." + } + } + }, + "audio": { + "type": "object", + "additionalProperties": false, + "properties": { + "default": { + "type": "object", + "additionalProperties": false, + "properties": { + "on": { + "type": "boolean", + "default": true, + "description": "The default audio enabled state." + }, + "clicky": { + "type": "boolean", + "default": true, + "description": "The default audio clicky enabled state." + } + } + }, + "driver": { "type": "string", - "format": "uri", - "description": "A URL to the keyboard's product page, [QMK.fm/keyboards](https://qmk.fm/keyboards) page, or other page describing information about the keyboard.", - "examples": ["https://clueboard.co"] - }, - "development_board": { + "enum": ["dac_additive", "dac_basic", "pwm_software", "pwm_hardware"], + "description": "The driver to use. Must be one of `dac_additive`, `dac_basic`, `pwm_software`, `pwm_hardware`." + }, + "macro_beep": { + "type": "boolean", + "default": false, + "description": "Play a short beep for `\\a` (ASCII `BEL`) characters in Send String macros." + }, + "pins": { + "$ref": "qmk.definitions.v1#/mcu_pin_array", + "description": "The GPIO pin(s) connected to the speaker(s)." + }, + "power_control": { + "type": "object", + "additionalProperties": false, + "properties": { + "on_state": { + "$ref": "qmk.definitions.v1#/bit", + "default": "`1` (on = high)", + "description": "The logical GPIO state required to turn the speaker on." + }, + "pin": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to speaker power circuit." + } + } + }, + "voices": { + "type": "boolean", + "default": false, + "description": "Use multiple audio voices." + } + } + }, + "backlight": { + "type": "object", + "additionalProperties": false, + "properties": { + "driver": { + "type": "string", + "enum": ["custom", "pwm", "software", "timer"], + "default": "pwm", + "description": "The driver to use. Must be one of `custom`, `pwm`, `software`, `timer`." + }, + "default": { + "type": "object", + "additionalProperties": false, + "properties": { + "on": { + "type": "boolean", + "default": true, + "description": "The default backlight enabled state." + }, + "breathing": { + "type": "boolean", + "default": false, + "description": "The default backlight breathing state." + }, + "brightness": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": "`max_brightness`", + "description": "The default brightness level." + } + } + }, + "breathing": { + "type": "boolean", + "default": false, + "description": "Whether backlight breathing is enabled." + }, + "breathing_period": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": "`6` (6 seconds)", + "description": "The length of one backlight breathing cycle in seconds." + }, + "levels": { + "type": "integer", + "minimum": 1, + "maximum": 31, + "default": 3, + "description": "The number of brightness levels (excluding off), from 1 to 31." + }, + "max_brightness": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 255, + "description": "The maximum PWM value which brightness is scaled to, from 0 to 255." + }, + "pin": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the backlight circuit." + }, + "pins": { + "$ref": "qmk.definitions.v1#/mcu_pin_array", + "description": "A list of GPIO pins connected to the backlight LEDs (`software` and `timer` drivers only)." + }, + "on_state": { + "$ref": "qmk.definitions.v1#/bit", + "default": "`1` (on = high)", + "description": "The logical GPIO state required to turn the LEDs on." + }, + "as_caps_lock": { + "type": "boolean", + "default": false, + "description": "Use the backlight as a Caps Lock indicator." + } + } + }, + "bluetooth": { + "type": "object", + "additionalProperties": false, + "properties": { + "driver": { + "type": "string", + "enum": ["bluefruit_le", "custom", "rn42"], + "description": "The driver to use. Must be one of `custom`, `bluefruit_le`, `rn42`." + } + } + }, + "bootmagic": { + "type": "object", + "additionalProperties": false, + "properties": { + "enabled": { + "type": "boolean", + "default": false, + "description": "Enables the Bootmagic feature." + }, + "matrix": { + "type": "array", + "minItems": 2, + "maxItems": 2, + "items": {"type": "integer", "minimum": 0}, + "default": [0, 0], + "description": "The matrix position of the key to check during startup. This should generally be set to the (physically) top left key." + } + } + }, + "board": { + "type": "string", + "minLength": 2, + "pattern": "^[a-zA-Z_][0-9a-zA-Z_]*$", + "description": "Override the default ChibiOS board name (ARM-based keyboards only).", + "examples": ["BLACKPILL_STM32_F411"] + }, + "bootloader": { + "type": "string", + "enum": [ + "apm32-dfu", + "atmel-dfu", + "bootloadhid", + "caterina", + "custom", + "gd32v-dfu", + "halfkay", + "kiibohd", + "lufa-dfu", + "lufa-ms", + "md-boot", + "qmk-dfu", + "qmk-hid", + "rp2040", + "stm32-dfu", + "stm32duino", + "tinyuf2", + "uf2boot", + "unknown", + "usbasploader", + "wb32-dfu" + ], + "description": "The bootloader in use on the keyboard. Required if `development_board` is not specified." + }, + "bootloader_instructions": { + "type": "string", + "description": "Instructions for putting the keyboard into a mode that allows for firmware flashing.", + "examples": ["Press the button marked RESET on the back of the PCB"] + }, + "build": { + "type": "object", + "additionalProperties": false, + "properties": { + "debounce_type": { "type": "string", "enum": [ - "promicro", - "elite_c", - "elite_pi", - "proton_c", - "kb2040", - "promicro_rp2040", - "blok", - "michi", - "bit_c_pro", - "stemcell", - "bluepill", - "blackpill_f401", - "blackpill_f411", - "bonsai_c4", - "helios", - "liatris", - "imera" + "asym_eager_defer_pk", + "custom", + "sym_defer_g", + "sym_defer_pk", + "sym_defer_pr", + "sym_eager_pk", + "sym_eager_pr" ], - "description": "The microcontroller development board, if applicable.", - "examples": ["promicro"] - }, - "pin_compatible": { + "description": "The debounce algorithm to use. Must be one of `asym_eager_defer_pk`, `custom`, `sym_defer_g`, `sym_defer_pk`, `sym_defer_pr`, `sym_eager_pk`, `sym_eager_pr`." + }, + "firmware_format": { "type": "string", - "enum": ["promicro", "elite_c"], - "description": "The form factor of the development board, if applicable. Must be one of `elite_c`, `promicro`." - }, - "processor": { + "enum": ["bin", "hex", "uf2"], + "description": "The format of the final output binary. Must be one of `bin`, `hex`, `uf2`." + }, + "lto": { + "type": "boolean", + "default": false, + "description": "Enable Link-Time Optimization." + } + } + }, + "diode_direction": { + "type": "string", + "enum": ["COL2ROW", "ROW2COL"], + "description": "Which way the diodes are \"pointing\". Unused for `matrix_pins.direct`. Must be one of `COL2ROW`, `ROW2COL`." + }, + "debounce": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`5` (5 ms)", + "description": "The debounce time in milliseconds." + }, + "caps_word": { + "type": "object", + "additionalProperties": false, + "properties": { + "enabled": { + "type": "boolean", + "default": false, + "description": "Enables the Caps Word feature." + }, + "both_shifts_turns_on": { + "type": "boolean", + "default": false, + "description": "Activate Caps Word by pressing both Shift keys." + }, + "double_tap_shift_turns_on": { + "type": "boolean", + "default": false, + "description": "Activate Caps Word by pressing Left Shift twice." + }, + "idle_timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`5000` (5 seconds)", + "description": "The amount of time before Caps Word automatically deactivates in milliseconds." + }, + "invert_on_shift": { + "type": "boolean", + "default": false, + "description": "Invert shift state instead of deactivating Caps Word when Shift is pressed." + } + } + }, + "combo": { + "type": "object", + "properties": { + "count": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "term": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`50` (50 ms)", + "description": "The amount of time to recognize a combo in milliseconds." + } + } + }, + "community_layouts": { + "type": "array", + "items": {"$ref": "qmk.definitions.v1#/filename"}, + "description": "A list of community layouts supported by the keyboard.", + "examples": [ + ["60_ansi", "60_iso"] + ] + }, + "dip_switch": { + "$ref": "#/definitions/dip_switch_config", + "properties": { + "enabled": { + "type": "boolean", + "default": false, + "description": "Enable the DIP Switches feature." + }, + "matrix_grid": { + "type": "array", + "minItems": 1, + "items": { + "type": "array", + "minItems": 2, + "maxItems": 2, + "items": {"type": "integer", "minimum": 0} + }, + "description": "A list of matrix locations in the key matrix.", + "examples": [ + [ + [0, 6], + [1, 6], + [2, 6] + ] + ] + } + } + }, + "eeprom": { + "properties": { + "driver": { "type": "string", - "enum": [ - "cortex-m0", - "cortex-m0plus", - "cortex-m3", - "cortex-m4", - "cortex-m7", - "cortex-m23", - "cortex-m33", - "cortex-m35p", - "cortex-m55", - "cortex-m85", - "MKL26Z64", - "MK20DX128", - "MK20DX256", - "MK64FX512", - "MK66FX1M0", - "RP2040", - "STM32F042", - "STM32F072", - "STM32F103", - "STM32F303", - "STM32F401", - "STM32F405", - "STM32F407", - "STM32F411", - "STM32F446", - "STM32G431", - "STM32G474", - "STM32H723", - "STM32H733", - "STM32L412", - "STM32L422", - "STM32L432", - "STM32L433", - "STM32L442", - "STM32L443", - "GD32VF103", - "WB32F3G71", - "WB32FQ95", - "atmega16u2", - "atmega32u2", - "atmega16u4", - "atmega32u4", - "at90usb162", - "at90usb646", - "at90usb647", - "at90usb1286", - "at90usb1287", - "atmega32a", - "atmega328p", - "atmega328", - "attiny85", - "unknown" - ], - "description": "The microcontroller in use on the keyboard. Required if `development_board` is not specified." - }, - "apa102": { + "default": "vendor", + "description": "The EEPROM backend to use. Must be one of `custom`, `i2c`, `legacy_stm32_flash`, `spi`, `transient`, `vendor`, `wear_leveling`." + }, + "wear_leveling": { "type": "object", "additionalProperties": false, "properties": { - "data_pin": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to `DI` on the first LED in the chain." - }, - "clock_pin": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to `CI` on the first LED in the chain." - }, - "default_brightness": { - "type": "integer", - "minimum": 0, - "maximum": 31, - "default": 31, - "description": "The initial global brightness level (independent of the RGB data), from 0 to 31." - } + "driver": { + "type": "string", + "enum": [ + "custom", + "embedded_flash", + "legacy", + "rp2040_flash", + "spi_flash" + ], + "description": "The driver to use. Must be one of `embedded_flash`, `legacy`, `rp2040_flash`, `spi_flash`, `custom`." + }, + "backing_size": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "Number of bytes used by the wear-leveling algorithm for its underlying storage, and needs to be a multiple of the logical size." + }, + "logical_size": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "Number of bytes “exposed” to the rest of QMK and denotes the size of the usable EEPROM." + } } + } + } + }, + "encoder": { + "$ref": "#/definitions/encoder_config", + "properties": { + "enabled": {"type": "boolean"} + } + }, + "features": { + "$ref": "qmk.definitions.v1#/boolean_array", + "propertyNames": {"$ref": "qmk.definitions.v1#/snake_case"}, + "not": { + "required": ["lto"] }, - "audio": { + "description": "A dictionary of features to enable or disable.", + "examples": [ + {"rgb_matrix": true, "rgblight": false} + ] + }, + "indicators": { + "type": "object", + "properties": { + "caps_lock": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the Caps Lock LED." + }, + "num_lock": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the Num Lock LED." + }, + "scroll_lock": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the Scroll Lock LED." + }, + "compose": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the Compose LED." + }, + "kana": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the Kana LED." + }, + "on_state": { + "$ref": "qmk.definitions.v1#/bit", + "default": "`1` (on = high)", + "description": "The logical GPIO state required to turn the LEDs on." + } + } + }, + "joystick": { + "type": "object", + "properties": { + "enabled": {"type": "boolean"}, + "driver": {"type": "string"}, + "button_count": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "axis_resolution": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "axes": { "type": "object", - "additionalProperties": false, - "properties": { - "default": { - "type": "object", - "additionalProperties": false, - "properties": { - "on": { - "type": "boolean", - "default": true, - "description": "The default audio enabled state." - }, - "clicky": { - "type": "boolean", - "default": true, - "description": "The default audio clicky enabled state." - } - } + "propertyNames": { + "enum": ["x", "y", "z", "rx", "ry", "rz"] + }, + "additionalProperties": { + "oneOf": [ + { + "type": "object", + "properties": { + "input_pin": {"$ref": "qmk.definitions.v1#/mcu_pin"}, + "low": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "rest": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "high": {"$ref": "qmk.definitions.v1#/unsigned_int"} + } }, - "driver": { + { + "type": "string", + "enum": ["virtual"] + } + ] + } + } + } + }, + "keycodes": {"$ref": "qmk.definitions.v1#/keycode_decl_array"}, + "layout_aliases": { + "type": "object", + "additionalProperties": {"$ref": "qmk.definitions.v1#/layout_macro"}, + "description": "A mapping of layout aliases to layout definitions.", + "examples": [ + { + "LAYOUT_ansi": "LAYOUT_60_ansi", + "LAYOUT_iso": "LAYOUT_60_iso" + } + ] + }, + "layouts": { + "type": "object", + "propertyNames": {"$ref": "qmk.definitions.v1#/layout_macro"}, + "additionalProperties": { + "type": "object", + "additionalProperties": false, + "properties": { + "filename": {"type": "string"}, + "c_macro": {"type": "boolean"}, + "json_layout": {"type": "boolean"}, + "layout": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": false, + "required": ["x", "y"], + "properties": { + "encoder": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "The index of an encoder this key should be linked to" + }, + "label": { "type": "string", - "enum": [ - "dac_additive", - "dac_basic", - "pwm_software", - "pwm_hardware" - ], - "description": "The driver to use. Must be one of `dac_additive`, `dac_basic`, `pwm_software`, `pwm_hardware`." - }, - "macro_beep": { - "type": "boolean", - "default": false, - "description": "Play a short beep for `\\a` (ASCII `BEL`) characters in Send String macros." - }, - "pins": { - "$ref": "qmk.definitions.v1#/mcu_pin_array", - "description": "The GPIO pin(s) connected to the speaker(s)." - }, - "power_control": { - "type": "object", - "additionalProperties": false, - "properties": { - "on_state": { - "$ref": "qmk.definitions.v1#/bit", - "default": "`1` (on = high)", - "description": "The logical GPIO state required to turn the speaker on." - }, - "pin": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to speaker power circuit." - } - } - }, - "voices": { - "type": "boolean", - "default": false, - "description": "Use multiple audio voices." - } - } - }, - "backlight": { - "type": "object", - "additionalProperties": false, - "properties": { - "driver": { - "type": "string", - "enum": ["custom", "pwm", "software", "timer"], - "default": "pwm", - "description": "The driver to use. Must be one of `custom`, `pwm`, `software`, `timer`." - }, - "default": { - "type": "object", - "additionalProperties": false, - "properties": { - "on": { - "type": "boolean", - "default": true, - "description": "The default backlight enabled state." - }, - "breathing": { - "type": "boolean", - "default": false, - "description": "The default backlight breathing state." - }, - "brightness": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": "`max_brightness`", - "description": "The default brightness level." - } - } - }, - "breathing": { - "type": "boolean", - "default": false, - "description": "Whether backlight breathing is enabled." - }, - "breathing_period": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": "`6` (6 seconds)", - "description": "The length of one backlight breathing cycle in seconds." - }, - "levels": { - "type": "integer", - "minimum": 1, - "maximum": 31, - "default": 3, - "description": "The number of brightness levels (excluding off), from 1 to 31." - }, - "max_brightness": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": 255, - "description": "The maximum PWM value which brightness is scaled to, from 0 to 255." - }, - "pin": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to the backlight circuit." - }, - "pins": { - "$ref": "qmk.definitions.v1#/mcu_pin_array", - "description": "A list of GPIO pins connected to the backlight LEDs (`software` and `timer` drivers only)." - }, - "on_state": { - "$ref": "qmk.definitions.v1#/bit", - "default": "`1` (on = high)", - "description": "The logical GPIO state required to turn the LEDs on." - }, - "as_caps_lock": { - "type": "boolean", - "default": false, - "description": "Use the backlight as a Caps Lock indicator." - } - } - }, - "bluetooth": { - "type": "object", - "additionalProperties": false, - "properties": { - "driver": { - "type": "string", - "enum": ["bluefruit_le", "custom", "rn42"], - "description": "The driver to use. Must be one of `custom`, `bluefruit_le`, `rn42`." - } - } - }, - "bootmagic": { - "type": "object", - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean", - "default": false, - "description": "Enables the Bootmagic feature." - }, - "matrix": { + "pattern": "^[^\\n]*$", + "examples": ["Escape"], + "description": "What to name the key. This is *not* a key assignment as in the keymap, but should usually correspond to the keycode for the first layer of the default keymap." + }, + "matrix": { "type": "array", "minItems": 2, "maxItems": 2, - "items": { - "type": "integer", - "minimum": 0 - }, - "default": [0, 0], - "description": "The matrix position of the key to check during startup. This should generally be set to the (physically) top left key." + "items": {"type": "integer", "minimum": 0}, + "examples": ["`[0, 4]` (row 0, column 4)"], + "description": "The matrix position for the key." + }, + "r": { + "$ref": "qmk.definitions.v1#/signed_decimal", + "description": "The rotation angle in degrees. Currently not implemented." + }, + "rx": { + "$ref": "qmk.definitions.v1#/unsigned_decimal", + "description": "The absolute X position of the rotation axis. Currently not implemented." + }, + "ry": { + "$ref": "qmk.definitions.v1#/unsigned_decimal", + "description": "The absolute Y position of the rotation axis. Currently not implemented." + }, + "h": { + "$ref": "qmk.definitions.v1#/key_unit", + "description": "The height of the key, in key units.", + "default": "`1` (1u)" + }, + "w": { + "$ref": "qmk.definitions.v1#/key_unit", + "description": "The width of the key, in key units.", + "default": "`1` (1u)" + }, + "x": { + "$ref": "qmk.definitions.v1#/key_unit", + "description": "The absolute position of the key in the horizontal axis, in key units." + }, + "y": { + "$ref": "qmk.definitions.v1#/key_unit", + "description": "The absolute position of the key in the vertical axis, in key units." + } } + }, + "description": "A list of key dictionaries comprising the layout. Each key dictionary contains:" } + } }, - "board": { + "description": "A dictionary of layouts supported by the keyboard." + }, + "haptic": { + "type": "object", + "properties": { + "driver": { "type": "string", - "minLength": 2, - "pattern": "^[a-zA-Z_][0-9a-zA-Z_]*$", - "description": "Override the default ChibiOS board name (ARM-based keyboards only).", - "examples": ["BLACKPILL_STM32_F411"] - }, - "bootloader": { + "enum": ["drv2605l", "solenoid"] + } + } + }, + "leader_key": { + "type": "object", + "properties": { + "timing": { + "type": "boolean", + "default": false, + "description": "Reset the `timeout` on each keypress." + }, + "strict_processing": { + "type": "boolean", + "default": false, + "description": "Do not extract the tap keycodes from Layer-Tap and Mod-Tap key events." + }, + "timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`300` (300 ms)", + "description": "The amount of time to complete a leader sequence in milliseconds." + } + } + }, + "matrix_pins": { + "type": "object", + "additionalProperties": false, + "properties": { + "custom": { + "type": "boolean", + "default": false, + "description": "Whether to use a custom matrix scanning implementation." + }, + "custom_lite": { + "type": "boolean", + "default": false, + "description": "Whether to use a \"lite\" custom matrix scanning implementation." + }, + "ghost": { + "type": "boolean", + "default": false, + "description": "Whether the matrix has no anti-ghosting diodes." + }, + "input_pressed_state": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`0` (pressed = low)", + "description": "The logical GPIO state of the input pins when a key is pressed." + }, + "io_delay": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`30` (30 µs)", + "description": "The amount of time to wait between row/col selection and col/row pin reading, in microseconds." + }, + "direct": { + "type": "array", + "items": {"$ref": "qmk.definitions.v1#/mcu_pin_array"}, + "description": "A 2-dimensional list of GPIO pins connected to each keyswitch, forming the \"matrix\" rows and columns.", + "examples": [ + [ + ["A0", "A1", "A2"], + ["B0", "B1", "B2"], + ["C0", "C1", "C2"] + ] + ] + }, + "cols": { + "$ref": "qmk.definitions.v1#/mcu_pin_array", + "description": "A list of GPIO pins connected to the matrix columns.", + "examples": [ + ["A0", "A1", "A2"] + ] + }, + "rows": { + "$ref": "qmk.definitions.v1#/mcu_pin_array", + "description": "A list of GPIO pins connected to the matrix rows.", + "examples": [ + ["B0", "B1", "B2"] + ] + } + } + }, + "mouse_key": { + "type": "object", + "properties": { + "enabled": { + "type": "boolean", + "default": false, + "description": "Enables the Mouse Keys feature." + }, + "delay": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, + "interval": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, + "max_speed": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, + "time_to_max": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, + "wheel_delay": {"$ref": "qmk.definitions.v1#/unsigned_int_8"} + } + }, + "oneshot": { + "type": "object", + "properties": { + "tap_toggle": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "The number of times to tap the key in order to hold it." + }, + "timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "The amount of time before the key is released in milliseconds." + } + } + }, + "led_matrix": { + "type": "object", + "properties": { + "animations": { + "type": "object", + "propertyNames": {"$ref": "qmk.definitions.v1#/snake_case"}, + "additionalProperties": {"type": "boolean"}, + "description": "A dictionary of effects to enable or disable. Effects which are absent default to `false`.", + "examples": [ + { + "alphas_mods": true, + "breathing": true, + "cycle_left_right": false + } + ] + }, + "default": { + "type": "object", + "additionalProperties": false, + "properties": { + "on": { + "type": "boolean", + "default": true, + "description": "The default enabled state." + }, + "animation": { + "type": "string", + "default": "solid", + "description": "The default effect. Must be one of `led_matrix.animations`" + }, + "val": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": "`max_brightness`", + "description": "The default brightness level." + }, + "speed": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 128, + "description": "The default animation speed." + } + } + }, + "driver": { "type": "string", "enum": [ - "apm32-dfu", - "atmel-dfu", - "bootloadhid", - "caterina", - "custom", - "gd32v-dfu", - "halfkay", - "kiibohd", - "lufa-dfu", - "lufa-ms", - "md-boot", - "qmk-dfu", - "qmk-hid", - "rp2040", - "stm32-dfu", - "stm32duino", - "tinyuf2", - "uf2boot", - "unknown", - "usbasploader", - "wb32-dfu" + "custom", + "is31fl3218", + "is31fl3236", + "is31fl3729", + "is31fl3731", + "is31fl3733", + "is31fl3736", + "is31fl3737", + "is31fl3741", + "is31fl3742a", + "is31fl3743a", + "is31fl3745", + "is31fl3746a", + "snled27351" ], - "description": "The bootloader in use on the keyboard. Required if `development_board` is not specified." - }, - "bootloader_instructions": { - "type": "string", - "description": "Instructions for putting the keyboard into a mode that allows for firmware flashing.", - "examples": ["Press the button marked RESET on the back of the PCB"] - }, - "build": { - "type": "object", - "additionalProperties": false, - "properties": { - "debounce_type": { - "type": "string", - "enum": [ - "asym_eager_defer_pk", - "custom", - "sym_defer_g", - "sym_defer_pk", - "sym_defer_pr", - "sym_eager_pk", - "sym_eager_pr" - ], - "description": "The debounce algorithm to use. Must be one of `asym_eager_defer_pk`, `custom`, `sym_defer_g`, `sym_defer_pk`, `sym_defer_pr`, `sym_eager_pk`, `sym_eager_pr`." - }, - "firmware_format": { - "type": "string", - "enum": ["bin", "hex", "uf2"], - "description": "The format of the final output binary. Must be one of `bin`, `hex`, `uf2`." - }, - "lto": { - "type": "boolean", - "default": false, - "description": "Enable Link-Time Optimization." - } - } - }, - "diode_direction": { - "type": "string", - "enum": ["COL2ROW", "ROW2COL"], - "description": "Which way the diodes are \"pointing\". Unused for `matrix_pins.direct`. Must be one of `COL2ROW`, `ROW2COL`." - }, - "debounce": { + "description": "The driver to use. Must be one of `custom`, `is31fl3218`, `is31fl3731`, `is31fl3733`, `is31fl3736`, `is31fl3737`, `is31fl3741`, `is31fl3742a`, `is31fl3743a`, `is31fl3745`, `is31fl3746a`, `snled27351`." + }, + "center_point": { + "type": "array", + "minItems": 2, + "maxItems": 2, + "items": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, + "default": [112, 32], + "description": "The centroid (geometric center) of the LEDs. Used for certain effects." + }, + "max_brightness": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 255, + "description": "The maximum value which brightness is scaled to, from 0 to 255." + }, + "timeout": { "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`5` (5 ms)", - "description": "The debounce time in milliseconds." - }, - "caps_word": { - "type": "object", - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean", - "default": false, - "description": "Enables the Caps Word feature." - }, - "both_shifts_turns_on": { - "type": "boolean", - "default": false, - "description": "Activate Caps Word by pressing both Shift keys." - }, - "double_tap_shift_turns_on": { - "type": "boolean", - "default": false, - "description": "Activate Caps Word by pressing Left Shift twice." - }, - "idle_timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`5000` (5 seconds)", - "description": "The amount of time before Caps Word automatically deactivates in milliseconds." - }, - "invert_on_shift": { - "type": "boolean", - "default": false, - "description": "Invert shift state instead of deactivating Caps Word when Shift is pressed." - } - } - }, - "combo": { - "type": "object", - "properties": { - "count": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "term": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`50` (50 ms)", - "description": "The amount of time to recognize a combo in milliseconds." - } - } - }, - "community_layouts": { + "default": "`0` (no timeout)", + "description": "The LED activity timeout in milliseconds." + }, + "val_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 8, + "description": "The number of brightness adjustment steps." + }, + "speed_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 16, + "description": "The number of speed adjustment steps." + }, + "led_flush_limit": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 16, + "description": "Limits in milliseconds how frequently an animation will update the LEDs." + }, + "led_process_limit": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`led_count / 5`", + "description": "Limits the number of LEDs to process in an animation per task run (increases keyboard responsiveness)." + }, + "react_on_keyup": { + "type": "boolean", + "default": false, + "description": "Animations react to keyup instead of keydown." + }, + "sleep": { + "type": "boolean", + "default": false, + "description": "Turn off the LEDs when the host goes to sleep." + }, + "split_count": { + "type": "array", + "minItems": 2, + "maxItems": 2, + "items": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "description": "For split keyboards, the number of LEDs on each half.", + "examples": [ + [16, 16] + ] + }, + "layout": { "type": "array", "items": { - "$ref": "qmk.definitions.v1#/filename" - }, - "description": "A list of community layouts supported by the keyboard.", - "examples": [["60_ansi", "60_iso"]] - }, - "dip_switch": { - "$ref": "#/definitions/dip_switch_config", - "properties": { - "enabled": { - "type": "boolean", - "default": false, - "description": "Enable the DIP Switches feature." + "type": "object", + "additionalProperties": false, + "properties": { + "matrix": { + "type": "array", + "minItems": 2, + "maxItems": 2, + "items": {"type": "integer", "minimum": 0} }, - "matrix_grid": { - "type": "array", - "minItems": 1, - "items": { - "type": "array", - "minItems": 2, - "maxItems": 2, - "items": { - "type": "integer", - "minimum": 0 - } - }, - "description": "A list of matrix locations in the key matrix.", - "examples": [ - [ - [0, 6], - [1, 6], - [2, 6] - ] - ] - }, - "pins": { - "description": "A list of GPIO pins connected to the MCU." - } - } - }, - "eeprom": { - "properties": { - "driver": { - "type": "string", - "default": "vendor", - "description": "The EEPROM backend to use. Must be one of `custom`, `i2c`, `legacy_stm32_flash`, `spi`, `transient`, `vendor`, `wear_leveling`." - }, - "wear_leveling": { - "type": "object", - "additionalProperties": false, - "properties": { - "driver": { - "type": "string", - "enum": [ - "custom", - "embedded_flash", - "legacy", - "rp2040_flash", - "spi_flash" - ], - "description": "The driver to use. Must be one of `embedded_flash`, `legacy`, `rp2040_flash`, `spi_flash`, `custom`." - }, - "backing_size": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "description": "Number of bytes used by the wear-leveling algorithm for its underlying storage, and needs to be a multiple of the logical size." - }, - "logical_size": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "description": "Number of bytes “exposed” to the rest of QMK and denotes the size of the usable EEPROM." - } - } - } - } - }, - "encoder": { - "$ref": "#/definitions/encoder_config", - "properties": { - "enabled": { - "type": "boolean" - } - } - }, - "features": { - "$ref": "qmk.definitions.v1#/boolean_array", - "propertyNames": { - "$ref": "qmk.definitions.v1#/snake_case" + "x": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "y": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "flags": {"$ref": "qmk.definitions.v1#/unsigned_int_8"} + } }, - "not": { - "required": ["lto"] - }, - "description": "A dictionary of features to enable or disable.", + "description": "List of LED configuration dictionaries. Each dictionary contains:" + } + } + }, + "rgb_matrix": { + "type": "object", + "properties": { + "animations": { + "type": "object", + "propertyNames": {"$ref": "qmk.definitions.v1#/snake_case"}, + "additionalProperties": {"type": "boolean"}, + "description": "A dictionary of effects to enable or disable. Effects which are absent default to `false`.", "examples": [ - { - "rgb_matrix": true, - "rgblight": false - } + { + "alphas_mods": true, + "breathing": true, + "cycle_left_right": false + } ] - }, - "indicators": { + }, + "default": { "type": "object", + "additionalProperties": false, "properties": { - "caps_lock": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to the Caps Lock LED." - }, - "num_lock": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to the Num Lock LED." - }, - "scroll_lock": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to the Scroll Lock LED." - }, - "compose": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to the Compose LED." - }, - "kana": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to the Kana LED." - }, - "on_state": { - "$ref": "qmk.definitions.v1#/bit", - "default": "`1` (on = high)", - "description": "The logical GPIO state required to turn the LEDs on." - } + "on": { + "type": "boolean", + "default": true, + "description": "The default enabled state." + }, + "animation": { + "type": "string", + "default": "solid_color", + "description": "The default effect. Must be one of `rgb_matrix.animations`" + }, + "hue": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 0, + "description": "The default hue value." + }, + "sat": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 255, + "description": "The default saturation value." + }, + "val": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": "`max_brightness`", + "description": "The default brightness level." + }, + "speed": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 128, + "description": "The default animation speed." + } } - }, - "joystick": { - "type": "object", - "properties": { - "enabled": { - "type": "boolean" - }, - "driver": { - "type": "string" - }, - "button_count": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "axis_resolution": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "axes": { - "type": "object", - "propertyNames": { - "enum": ["x", "y", "z", "rx", "ry", "rz"] - }, - "additionalProperties": { - "oneOf": [ - { - "type": "object", - "properties": { - "input_pin": { - "$ref": "qmk.definitions.v1#/mcu_pin" - }, - "low": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "rest": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "high": { - "$ref": "qmk.definitions.v1#/unsigned_int" - } - } - }, - { - "type": "string", - "enum": ["virtual"] - } - ] - } - } - } - }, - "keycodes": { - "$ref": "qmk.definitions.v1#/keycode_decl_array" - }, - "layout_aliases": { - "type": "object", - "additionalProperties": { - "$ref": "qmk.definitions.v1#/layout_macro" - }, - "description": "A mapping of layout aliases to layout definitions.", + }, + "driver": { + "type": "string", + "enum": [ + "aw20216s", + "custom", + "is31fl3218", + "is31fl3236", + "is31fl3729", + "is31fl3731", + "is31fl3733", + "is31fl3736", + "is31fl3737", + "is31fl3741", + "is31fl3742a", + "is31fl3743a", + "is31fl3745", + "is31fl3746a", + "snled27351", + "ws2812" + ], + "description": "The driver to use. Must be one of `aw20216s`, `custom`, `is31fl3218`, `is31fl3236`, `is31fl3729`, `is31fl3731`, `is31fl3733`, `is31fl3736`, `is31fl3737`, `is31fl3741`, `is31fl3742a`, `is31fl3743a`, `is31fl3745`, `is31fl3746a`, `snled27351`, `ws2812`." + }, + "center_point": { + "type": "array", + "minItems": 2, + "maxItems": 2, + "items": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, + "default": [112, 32], + "description": "The centroid (geometric center) of the LEDs. Used for certain effects." + }, + "max_brightness": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 255, + "description": "The maximum value which the HSV \"V\" component is scaled to, from 0 to 255." + }, + "timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`0` (no timeout)", + "description": "The LED activity timeout in milliseconds." + }, + "hue_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 8, + "description": "The number of hue adjustment steps." + }, + "sat_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 16, + "description": "The number of saturation adjustment steps." + }, + "val_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 16, + "description": "The number of brightness adjustment steps." + }, + "speed_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 16, + "description": "The number of speed adjustment steps." + }, + "led_flush_limit": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 16, + "description": "Limits in milliseconds how frequently an animation will update the LEDs." + }, + "led_process_limit": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`led_count / 5`", + "description": "Limits the number of LEDs to process in an animation per task run (increases keyboard responsiveness)." + }, + "react_on_keyup": { + "type": "boolean", + "default": false, + "description": "Animations react to keyup instead of keydown." + }, + "sleep": { + "type": "boolean", + "default": false, + "description": "Turn off the LEDs when the host goes to sleep." + }, + "split_count": { + "type": "array", + "minItems": 2, + "maxItems": 2, + "items": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "description": "For split keyboards, the number of LEDs on each half.", "examples": [ - { - "LAYOUT_ansi": "LAYOUT_60_ansi", - "LAYOUT_iso": "LAYOUT_60_iso" - } + [16, 16] ] - }, - "layouts": { - "type": "object", - "propertyNames": { - "$ref": "qmk.definitions.v1#/layout_macro" + }, + "layout": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": false, + "properties": { + "matrix": { + "type": "array", + "minItems": 2, + "maxItems": 2, + "items": {"type": "integer", "minimum": 0} + }, + "x": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "y": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "flags": {"$ref": "qmk.definitions.v1#/unsigned_int_8"} + } }, - "additionalProperties": { + "description": "List of LED configuration dictionaries. Each dictionary contains:" + } + } + }, + "rgblight": { + "type": "object", + "additionalProperties": false, + "properties": { + "animations": { + "type": "object", + "propertyNames": {"$ref": "qmk.definitions.v1#/snake_case"}, + "additionalProperties": {"type": "boolean"}, + "description": "A dictionary of effects to enable or disable. Effects which are absent default to `false`.", + "examples": [ + {"breathing": true, "rainbow_mood": true, "snake": false} + ] + }, + "brightness_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 17, + "description": "The number of brightness adjustment steps." + }, + "default": { + "type": "object", + "additionalProperties": false, + "properties": { + "on": { + "type": "boolean", + "default": true, + "description": "The default enabled state." + }, + "animation": { + "type": "string", + "default": "static_light", + "description": "The default effect. Must be one of `rgblight.animations`" + }, + "hue": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 0, + "description": "The default hue value." + }, + "sat": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 255, + "description": "The default saturation value." + }, + "val": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": "`max_brightness`", + "description": "The default brightness level." + }, + "speed": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 0, + "description": "The default animation speed." + } + } + }, + "driver": { + "type": "string", + "enum": ["apa102", "custom", "ws2812"], + "default": "ws2812", + "description": "The driver to use. Must be one of `apa102`, `custom`, `ws2812`." + }, + "hue_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 8, + "description": "The number of hue adjustment steps." + }, + "layers": { + "type": "object", + "additionalProperties": false, + "properties": { + "blink": { + "type": "boolean", + "default": false, + "description": "Enable layer blinking API." + }, + "enabled": { + "type": "boolean", + "default": false, + "description": "Enable RGB Lighting Layers." + }, + "max": { + "type": "integer", + "minimum": 1, + "maximum": 32, + "default": 8, + "description": "The maximum layer count, from 1 to 32." + }, + "override_rgb": {"type": "boolean"} + } + }, + "led_count": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "The number of LEDs in the chain." + }, + "led_map": { + "type": "array", + "minItems": 2, + "items": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "description": "Remap LED indices.", + "examples": [ + [4, 3, 2, 1, 0] + ] + }, + "max_brightness": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": 255, + "description": "The maximum value which the HSV \"V\" component is scaled to, from 0 to 255." + }, + "pin": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "$comment": "Deprecated: use ws2812.pin instead" + }, + "rgbw": { + "type": "boolean", + "$comment": "Deprecated: use ws2812.rgbw instead" + }, + "saturation_steps": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": 17, + "description": "The number of saturation adjustment steps." + }, + "sleep": { + "type": "boolean", + "default": false, + "description": "Turn off the LEDs when the host goes to sleep." + }, + "split": { + "type": "boolean", + "default": false, + "description": "Enable synchronization between split halves." + }, + "split_count": { + "type": "array", + "minItems": 2, + "maxItems": 2, + "items": {"$ref": "qmk.definitions.v1#/unsigned_int"}, + "description": "When `rgblight.split` is enabled, the number of LEDs on each half.", + "examples": [ + [10, 10] + ] + } + } + }, + "secure": { + "type": "object", + "additionalProperties": false, + "properties": { + "enabled": { + "type": "boolean", + "default": false, + "description": "Enable the Secure feature." + }, + "unlock_timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`5000` (5 seconds)", + "description": "Timeout for the user to perform the unlock sequence. Set to `0` to disable." + }, + "idle_timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`60000` (1 minute)", + "description": "Timeout while unlocked before returning to the locked state. Set to `0` to disable." + }, + "unlock_sequence": { + "type": "array", + "minItems": 1, + "maxItems": 5, + "items": { + "type": "array", + "minItems": 2, + "maxItems": 2, + "items": {"type": "integer", "minimum": 0} + }, + "description": "A list of up to five matrix locations comprising the \"unlock sequence\".", + "examples": [ + [ + [0, 0], + [0, 1], + [4, 3] + ] + ] + } + } + }, + "stenography": { + "type": "object", + "additionalProperties": false, + "properties": { + "enabled": { + "type": "boolean", + "default": false, + "description": "Enable the Stenography feature." + }, + "protocol": { + "type": "string", + "enum": ["all", "geminipr", "txbolt"], + "default": "all", + "description": "The Steno protocol to use. Must be one of `all`, `geminipr`, `txbolt`." + } + } + }, + "ps2": { + "type": "object", + "additionalProperties": false, + "properties": { + "enabled": { + "type": "boolean", + "default": false, + "description": "Enable the PS/2 feature." + }, + "mouse_enabled": { + "type": "boolean", + "default": false, + "description": "Enable the PS/2 mouse handling." + }, + "clock_pin": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to `CLK` on the PS/2 device." + }, + "data_pin": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to `DATA` on the PS/2 device." + }, + "driver": { + "type": "string", + "enum": ["busywait", "interrupt", "usart", "vendor"], + "default": "busywait", + "description": "The PS/2 driver to use. Must be one of `busywait`, `interrupt`, `usart`, `vendor`." + } + } + }, + "split": { + "type": "object", + "additionalProperties": false, + "properties": { + "enabled": { + "type": "boolean", + "default": false, + "description": "Enable the Split Keyboard feature." + }, + "bootmagic": { + "type": "object", + "additionalProperties": false, + "properties": { + "matrix": { + "type": "array", + "minItems": 2, + "maxItems": 2, + "items": {"type": "integer", "minimum": 0} + } + } + }, + "matrix_pins": { + "type": "object", + "additionalProperties": false, + "properties": { + "right": { "type": "object", "additionalProperties": false, "properties": { - "filename": { - "type": "string" - }, - "c_macro": { - "type": "boolean" - }, - "json_layout": { - "type": "boolean" - }, - "layout": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "required": ["x", "y"], - "properties": { - "encoder": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "description": "The index of an encoder this key should be linked to" - }, - "label": { - "type": "string", - "pattern": "^[^\\n]*$", - "examples": ["Escape"], - "description": "What to name the key. This is *not* a key assignment as in the keymap, but should usually correspond to the keycode for the first layer of the default keymap." - }, - "matrix": { - "type": "array", - "minItems": 2, - "maxItems": 2, - "items": { - "type": "integer", - "minimum": 0 - }, - "examples": ["`[0, 4]` (row 0, column 4)"], - "description": "The matrix position for the key." - }, - "r": { - "$ref": "qmk.definitions.v1#/signed_decimal", - "description": "The rotation angle in degrees. Currently not implemented." - }, - "rx": { - "$ref": "qmk.definitions.v1#/unsigned_decimal", - "description": "The absolute X position of the rotation axis. Currently not implemented." - }, - "ry": { - "$ref": "qmk.definitions.v1#/unsigned_decimal", - "description": "The absolute Y position of the rotation axis. Currently not implemented." - }, - "h": { - "$ref": "qmk.definitions.v1#/key_unit", - "description": "The height of the key, in key units.", - "default": "`1` (1u)" - }, - "w": { - "$ref": "qmk.definitions.v1#/key_unit", - "description": "The width of the key, in key units.", - "default": "`1` (1u)" - }, - "x": { - "$ref": "qmk.definitions.v1#/key_unit", - "description": "The absolute position of the key in the horizontal axis, in key units." - }, - "y": { - "$ref": "qmk.definitions.v1#/key_unit", - "description": "The absolute position of the key in the vertical axis, in key units." - } - } - }, - "description": "A list of key dictionaries comprising the layout. Each key dictionary contains:" - } - } - }, - "description": "A dictionary of layouts supported by the keyboard." - }, - "haptic": { - "type": "object", - "properties": { - "driver": { - "type": "string", - "enum": ["drv2605l", "solenoid"] + "direct": { + "type": "array", + "items": {"$ref": "qmk.definitions.v1#/mcu_pin_array"} + }, + "cols": {"$ref": "qmk.definitions.v1#/mcu_pin_array"}, + "rows": {"$ref": "qmk.definitions.v1#/mcu_pin_array"}, + "unused": {"$ref": "qmk.definitions.v1#/mcu_pin_array"} } + } } - }, - "leader_key": { - "type": "object", - "properties": { - "timing": { - "type": "boolean", - "default": false, - "description": "Reset the `timeout` on each keypress." - }, - "strict_processing": { - "type": "boolean", - "default": false, - "description": "Do not extract the tap keycodes from Layer-Tap and Mod-Tap key events." - }, - "timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`300` (300 ms)", - "description": "The amount of time to complete a leader sequence in milliseconds." - } - } - }, - "matrix_pins": { + }, + "dip_switch": { "type": "object", "additionalProperties": false, "properties": { - "custom": { - "type": "boolean", - "default": false, - "description": "Whether to use a custom matrix scanning implementation." - }, - "custom_lite": { - "type": "boolean", - "default": false, - "description": "Whether to use a \"lite\" custom matrix scanning implementation." - }, - "ghost": { - "type": "boolean", - "default": false, - "description": "Whether the matrix has no anti-ghosting diodes." - }, - "input_pressed_state": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`0` (pressed = low)", - "description": "The logical GPIO state of the input pins when a key is pressed." - }, - "io_delay": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`30` (30 µs)", - "description": "The amount of time to wait between row/col selection and col/row pin reading, in microseconds." - }, - "direct": { - "type": "array", - "items": { - "$ref": "qmk.definitions.v1#/mcu_pin_array" - }, - "description": "A 2-dimensional list of GPIO pins connected to each keyswitch, forming the \"matrix\" rows and columns.", - "examples": [ - [ - ["A0", "A1", "A2"], - ["B0", "B1", "B2"], - ["C0", "C1", "C2"] - ] - ] - }, - "cols": { - "$ref": "qmk.definitions.v1#/mcu_pin_array", - "description": "A list of GPIO pins connected to the matrix columns.", - "examples": [["A0", "A1", "A2"]] - }, - "rows": { - "$ref": "qmk.definitions.v1#/mcu_pin_array", - "description": "A list of GPIO pins connected to the matrix rows.", - "examples": [["B0", "B1", "B2"]] - } + "right": {"$ref": "#/definitions/dip_switch_config"} } - }, - "mouse_key": { - "type": "object", - "properties": { - "enabled": { - "type": "boolean", - "default": false, - "description": "Enables the Mouse Keys feature." - }, - "delay": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" - }, - "interval": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" - }, - "max_speed": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" - }, - "time_to_max": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" - }, - "wheel_delay": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" - } - } - }, - "oneshot": { - "type": "object", - "properties": { - "tap_toggle": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "description": "The number of times to tap the key in order to hold it." - }, - "timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "description": "The amount of time before the key is released in milliseconds." - } - } - }, - "led_matrix": { - "type": "object", - "properties": { - "animations": { - "type": "object", - "propertyNames": { - "$ref": "qmk.definitions.v1#/snake_case" - }, - "additionalProperties": { - "type": "boolean" - }, - "description": "A dictionary of effects to enable or disable. Effects which are absent default to `false`.", - "examples": [ - { - "alphas_mods": true, - "breathing": true, - "cycle_left_right": false - } - ] - }, - "default": { - "type": "object", - "additionalProperties": false, - "properties": { - "on": { - "type": "boolean", - "default": true, - "description": "The default enabled state." - }, - "animation": { - "type": "string", - "default": "solid", - "description": "The default effect. Must be one of `led_matrix.animations`" - }, - "val": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": "`max_brightness`", - "description": "The default brightness level." - }, - "speed": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": 128, - "description": "The default animation speed." - } - } - }, - "driver": { - "type": "string", - "enum": [ - "custom", - "is31fl3218", - "is31fl3236", - "is31fl3729", - "is31fl3731", - "is31fl3733", - "is31fl3736", - "is31fl3737", - "is31fl3741", - "is31fl3742a", - "is31fl3743a", - "is31fl3745", - "is31fl3746a", - "snled27351" - ], - "description": "The driver to use. Must be one of `custom`, `is31fl3218`, `is31fl3731`, `is31fl3733`, `is31fl3736`, `is31fl3737`, `is31fl3741`, `is31fl3742a`, `is31fl3743a`, `is31fl3745`, `is31fl3746a`, `snled27351`." - }, - "center_point": { - "type": "array", - "minItems": 2, - "maxItems": 2, - "items": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" - }, - "default": [112, 32], - "description": "The centroid (geometric center) of the LEDs. Used for certain effects." - }, - "max_brightness": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": 255, - "description": "The maximum value which brightness is scaled to, from 0 to 255." - }, - "timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`0` (no timeout)", - "description": "The LED activity timeout in milliseconds." - }, - "val_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 8, - "description": "The number of brightness adjustment steps." - }, - "speed_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 16, - "description": "The number of speed adjustment steps." - }, - "led_flush_limit": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 16, - "description": "Limits in milliseconds how frequently an animation will update the LEDs." - }, - "led_process_limit": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`led_count / 5`", - "description": "Limits the number of LEDs to process in an animation per task run (increases keyboard responsiveness)." - }, - "react_on_keyup": { - "type": "boolean", - "default": false, - "description": "Animations react to keyup instead of keydown." - }, - "sleep": { - "type": "boolean", - "default": false, - "description": "Turn off the LEDs when the host goes to sleep." - }, - "split_count": { - "type": "array", - "minItems": 2, - "maxItems": 2, - "items": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "description": "For split keyboards, the number of LEDs on each half.", - "examples": [[16, 16]] - }, - "layout": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "matrix": { - "type": "array", - "minItems": 2, - "maxItems": 2, - "items": { - "type": "integer", - "minimum": 0 - } - }, - "x": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "y": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "flags": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" - } - } - }, - "description": "List of LED configuration dictionaries. Each dictionary contains:" - } - } - }, - "rgb_matrix": { - "type": "object", - "properties": { - "animations": { - "type": "object", - "propertyNames": { - "$ref": "qmk.definitions.v1#/snake_case" - }, - "additionalProperties": { - "type": "boolean" - }, - "description": "A dictionary of effects to enable or disable. Effects which are absent default to `false`.", - "examples": [ - { - "alphas_mods": true, - "breathing": true, - "cycle_left_right": false - } - ] - }, - "default": { - "type": "object", - "additionalProperties": false, - "properties": { - "on": { - "type": "boolean", - "default": true, - "description": "The default enabled state." - }, - "animation": { - "type": "string", - "default": "solid_color", - "description": "The default effect. Must be one of `rgb_matrix.animations`" - }, - "hue": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": 0, - "description": "The default hue value." - }, - "sat": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": 255, - "description": "The default saturation value." - }, - "val": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": "`max_brightness`", - "description": "The default brightness level." - }, - "speed": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": 128, - "description": "The default animation speed." - } - } - }, - "driver": { - "type": "string", - "enum": [ - "aw20216s", - "custom", - "is31fl3218", - "is31fl3236", - "is31fl3729", - "is31fl3731", - "is31fl3733", - "is31fl3736", - "is31fl3737", - "is31fl3741", - "is31fl3742a", - "is31fl3743a", - "is31fl3745", - "is31fl3746a", - "snled27351", - "ws2812" - ], - "description": "The driver to use. Must be one of `aw20216s`, `custom`, `is31fl3218`, `is31fl3236`, `is31fl3729`, `is31fl3731`, `is31fl3733`, `is31fl3736`, `is31fl3737`, `is31fl3741`, `is31fl3742a`, `is31fl3743a`, `is31fl3745`, `is31fl3746a`, `snled27351`, `ws2812`." - }, - "center_point": { - "type": "array", - "minItems": 2, - "maxItems": 2, - "items": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" - }, - "default": [112, 32], - "description": "The centroid (geometric center) of the LEDs. Used for certain effects." - }, - "max_brightness": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": 255, - "description": "The maximum value which the HSV \"V\" component is scaled to, from 0 to 255." - }, - "timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`0` (no timeout)", - "description": "The LED activity timeout in milliseconds." - }, - "hue_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 8, - "description": "The number of hue adjustment steps." - }, - "sat_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 16, - "description": "The number of saturation adjustment steps." - }, - "val_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 16, - "description": "The number of brightness adjustment steps." - }, - "speed_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 16, - "description": "The number of speed adjustment steps." - }, - "led_flush_limit": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 16, - "description": "Limits in milliseconds how frequently an animation will update the LEDs." - }, - "led_process_limit": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`led_count / 5`", - "description": "Limits the number of LEDs to process in an animation per task run (increases keyboard responsiveness)." - }, - "react_on_keyup": { - "type": "boolean", - "default": false, - "description": "Animations react to keyup instead of keydown." - }, - "sleep": { - "type": "boolean", - "default": false, - "description": "Turn off the LEDs when the host goes to sleep." - }, - "split_count": { - "type": "array", - "minItems": 2, - "maxItems": 2, - "items": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "description": "For split keyboards, the number of LEDs on each half.", - "examples": [[16, 16]] - }, - "layout": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": false, - "properties": { - "matrix": { - "type": "array", - "minItems": 2, - "maxItems": 2, - "items": { - "type": "integer", - "minimum": 0 - } - }, - "x": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "y": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "flags": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" - } - } - }, - "description": "List of LED configuration dictionaries. Each dictionary contains:" - } - } - }, - "rgblight": { + }, + "encoder": { "type": "object", "additionalProperties": false, "properties": { - "animations": { - "type": "object", - "propertyNames": { - "$ref": "qmk.definitions.v1#/snake_case" - }, - "additionalProperties": { - "type": "boolean" - }, - "description": "A dictionary of effects to enable or disable. Effects which are absent default to `false`.", - "examples": [ - { - "breathing": true, - "rainbow_mood": true, - "snake": false - } - ] - }, - "brightness_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 17, - "description": "The number of brightness adjustment steps." - }, - "default": { - "type": "object", - "additionalProperties": false, - "properties": { - "on": { - "type": "boolean", - "default": true, - "description": "The default enabled state." - }, - "animation": { - "type": "string", - "default": "static_light", - "description": "The default effect. Must be one of `rgblight.animations`" - }, - "hue": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": 0, - "description": "The default hue value." - }, - "sat": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": 255, - "description": "The default saturation value." - }, - "val": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": "`max_brightness`", - "description": "The default brightness level." - }, - "speed": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": 0, - "description": "The default animation speed." - } - } - }, - "driver": { - "type": "string", - "enum": ["apa102", "custom", "ws2812"], - "default": "ws2812", - "description": "The driver to use. Must be one of `apa102`, `custom`, `ws2812`." - }, - "hue_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 8, - "description": "The number of hue adjustment steps." - }, - "layers": { - "type": "object", - "additionalProperties": false, - "properties": { - "blink": { - "type": "boolean", - "default": false, - "description": "Enable layer blinking API." - }, - "enabled": { - "type": "boolean", - "default": false, - "description": "Enable RGB Lighting Layers." - }, - "max": { - "type": "integer", - "minimum": 1, - "maximum": 32, - "default": 8, - "description": "The maximum layer count, from 1 to 32." - }, - "override_rgb": { - "type": "boolean" - } - } - }, - "led_count": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "description": "The number of LEDs in the chain." - }, - "led_map": { - "type": "array", - "minItems": 2, - "items": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "description": "Remap LED indices.", - "examples": [[4, 3, 2, 1, 0]] - }, - "max_brightness": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": 255, - "description": "The maximum value which the HSV \"V\" component is scaled to, from 0 to 255." - }, - "pin": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "$comment": "Deprecated: use ws2812.pin instead" - }, - "rgbw": { - "type": "boolean", - "$comment": "Deprecated: use ws2812.rgbw instead" - }, - "saturation_steps": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 17, - "description": "The number of saturation adjustment steps." - }, - "sleep": { - "type": "boolean", - "default": false, - "description": "Turn off the LEDs when the host goes to sleep." - }, - "split": { - "type": "boolean", - "default": false, - "description": "Enable synchronization between split halves." - }, - "split_count": { - "type": "array", - "minItems": 2, - "maxItems": 2, - "items": { - "$ref": "qmk.definitions.v1#/unsigned_int" - }, - "description": "When `rgblight.split` is enabled, the number of LEDs on each half.", - "examples": [[10, 10]] - } + "right": {"$ref": "#/definitions/encoder_config"} } - }, - "secure": { + }, + "handedness": { "type": "object", "additionalProperties": false, "properties": { - "enabled": { - "type": "boolean", - "default": false, - "description": "Enable the Secure feature." - }, - "unlock_timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`5000` (5 seconds)", - "description": "Timeout for the user to perform the unlock sequence. Set to `0` to disable." - }, - "idle_timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`60000` (1 minute)", - "description": "Timeout while unlocked before returning to the locked state. Set to `0` to disable." - }, - "unlock_sequence": { - "type": "array", - "minItems": 1, - "maxItems": 5, - "items": { - "type": "array", - "minItems": 2, - "maxItems": 2, - "items": { - "type": "integer", - "minimum": 0 - } - }, - "description": "A list of up to five matrix locations comprising the \"unlock sequence\".", - "examples": [ - [ - [0, 0], - [0, 1], - [4, 3] - ] - ] - } + "pin": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to determine handedness." + }, + "matrix_grid": { + "$ref": "qmk.definitions.v1#/mcu_pin_array", + "minItems": 2, + "maxItems": 2, + "description": "The GPIO pins of the matrix position which determines the handedness.", + "examples": [ + ["A1", "B5"] + ] + } } - }, - "stenography": { + }, + "soft_serial_pin": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "$comment": "Deprecated: use split.serial.pin instead" + }, + "soft_serial_speed": { + "type": "integer", + "minimum": 0, + "maximum": 5, + "default": 1, + "description": "The protocol speed, from `0` to `5` (`serial` transport protocol only)." + }, + "serial": { "type": "object", "additionalProperties": false, "properties": { - "enabled": { - "type": "boolean", - "default": false, - "description": "Enable the Stenography feature." - }, - "protocol": { - "type": "string", - "enum": ["all", "geminipr", "txbolt"], - "default": "all", - "description": "The Steno protocol to use. Must be one of `all`, `geminipr`, `txbolt`." - } + "driver": { + "type": "string", + "enum": ["bitbang", "usart", "vendor"], + "default": "bitbang", + "description": "The driver to use. Must be one of `bitbang`, `usart`, `vendor`." + }, + "pin": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin to use for transmit and receive." + } } - }, - "ps2": { + }, + "transport": { "type": "object", "additionalProperties": false, "properties": { - "enabled": { + "protocol": { + "type": "string", + "enum": ["custom", "i2c", "serial"], + "description": "The split transport protocol to use. Must be one of `custom`, `i2c`, `serial`." + }, + "sync": { + "type": "object", + "additionalProperties": false, + "properties": { + "activity": { "type": "boolean", "default": false, - "description": "Enable the PS/2 feature." - }, - "mouse_enabled": { + "description": "Mirror the activity timestamps to the secondary half." + }, + "detected_os": { "type": "boolean", "default": false, - "description": "Enable the PS/2 mouse handling." - }, - "clock_pin": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to `CLK` on the PS/2 device." - }, - "data_pin": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to `DATA` on the PS/2 device." - }, - "driver": { - "type": "string", - "enum": ["busywait", "interrupt", "usart", "vendor"], - "default": "busywait", - "description": "The PS/2 driver to use. Must be one of `busywait`, `interrupt`, `usart`, `vendor`." + "description": "Mirror the [detected OS](features/os_detection) to the secondary half." + }, + "haptic": { + "type": "boolean", + "default": false, + "description": "Mirror the haptic state and process haptic feedback to the secondary half." + }, + "layer_state": { + "type": "boolean", + "default": false, + "description": "Mirror the layer state to the secondary half." + }, + "indicators": { + "type": "boolean", + "default": false, + "description": "Mirror the indicator state to the secondary half." + }, + "matrix_state": { + "type": "boolean", + "default": false, + "description": "Mirror the main/primary half's matrix state to the secondary half." + }, + "modifiers": { + "type": "boolean", + "default": false, + "description": "Mirror the modifier state to the secondary half." + }, + "oled": { + "type": "boolean", + "default": false, + "description": "Mirror the OLED on/off status to the secondary half." + }, + "st7565": { + "type": "boolean", + "default": false, + "description": "Mirror the ST7565 on/off status to the secondary half." + }, + "wpm": { + "type": "boolean", + "default": false, + "description": "Mirror the current WPM value to the secondary half." + } } + }, + "watchdog": { + "type": "boolean", + "default": false, + "description": "Reboot the secondary half if it loses connection." + }, + "watchdog_timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "description": "The amount of time to wait for communication from the primary half in milliseconds." + }, + "sync_matrix_state": { + "type": "boolean", + "$comment": "Deprecated: use sync.matrix_state instead" + }, + "sync_modifiers": { + "type": "boolean", + "$comment": "Deprecated: use sync.modifiers instead" + } } - }, - "split": { + }, + "usb_detect": { "type": "object", "additionalProperties": false, "properties": { - "enabled": { - "type": "boolean", - "default": false, - "description": "Enable the Split Keyboard feature." - }, - "bootmagic": { - "type": "object", - "additionalProperties": false, - "properties": { - "matrix": { - "type": "array", - "minItems": 2, - "maxItems": 2, - "items": { - "type": "integer", - "minimum": 0 - } - } - } - }, - "matrix_pins": { - "type": "object", - "additionalProperties": false, - "properties": { - "right": { - "type": "object", - "additionalProperties": false, - "properties": { - "direct": { - "type": "array", - "items": { - "$ref": "qmk.definitions.v1#/mcu_pin_array" - } - }, - "cols": { - "$ref": "qmk.definitions.v1#/mcu_pin_array" - }, - "rows": { - "$ref": "qmk.definitions.v1#/mcu_pin_array" - }, - "unused": { - "$ref": "qmk.definitions.v1#/mcu_pin_array" - } - } - } - } - }, - "dip_switch": { - "type": "object", - "additionalProperties": false, - "properties": { - "right": { - "$ref": "#/definitions/dip_switch_config" - } - } - }, - "encoder": { - "type": "object", - "additionalProperties": false, - "properties": { - "right": { - "$ref": "#/definitions/encoder_config" - } - } - }, - "handedness": { - "type": "object", - "additionalProperties": false, - "properties": { - "pin": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to determine handedness." - }, - "matrix_grid": { - "$ref": "qmk.definitions.v1#/mcu_pin_array", - "minItems": 2, - "maxItems": 2, - "description": "The GPIO pins of the matrix position which determines the handedness.", - "examples": [["A1", "B5"]] - } - } - }, - "soft_serial_pin": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "$comment": "Deprecated: use split.serial.pin instead" - }, - "soft_serial_speed": { - "type": "integer", - "minimum": 0, - "maximum": 5, - "default": 1, - "description": "The protocol speed, from `0` to `5` (`serial` transport protocol only)." - }, - "serial": { - "type": "object", - "additionalProperties": false, - "properties": { - "driver": { - "type": "string", - "enum": ["bitbang", "usart", "vendor"], - "default": "bitbang", - "description": "The driver to use. Must be one of `bitbang`, `usart`, `vendor`." - }, - "pin": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin to use for transmit and receive." - } - } - }, - "transport": { - "type": "object", - "additionalProperties": false, - "properties": { - "protocol": { - "type": "string", - "enum": ["custom", "i2c", "serial"], - "description": "The split transport protocol to use. Must be one of `custom`, `i2c`, `serial`." - }, - "sync": { - "type": "object", - "additionalProperties": false, - "properties": { - "activity": { - "type": "boolean", - "default": false, - "description": "Mirror the activity timestamps to the secondary half." - }, - "detected_os": { - "type": "boolean", - "default": false, - "description": "Mirror the [detected OS](features/os_detection) to the secondary half." - }, - "haptic": { - "type": "boolean", - "default": false, - "description": "Mirror the haptic state and process haptic feedback to the secondary half." - }, - "layer_state": { - "type": "boolean", - "default": false, - "description": "Mirror the layer state to the secondary half." - }, - "indicators": { - "type": "boolean", - "default": false, - "description": "Mirror the indicator state to the secondary half." - }, - "matrix_state": { - "type": "boolean", - "default": false, - "description": "Mirror the main/primary half's matrix state to the secondary half." - }, - "modifiers": { - "type": "boolean", - "default": false, - "description": "Mirror the modifier state to the secondary half." - }, - "oled": { - "type": "boolean", - "default": false, - "description": "Mirror the OLED on/off status to the secondary half." - }, - "st7565": { - "type": "boolean", - "default": false, - "description": "Mirror the ST7565 on/off status to the secondary half." - }, - "wpm": { - "type": "boolean", - "default": false, - "description": "Mirror the current WPM value to the secondary half." - } - } - }, - "watchdog": { - "type": "boolean", - "default": false, - "description": "Reboot the secondary half if it loses connection." - }, - "watchdog_timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "description": "The amount of time to wait for communication from the primary half in milliseconds." - }, - "sync_matrix_state": { - "type": "boolean", - "$comment": "Deprecated: use sync.matrix_state instead" - }, - "sync_modifiers": { - "type": "boolean", - "$comment": "Deprecated: use sync.modifiers instead" - } - } - }, - "usb_detect": { - "type": "object", - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean", - "description": "Detect USB connection when determining split half roles." - }, - "polling_interval": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`10` (10 ms)", - "description": "The polling frequency in milliseconds." - }, - "timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`2000` (2 seconds)", - "description": "The amount of time to wait for a USB connection in milliseconds." - } - } - }, - "main": { - "type": "string", - "enum": ["eeprom", "left", "matrix_grid", "pin", "right"], - "$comment": "Deprecated: use config.h options for now" - }, - "matrix_grid": { - "type": "array", - "items": { - "$ref": "qmk.definitions.v1#/mcu_pin" - }, - "$comment": "Deprecated: use split.handedness.matrix_grid instead" - } + "enabled": { + "type": "boolean", + "description": "Detect USB connection when determining split half roles." + }, + "polling_interval": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`10` (10 ms)", + "description": "The polling frequency in milliseconds." + }, + "timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`2000` (2 seconds)", + "description": "The amount of time to wait for a USB connection in milliseconds." + } } - }, - "tags": { + }, + "main": { + "type": "string", + "enum": ["eeprom", "left", "matrix_grid", "pin", "right"], + "$comment": "Deprecated: use config.h options for now" + }, + "matrix_grid": { "type": "array", - "items": { - "type": "string" - }, - "description": "A list of tags describing the keyboard.", - "examples": [["ortho", "split", "rgb"]] - }, - "tapping": { - "type": "object", - "properties": { - "force_hold": { - "type": "boolean" - }, - "force_hold_per_key": { - "type": "boolean" - }, - "ignore_mod_tap_interrupt": { - "type": "boolean" - }, - "hold_on_other_key_press": { - "type": "boolean", - "default": false - }, - "hold_on_other_key_press_per_key": { - "type": "boolean", - "default": false - }, - "permissive_hold": { - "type": "boolean", - "default": false - }, - "permissive_hold_per_key": { - "type": "boolean", - "default": false - }, - "retro": { - "type": "boolean", - "default": false - }, - "retro_per_key": { - "type": "boolean", - "default": false - }, - "term": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`200` (200 ms)" - }, - "term_per_key": { - "type": "boolean", - "default": false - }, - "toggle": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": 5 - } - } - }, - "usb": { - "type": "object", - "additionalProperties": false, - "properties": { - "device_ver": { - "$ref": "qmk.definitions.v1#/hex_number_4d", - "$comment": "Deprecated: use device_version instead" - }, - "device_version": { - "$ref": "qmk.definitions.v1#/bcd_version", - "description": "A BCD version number in the format `MM.m.r` (up to `99.9.9`).", - "examples": ["1.0.0"] - }, - "force_nkro": { - "type": "boolean", - "default": false, - "description": "Force NKRO to be active." - }, - "pid": { - "$ref": "qmk.definitions.v1#/hex_number_4d", - "description": "The USB product ID as a four-digit hexadecimal number.", - "examples": ["0x23B0"] - }, - "vid": { - "$ref": "qmk.definitions.v1#/hex_number_4d", - "description": "The USB vendor ID as a four-digit hexadecimal number.", - "examples": ["0xC1ED"] - }, - "max_power": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`500` (500 mA)", - "description": "The maximum current draw the host should expect from the device. This does not control the actual current usage." - }, - "no_startup_check": { - "type": "boolean", - "default": false, - "description": "Disable USB suspend check after keyboard startup." - }, - "polling_interval": { - "$ref": "qmk.definitions.v1#/unsigned_int_8", - "default": "`1` (1 ms/1000 Hz)", - "description": "The frequency at which the host should poll the keyboard for reports." - }, - "shared_endpoint": { - "type": "object", - "additionalProperties": false, - "properties": { - "keyboard": { - "type": "boolean", - "default": false, - "description": "Send keyboard reports through the \"shared\" USB endpoint." - }, - "mouse": { - "type": "boolean", - "default": true, - "description": "Send mouse reports through the \"shared\" USB endpoint." - } - } - }, - "suspend_wakeup_delay": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`0` (disabled)", - "description": "The amount of time to wait after sending a wakeup packet, in milliseconds." - }, - "wait_for_enumeration": { - "type": "boolean", - "default": false, - "description": "Force the keyboard to wait for USB enumeration before starting up." - } - } - }, - "qmk": { - "type": "object", - "additionalProperties": false, - "properties": { - "keys_per_scan": { - "$ref": "qmk.definitions.v1#/unsigned_int_8" - }, - "tap_keycode_delay": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`0` (no delay)", - "description": "The delay between keydown and keyup for tap events in milliseconds." - }, - "tap_capslock_delay": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`80` (80 ms)", - "description": "The delay between keydown and keyup for Caps Lock tap events in milliseconds." - }, - "locking": { - "type": "object", - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean", - "default": false, - "description": "Enable locking switch support." - }, - "resync": { - "type": "boolean", - "default": false, - "description": "Keep switch state consistent with keyboard LED state." - } - } - } - } - }, - "qmk_lufa_bootloader": { - "type": "object", - "additionalProperties": false, - "properties": { - "esc_output": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to the designated \"exit bootloader\" key's column (if `COL2ROW`)." - }, - "esc_input": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to the designated \"exit bootloader\" key's row (if `COL2ROW`)." - }, - "led": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to an LED to flash." - }, - "speaker": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to a speaker to click (can also be used for a second LED)." - } - } - }, - "ws2812": { - "type": "object", - "additionalProperties": false, - "properties": { - "driver": { - "type": "string", - "enum": [ - "bitbang", - "custom", - "i2c", - "pwm", - "spi", - "vendor" - ], - "default": "bitbang", - "description": "The driver to use. Must be one of `bitbang`, `custom`, `i2c`, `pwm`, `spi`, `vendor`." - }, - "pin": { - "$ref": "qmk.definitions.v1#/mcu_pin", - "description": "The GPIO pin connected to `DI` on the first LED in the chain (`bitbang`, `pwm`, `spi` and `vendor` drivers only)." - }, - "rgbw": { - "type": "boolean", - "default": false, - "description": "Enable RGBW LEDs." - }, - "i2c_address": { - "$ref": "qmk.definitions.v1#/hex_number_2d", - "default": "0xB0", - "description": "The I²C address of the WS2812 controller (`i2c` driver only)." - }, - "i2c_timeout": { - "$ref": "qmk.definitions.v1#/unsigned_int", - "default": "`100` (100 ms)", - "description": "The I²C timeout in milliseconds (`i2c` driver only)." - } - } + "items": {"$ref": "qmk.definitions.v1#/mcu_pin"}, + "$comment": "Deprecated: use split.handedness.matrix_grid instead" + } } + }, + "tags": { + "type": "array", + "items": {"type": "string"}, + "description": "A list of tags describing the keyboard.", + "examples": [ + ["ortho", "split", "rgb"] + ] + }, + "tapping": { + "type": "object", + "properties": { + "force_hold": {"type": "boolean"}, + "force_hold_per_key": {"type": "boolean"}, + "ignore_mod_tap_interrupt": {"type": "boolean"}, + "hold_on_other_key_press": {"type": "boolean", "default": false}, + "hold_on_other_key_press_per_key": {"type": "boolean", "default": false}, + "permissive_hold": {"type": "boolean", "default": false}, + "permissive_hold_per_key": {"type": "boolean", "default": false}, + "retro": {"type": "boolean", "default": false}, + "retro_per_key": {"type": "boolean", "default": false}, + "term": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`200` (200 ms)" + }, + "term_per_key": {"type": "boolean", "default": false}, + "toggle": {"$ref": "qmk.definitions.v1#/unsigned_int", "default": 5} + } + }, + "usb": { + "type": "object", + "additionalProperties": false, + "properties": { + "device_ver": { + "$ref": "qmk.definitions.v1#/hex_number_4d", + "$comment": "Deprecated: use device_version instead" + }, + "device_version": { + "$ref": "qmk.definitions.v1#/bcd_version", + "description": "A BCD version number in the format `MM.m.r` (up to `99.9.9`).", + "examples": ["1.0.0"] + }, + "force_nkro": { + "type": "boolean", + "default": false, + "description": "Force NKRO to be active." + }, + "pid": { + "$ref": "qmk.definitions.v1#/hex_number_4d", + "description": "The USB product ID as a four-digit hexadecimal number.", + "examples": ["0x23B0"] + }, + "vid": { + "$ref": "qmk.definitions.v1#/hex_number_4d", + "description": "The USB vendor ID as a four-digit hexadecimal number.", + "examples": ["0xC1ED"] + }, + "max_power": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`500` (500 mA)", + "description": "The maximum current draw the host should expect from the device. This does not control the actual current usage." + }, + "no_startup_check": { + "type": "boolean", + "default": false, + "description": "Disable USB suspend check after keyboard startup." + }, + "polling_interval": { + "$ref": "qmk.definitions.v1#/unsigned_int_8", + "default": "`1` (1 ms/1000 Hz)", + "description": "The frequency at which the host should poll the keyboard for reports." + }, + "shared_endpoint": { + "type": "object", + "additionalProperties": false, + "properties": { + "keyboard": { + "type": "boolean", + "default": false, + "description": "Send keyboard reports through the \"shared\" USB endpoint." + }, + "mouse": { + "type": "boolean", + "default": true, + "description": "Send mouse reports through the \"shared\" USB endpoint." + } + } + }, + "suspend_wakeup_delay": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`0` (disabled)", + "description": "The amount of time to wait after sending a wakeup packet, in milliseconds." + }, + "wait_for_enumeration": { + "type": "boolean", + "default": false, + "description": "Force the keyboard to wait for USB enumeration before starting up." + } + } + }, + "qmk": { + "type": "object", + "additionalProperties": false, + "properties": { + "keys_per_scan": {"$ref": "qmk.definitions.v1#/unsigned_int_8"}, + "tap_keycode_delay": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`0` (no delay)", + "description": "The delay between keydown and keyup for tap events in milliseconds." + }, + "tap_capslock_delay": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`80` (80 ms)", + "description": "The delay between keydown and keyup for Caps Lock tap events in milliseconds." + }, + "locking": { + "type": "object", + "additionalProperties": false, + "properties": { + "enabled": { + "type": "boolean", + "default": false, + "description": "Enable locking switch support." + }, + "resync": { + "type": "boolean", + "default": false, + "description": "Keep switch state consistent with keyboard LED state." + } + } + } + } + }, + "qmk_lufa_bootloader": { + "type": "object", + "additionalProperties": false, + "properties": { + "esc_output": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the designated \"exit bootloader\" key's column (if `COL2ROW`)." + }, + "esc_input": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to the designated \"exit bootloader\" key's row (if `COL2ROW`)." + }, + "led": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to an LED to flash." + }, + "speaker": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to a speaker to click (can also be used for a second LED)." + } + } + }, + "ws2812": { + "type": "object", + "additionalProperties": false, + "properties": { + "driver": { + "type": "string", + "enum": ["bitbang", "custom", "i2c", "pwm", "spi", "vendor"], + "default": "bitbang", + "description": "The driver to use. Must be one of `bitbang`, `custom`, `i2c`, `pwm`, `spi`, `vendor`." + }, + "pin": { + "$ref": "qmk.definitions.v1#/mcu_pin", + "description": "The GPIO pin connected to `DI` on the first LED in the chain (`bitbang`, `pwm`, `spi` and `vendor` drivers only)." + }, + "rgbw": { + "type": "boolean", + "default": false, + "description": "Enable RGBW LEDs." + }, + "i2c_address": { + "$ref": "qmk.definitions.v1#/hex_number_2d", + "default": "0xB0", + "description": "The I²C address of the WS2812 controller (`i2c` driver only)." + }, + "i2c_timeout": { + "$ref": "qmk.definitions.v1#/unsigned_int", + "default": "`100` (100 ms)", + "description": "The I²C timeout in milliseconds (`i2c` driver only)." + } + } + } } -} + }