summaryrefslogtreecommitdiff
path: root/lib/python/qmk
diff options
context:
space:
mode:
authorRyan <fauxpark@gmail.com>2022-09-16 12:05:25 +1000
committerGitHub <noreply@github.com>2022-09-16 12:05:25 +1000
commitbc0756f294f9555267dbd7007478804f537614c1 (patch)
treef753fa69703ab75fcdaff968902f2d0f80aa58ac /lib/python/qmk
parentb223e29921d7cad1bc7e3f07a7253216a3411f7a (diff)
Disconnect `usb.device_ver` (#18259)
Diffstat (limited to 'lib/python/qmk')
-rwxr-xr-xlib/python/qmk/cli/generate/layouts.py6
-rw-r--r--lib/python/qmk/info.py14
2 files changed, 0 insertions, 20 deletions
diff --git a/lib/python/qmk/cli/generate/layouts.py b/lib/python/qmk/cli/generate/layouts.py
index 193633baf6..8336f36b50 100755
--- a/lib/python/qmk/cli/generate/layouts.py
+++ b/lib/python/qmk/cli/generate/layouts.py
@@ -9,12 +9,6 @@ from qmk.keyboard import keyboard_completer, keyboard_folder
from qmk.path import is_keyboard, normpath
from qmk.commands import dump_lines
-usb_properties = {
- 'vid': 'VENDOR_ID',
- 'pid': 'PRODUCT_ID',
- 'device_ver': 'DEVICE_VER',
-}
-
@cli.argument('-o', '--output', arg_only=True, type=normpath, help='File to write to')
@cli.argument('-q', '--quiet', arg_only=True, action='store_true', help="Quiet mode, only output error messages")
diff --git a/lib/python/qmk/info.py b/lib/python/qmk/info.py
index b039c2c424..834f7d9170 100644
--- a/lib/python/qmk/info.py
+++ b/lib/python/qmk/info.py
@@ -437,19 +437,6 @@ def _extract_matrix_info(info_data, config_c):
return info_data
-# TODO: kill off usb.device_ver in favor of usb.device_version
-def _extract_device_version(info_data):
- if info_data.get('usb'):
- if info_data['usb'].get('device_version') and not info_data['usb'].get('device_ver'):
- (major, minor, revision) = info_data['usb']['device_version'].split('.', 3)
- info_data['usb']['device_ver'] = f'0x{major.zfill(2)}{minor}{revision}'
- if not info_data['usb'].get('device_version') and info_data['usb'].get('device_ver'):
- major = int(info_data['usb']['device_ver'][2:4])
- minor = int(info_data['usb']['device_ver'][4])
- revision = int(info_data['usb']['device_ver'][5])
- info_data['usb']['device_version'] = f'{major}.{minor}.{revision}'
-
-
def _config_to_json(key_type, config_value):
"""Convert config value using spec
"""
@@ -535,7 +522,6 @@ def _extract_config_h(info_data, config_c):
_extract_split_right_pins(info_data, config_c)
_extract_encoders(info_data, config_c)
_extract_split_encoders(info_data, config_c)
- _extract_device_version(info_data)
return info_data