From c505ea48b37ce6b1a725dbfe13842007785f5ef2 Mon Sep 17 00:00:00 2001 From: Ryan Date: Wed, 24 Apr 2024 13:59:57 +1000 Subject: [PATCH] Add haptic driver to keyboard.json schema (#23591) --- data/mappings/info_rules.hjson | 1 + data/schemas/keyboard.jsonschema | 9 +++++++++ keyboards/ai03/lunar_ii/keyboard.json | 3 +++ keyboards/ai03/lunar_ii/rules.mk | 1 - keyboards/boston_meetup/2019/keyboard.json | 3 +++ keyboards/boston_meetup/2019/rules.mk | 1 - keyboards/dcpedit/redherring/keyboard.json | 3 +++ keyboards/dcpedit/redherring/rules.mk | 1 - keyboards/hadron/ver3/keyboard.json | 3 +++ keyboards/hadron/ver3/rules.mk | 1 - keyboards/hardwareabstraction/handwire/keyboard.json | 3 +++ keyboards/hardwareabstraction/handwire/rules.mk | 1 - .../ibm/model_m_4th_gen/overnumpad_1xb/keyboard.json | 3 +++ keyboards/ibm/model_m_4th_gen/overnumpad_1xb/rules.mk | 1 - keyboards/mechwild/clunker/{info.json => keyboard.json} | 3 +++ keyboards/mechwild/clunker/rules.mk | 1 - keyboards/pearlboards/atlas/keyboard.json | 3 +++ keyboards/pearlboards/atlas/rules.mk | 1 - keyboards/pearlboards/pearl/keyboard.json | 3 +++ keyboards/pearlboards/pearl/rules.mk | 1 - keyboards/pearlboards/zeus/keyboard.json | 3 +++ keyboards/pearlboards/zeus/rules.mk | 1 - keyboards/splitkb/zima/keyboard.json | 3 +++ keyboards/splitkb/zima/rules.mk | 1 - .../overnumpad_1xb/keyboard.json | 3 +++ .../classic_ultracl_post_2013/overnumpad_1xb/rules.mk | 1 - .../overnumpad_1xb/keyboard.json | 3 +++ .../classic_ultracl_pre_2013/overnumpad_1xb/rules.mk | 1 - keyboards/unicomp/pc122/overnumpad_1xb/keyboard.json | 3 +++ keyboards/unicomp/pc122/overnumpad_1xb/rules.mk | 1 - .../spacesaver_m_post_2013/overnumpad_1xb/keyboard.json | 3 +++ .../spacesaver_m_post_2013/overnumpad_1xb/rules.mk | 1 - .../spacesaver_m_pre_2013/overnumpad_1xb/keyboard.json | 3 +++ .../spacesaver_m_pre_2013/overnumpad_1xb/rules.mk | 1 - keyboards/vertex/angle65/keyboard.json | 3 +++ keyboards/vertex/angle65/rules.mk | 1 - keyboards/xw60/keyboard.json | 3 +++ keyboards/xw60/rules.mk | 1 - 38 files changed, 64 insertions(+), 18 deletions(-) delete mode 100644 keyboards/ai03/lunar_ii/rules.mk delete mode 100644 keyboards/boston_meetup/2019/rules.mk delete mode 100644 keyboards/hadron/ver3/rules.mk delete mode 100644 keyboards/hardwareabstraction/handwire/rules.mk delete mode 100644 keyboards/ibm/model_m_4th_gen/overnumpad_1xb/rules.mk rename keyboards/mechwild/clunker/{info.json => keyboard.json} (99%) delete mode 100644 keyboards/mechwild/clunker/rules.mk delete mode 100644 keyboards/pearlboards/atlas/rules.mk delete mode 100644 keyboards/pearlboards/pearl/rules.mk delete mode 100644 keyboards/pearlboards/zeus/rules.mk delete mode 100644 keyboards/splitkb/zima/rules.mk delete mode 100644 keyboards/unicomp/classic_ultracl_post_2013/overnumpad_1xb/rules.mk delete mode 100644 keyboards/unicomp/classic_ultracl_pre_2013/overnumpad_1xb/rules.mk delete mode 100644 keyboards/unicomp/pc122/overnumpad_1xb/rules.mk delete mode 100644 keyboards/unicomp/spacesaver_m_post_2013/overnumpad_1xb/rules.mk delete mode 100644 keyboards/unicomp/spacesaver_m_pre_2013/overnumpad_1xb/rules.mk delete mode 100644 keyboards/vertex/angle65/rules.mk delete mode 100644 keyboards/xw60/rules.mk diff --git a/data/mappings/info_rules.hjson b/data/mappings/info_rules.hjson index fc25eb3328b..35e2e8dfc0d 100644 --- a/data/mappings/info_rules.hjson +++ b/data/mappings/info_rules.hjson @@ -23,6 +23,7 @@ "ENCODER_ENABLE": {"info_key": "encoder.enabled", "value_type": "bool"}, "ENCODER_DRIVER": {"info_key": "encoder.driver"}, "FIRMWARE_FORMAT": {"info_key": "build.firmware_format"}, + "HAPTIC_DRIVER": {"info_key": "haptic.driver"}, "KEYBOARD_SHARED_EP": {"info_key": "usb.shared_endpoint.keyboard", "value_type": "bool"}, "LAYOUTS": {"info_key": "community_layouts", "value_type": "list"}, "LED_MATRIX_DRIVER": {"info_key": "led_matrix.driver"}, diff --git a/data/schemas/keyboard.jsonschema b/data/schemas/keyboard.jsonschema index 25aaabcf4a3..f3116fd2710 100644 --- a/data/schemas/keyboard.jsonschema +++ b/data/schemas/keyboard.jsonschema @@ -387,6 +387,15 @@ } } }, + "haptic": { + "type": "object", + "properties": { + "driver": { + "type": "string", + "enum": ["drv2605l", "solenoid"] + } + } + }, "leader_key": { "type": "object", "properties": { diff --git a/keyboards/ai03/lunar_ii/keyboard.json b/keyboards/ai03/lunar_ii/keyboard.json index 38729595a29..badf9240aba 100644 --- a/keyboards/ai03/lunar_ii/keyboard.json +++ b/keyboards/ai03/lunar_ii/keyboard.json @@ -22,6 +22,9 @@ "resync": true } }, + "haptic": { + "driver": "solenoid" + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "diode_direction": "COL2ROW", diff --git a/keyboards/ai03/lunar_ii/rules.mk b/keyboards/ai03/lunar_ii/rules.mk deleted file mode 100644 index a521203b326..00000000000 --- a/keyboards/ai03/lunar_ii/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = solenoid diff --git a/keyboards/boston_meetup/2019/keyboard.json b/keyboards/boston_meetup/2019/keyboard.json index 97990bb5030..40a390b0a8c 100644 --- a/keyboards/boston_meetup/2019/keyboard.json +++ b/keyboards/boston_meetup/2019/keyboard.json @@ -17,6 +17,9 @@ "haptic": true, "oled": true }, + "haptic": { + "driver": "drv2605l" + }, "rgb_matrix": { "driver": "ws2812" }, diff --git a/keyboards/boston_meetup/2019/rules.mk b/keyboards/boston_meetup/2019/rules.mk deleted file mode 100644 index dea510c2ab3..00000000000 --- a/keyboards/boston_meetup/2019/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = drv2605l diff --git a/keyboards/dcpedit/redherring/keyboard.json b/keyboards/dcpedit/redherring/keyboard.json index 845c52e3e04..a2f87c90b9a 100644 --- a/keyboards/dcpedit/redherring/keyboard.json +++ b/keyboards/dcpedit/redherring/keyboard.json @@ -31,6 +31,9 @@ "qmk": { "tap_keycode_delay": 10 }, + "haptic": { + "driver": "solenoid" + }, "url": "https://github.com/dcpedit/redherring", "usb": { "device_version": "1.0.0", diff --git a/keyboards/dcpedit/redherring/rules.mk b/keyboards/dcpedit/redherring/rules.mk index 35c76d4cf1c..27d8af7683e 100644 --- a/keyboards/dcpedit/redherring/rules.mk +++ b/keyboards/dcpedit/redherring/rules.mk @@ -1,2 +1 @@ F_CPU = 16000000 -HAPTIC_DRIVER = solenoid \ No newline at end of file diff --git a/keyboards/hadron/ver3/keyboard.json b/keyboards/hadron/ver3/keyboard.json index 02a75d59eb8..f3e4bba06f1 100644 --- a/keyboards/hadron/ver3/keyboard.json +++ b/keyboards/hadron/ver3/keyboard.json @@ -15,6 +15,9 @@ {"pin_a": "B13", "pin_b": "B14"} ] }, + "haptic": { + "driver": "drv2605l" + }, "rgblight": { "led_count": 10, "animations": { diff --git a/keyboards/hadron/ver3/rules.mk b/keyboards/hadron/ver3/rules.mk deleted file mode 100644 index dea510c2ab3..00000000000 --- a/keyboards/hadron/ver3/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = drv2605l diff --git a/keyboards/hardwareabstraction/handwire/keyboard.json b/keyboards/hardwareabstraction/handwire/keyboard.json index 5e0ec6f11e2..225712dcc4f 100644 --- a/keyboards/hardwareabstraction/handwire/keyboard.json +++ b/keyboards/hardwareabstraction/handwire/keyboard.json @@ -15,6 +15,9 @@ "oled": true, "wpm": true }, + "haptic": { + "driver": "solenoid" + }, "build": { "lto": true }, diff --git a/keyboards/hardwareabstraction/handwire/rules.mk b/keyboards/hardwareabstraction/handwire/rules.mk deleted file mode 100644 index a521203b326..00000000000 --- a/keyboards/hardwareabstraction/handwire/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = solenoid diff --git a/keyboards/ibm/model_m_4th_gen/overnumpad_1xb/keyboard.json b/keyboards/ibm/model_m_4th_gen/overnumpad_1xb/keyboard.json index 0f67e6606d7..be103896718 100644 --- a/keyboards/ibm/model_m_4th_gen/overnumpad_1xb/keyboard.json +++ b/keyboards/ibm/model_m_4th_gen/overnumpad_1xb/keyboard.json @@ -11,6 +11,9 @@ "keyboard": true } }, + "haptic": { + "driver": "solenoid" + }, "indicators": { "caps_lock": "C11", "num_lock": "C12", diff --git a/keyboards/ibm/model_m_4th_gen/overnumpad_1xb/rules.mk b/keyboards/ibm/model_m_4th_gen/overnumpad_1xb/rules.mk deleted file mode 100644 index a521203b326..00000000000 --- a/keyboards/ibm/model_m_4th_gen/overnumpad_1xb/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = solenoid diff --git a/keyboards/mechwild/clunker/info.json b/keyboards/mechwild/clunker/keyboard.json similarity index 99% rename from keyboards/mechwild/clunker/info.json rename to keyboards/mechwild/clunker/keyboard.json index 1a4114f8f29..acf9628f8e1 100644 --- a/keyboards/mechwild/clunker/info.json +++ b/keyboards/mechwild/clunker/keyboard.json @@ -17,6 +17,9 @@ "mousekey": true, "nkro": true }, + "haptic": { + "driver": "solenoid" + }, "matrix_pins": { "cols": ["D1", "D0", "D4", "C6", "D7", "E6", "B4", "B5"], "rows": ["F5", "F6", "B3", "F7", "B2", "B1", "B6"] diff --git a/keyboards/mechwild/clunker/rules.mk b/keyboards/mechwild/clunker/rules.mk deleted file mode 100644 index a521203b326..00000000000 --- a/keyboards/mechwild/clunker/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = solenoid diff --git a/keyboards/pearlboards/atlas/keyboard.json b/keyboards/pearlboards/atlas/keyboard.json index 173a20892b5..714a344c33a 100644 --- a/keyboards/pearlboards/atlas/keyboard.json +++ b/keyboards/pearlboards/atlas/keyboard.json @@ -31,6 +31,9 @@ {"pin_a": "E0", "pin_b": "D7", "resolution": 1} ] }, + "haptic": { + "driver": "drv2605l" + }, "indicators": { "caps_lock": "F4", "num_lock": "F5", diff --git a/keyboards/pearlboards/atlas/rules.mk b/keyboards/pearlboards/atlas/rules.mk deleted file mode 100644 index dea510c2ab3..00000000000 --- a/keyboards/pearlboards/atlas/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = drv2605l diff --git a/keyboards/pearlboards/pearl/keyboard.json b/keyboards/pearlboards/pearl/keyboard.json index e2dddb86620..0dc6f9a7a5e 100644 --- a/keyboards/pearlboards/pearl/keyboard.json +++ b/keyboards/pearlboards/pearl/keyboard.json @@ -31,6 +31,9 @@ "scroll_lock": "B2", "on_state": 0 }, + "haptic": { + "driver": "drv2605l" + }, "rgblight": { "saturation_steps": 8, "brightness_steps": 8, diff --git a/keyboards/pearlboards/pearl/rules.mk b/keyboards/pearlboards/pearl/rules.mk deleted file mode 100644 index dea510c2ab3..00000000000 --- a/keyboards/pearlboards/pearl/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = drv2605l diff --git a/keyboards/pearlboards/zeus/keyboard.json b/keyboards/pearlboards/zeus/keyboard.json index c77adfb5cf9..43639179509 100644 --- a/keyboards/pearlboards/zeus/keyboard.json +++ b/keyboards/pearlboards/zeus/keyboard.json @@ -31,6 +31,9 @@ {"pin_a": "E7", "pin_b": "E6", "resolution": 1} ] }, + "haptic": { + "driver": "drv2605l" + }, "indicators": { "caps_lock": "C5", "num_lock": "C4", diff --git a/keyboards/pearlboards/zeus/rules.mk b/keyboards/pearlboards/zeus/rules.mk deleted file mode 100644 index 34900998f76..00000000000 --- a/keyboards/pearlboards/zeus/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = drv2605l # Rumble motor diff --git a/keyboards/splitkb/zima/keyboard.json b/keyboards/splitkb/zima/keyboard.json index 68892960da7..c3e33d939e1 100644 --- a/keyboards/splitkb/zima/keyboard.json +++ b/keyboards/splitkb/zima/keyboard.json @@ -22,6 +22,9 @@ "oled": true, "rgblight": true }, + "haptic": { + "driver": "drv2605l" + }, "rgblight": { "saturation_steps": 8, "brightness_steps": 8, diff --git a/keyboards/splitkb/zima/rules.mk b/keyboards/splitkb/zima/rules.mk deleted file mode 100644 index dea510c2ab3..00000000000 --- a/keyboards/splitkb/zima/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = drv2605l diff --git a/keyboards/unicomp/classic_ultracl_post_2013/overnumpad_1xb/keyboard.json b/keyboards/unicomp/classic_ultracl_post_2013/overnumpad_1xb/keyboard.json index 0ef2cc4d5ed..cdc22909c0b 100644 --- a/keyboards/unicomp/classic_ultracl_post_2013/overnumpad_1xb/keyboard.json +++ b/keyboards/unicomp/classic_ultracl_post_2013/overnumpad_1xb/keyboard.json @@ -15,6 +15,9 @@ "num_lock": "C12", "scroll_lock": "C10" }, + "haptic": { + "driver": "solenoid" + }, "processor": "STM32F446", "bootloader": "stm32-dfu", "diode_direction": "ROW2COL", diff --git a/keyboards/unicomp/classic_ultracl_post_2013/overnumpad_1xb/rules.mk b/keyboards/unicomp/classic_ultracl_post_2013/overnumpad_1xb/rules.mk deleted file mode 100644 index a521203b326..00000000000 --- a/keyboards/unicomp/classic_ultracl_post_2013/overnumpad_1xb/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = solenoid diff --git a/keyboards/unicomp/classic_ultracl_pre_2013/overnumpad_1xb/keyboard.json b/keyboards/unicomp/classic_ultracl_pre_2013/overnumpad_1xb/keyboard.json index 30264dd537d..71f706171eb 100644 --- a/keyboards/unicomp/classic_ultracl_pre_2013/overnumpad_1xb/keyboard.json +++ b/keyboards/unicomp/classic_ultracl_pre_2013/overnumpad_1xb/keyboard.json @@ -10,6 +10,9 @@ "mousekey": true, "nkro": false }, + "haptic": { + "driver": "solenoid" + }, "indicators": { "caps_lock": "C11", "num_lock": "C12", diff --git a/keyboards/unicomp/classic_ultracl_pre_2013/overnumpad_1xb/rules.mk b/keyboards/unicomp/classic_ultracl_pre_2013/overnumpad_1xb/rules.mk deleted file mode 100644 index a521203b326..00000000000 --- a/keyboards/unicomp/classic_ultracl_pre_2013/overnumpad_1xb/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = solenoid diff --git a/keyboards/unicomp/pc122/overnumpad_1xb/keyboard.json b/keyboards/unicomp/pc122/overnumpad_1xb/keyboard.json index 936e286af1d..73b79e40473 100644 --- a/keyboards/unicomp/pc122/overnumpad_1xb/keyboard.json +++ b/keyboards/unicomp/pc122/overnumpad_1xb/keyboard.json @@ -10,6 +10,9 @@ "mousekey": true, "nkro": false }, + "haptic": { + "driver": "solenoid" + }, "indicators": { "caps_lock": "C11", "num_lock": "C12", diff --git a/keyboards/unicomp/pc122/overnumpad_1xb/rules.mk b/keyboards/unicomp/pc122/overnumpad_1xb/rules.mk deleted file mode 100644 index a521203b326..00000000000 --- a/keyboards/unicomp/pc122/overnumpad_1xb/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = solenoid diff --git a/keyboards/unicomp/spacesaver_m_post_2013/overnumpad_1xb/keyboard.json b/keyboards/unicomp/spacesaver_m_post_2013/overnumpad_1xb/keyboard.json index 9fd91ce48fc..e2e6a610434 100644 --- a/keyboards/unicomp/spacesaver_m_post_2013/overnumpad_1xb/keyboard.json +++ b/keyboards/unicomp/spacesaver_m_post_2013/overnumpad_1xb/keyboard.json @@ -10,6 +10,9 @@ "mousekey": true, "nkro": false }, + "haptic": { + "driver": "solenoid" + }, "indicators": { "caps_lock": "C12" }, diff --git a/keyboards/unicomp/spacesaver_m_post_2013/overnumpad_1xb/rules.mk b/keyboards/unicomp/spacesaver_m_post_2013/overnumpad_1xb/rules.mk deleted file mode 100644 index a521203b326..00000000000 --- a/keyboards/unicomp/spacesaver_m_post_2013/overnumpad_1xb/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = solenoid diff --git a/keyboards/unicomp/spacesaver_m_pre_2013/overnumpad_1xb/keyboard.json b/keyboards/unicomp/spacesaver_m_pre_2013/overnumpad_1xb/keyboard.json index db772e46e24..111b106f381 100644 --- a/keyboards/unicomp/spacesaver_m_pre_2013/overnumpad_1xb/keyboard.json +++ b/keyboards/unicomp/spacesaver_m_pre_2013/overnumpad_1xb/keyboard.json @@ -13,6 +13,9 @@ "indicators": { "caps_lock": "C12" }, + "haptic": { + "driver": "solenoid" + }, "processor": "STM32F446", // RET6 "bootloader": "stm32-dfu", "diode_direction": "ROW2COL", diff --git a/keyboards/unicomp/spacesaver_m_pre_2013/overnumpad_1xb/rules.mk b/keyboards/unicomp/spacesaver_m_pre_2013/overnumpad_1xb/rules.mk deleted file mode 100644 index a521203b326..00000000000 --- a/keyboards/unicomp/spacesaver_m_pre_2013/overnumpad_1xb/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = solenoid diff --git a/keyboards/vertex/angle65/keyboard.json b/keyboards/vertex/angle65/keyboard.json index 962b3fd4f11..ef0aacfef4b 100644 --- a/keyboards/vertex/angle65/keyboard.json +++ b/keyboards/vertex/angle65/keyboard.json @@ -30,6 +30,9 @@ "caps_lock": "C13", "on_state": 0 }, + "haptic": { + "driver": "solenoid" + }, "rgblight": { "led_count": 9, "animations": { diff --git a/keyboards/vertex/angle65/rules.mk b/keyboards/vertex/angle65/rules.mk deleted file mode 100644 index a521203b326..00000000000 --- a/keyboards/vertex/angle65/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = solenoid diff --git a/keyboards/xw60/keyboard.json b/keyboards/xw60/keyboard.json index 6316f944e50..3bd11e21c18 100644 --- a/keyboards/xw60/keyboard.json +++ b/keyboards/xw60/keyboard.json @@ -20,6 +20,9 @@ "enabled": true } }, + "haptic": { + "driver": "solenoid" + }, "matrix_pins": { "cols": ["F0", "F1", "E6", "C7", "C6", "B6", "D4", "B1", "B7", "B5", "B4", "D7", "D6", "B3"], "rows": ["D0", "D1", "D2", "D3", "D5"] diff --git a/keyboards/xw60/rules.mk b/keyboards/xw60/rules.mk deleted file mode 100644 index a521203b326..00000000000 --- a/keyboards/xw60/rules.mk +++ /dev/null @@ -1 +0,0 @@ -HAPTIC_DRIVER = solenoid