From e111b9d01743c4e6c8f6772f0a71e7127dd344cf Mon Sep 17 00:00:00 2001 From: zvecr Date: Thu, 31 Mar 2022 23:31:01 +0100 Subject: [PATCH] Use slightly more unique data name --- data/templates/xap/docs/term_definitions.md.j2 | 2 +- data/xap/xap_0.0.1.hjson | 2 +- lib/python/qmk/xap/gen_firmware/header_generator.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/data/templates/xap/docs/term_definitions.md.j2 b/data/templates/xap/docs/term_definitions.md.j2 index 39587edb49f..9b2863eaa5f 100644 --- a/data/templates/xap/docs/term_definitions.md.j2 +++ b/data/templates/xap/docs/term_definitions.md.j2 @@ -3,6 +3,6 @@ {%- for type, definition in xap.term_definitions | dictsort %} | _{{ type }}_ | {{ definition }} | {%- endfor %} -{%- for type, definition in xap.types | dictsort %} +{%- for type, definition in xap.type_definitions | dictsort %} | _{{ definition.name }}_ | {{ definition.description }}{% if 'struct' == definition.type %} Takes the format:{% for item in definition.struct_members %}
`{{ item.type }}` - {{ item.name }}{%- endfor %}{% endif %} | {%- endfor %} \ No newline at end of file diff --git a/data/xap/xap_0.0.1.hjson b/data/xap/xap_0.0.1.hjson index a2abcb5fd62..b8a479f01b9 100755 --- a/data/xap/xap_0.0.1.hjson +++ b/data/xap/xap_0.0.1.hjson @@ -119,7 +119,7 @@ ''' } - types: { + type_definitions: { identifier: { name: ID description: A single octet / 8-bit byte, representing Subsystem or Route index. diff --git a/lib/python/qmk/xap/gen_firmware/header_generator.py b/lib/python/qmk/xap/gen_firmware/header_generator.py index e8e2465e4dc..a4b7d7af95f 100755 --- a/lib/python/qmk/xap/gen_firmware/header_generator.py +++ b/lib/python/qmk/xap/gen_firmware/header_generator.py @@ -126,7 +126,7 @@ def _append_types(lines, container): lines.append('') additional_types = {} - types = container.get('types', {}) + types = container.get('type_definitions', {}) for key, value in types.items(): data_type = _get_c_type(value['type']) additional_types[key] = f'xap_{key}_t'