odxtools 6.7.0__py3-none-any.whl → 9.3.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- odxtools/__init__.py +6 -4
- odxtools/additionalaudience.py +3 -5
- odxtools/admindata.py +5 -7
- odxtools/audience.py +10 -13
- odxtools/basecomparam.py +3 -5
- odxtools/basicstructure.py +55 -240
- odxtools/cli/_parser_utils.py +1 -1
- odxtools/cli/_print_utils.py +168 -134
- odxtools/cli/browse.py +111 -92
- odxtools/cli/compare.py +90 -71
- odxtools/cli/list.py +24 -15
- odxtools/cli/snoop.py +28 -5
- odxtools/codec.py +211 -0
- odxtools/commrelation.py +122 -0
- odxtools/companydata.py +5 -7
- odxtools/companydocinfo.py +7 -8
- odxtools/companyrevisioninfo.py +3 -5
- odxtools/companyspecificinfo.py +8 -9
- odxtools/comparam.py +4 -6
- odxtools/comparaminstance.py +7 -9
- odxtools/comparamspec.py +16 -54
- odxtools/comparamsubset.py +22 -62
- odxtools/complexcomparam.py +5 -7
- odxtools/compumethods/compucodecompumethod.py +63 -0
- odxtools/compumethods/compuconst.py +31 -0
- odxtools/compumethods/compudefaultvalue.py +27 -0
- odxtools/compumethods/compuinternaltophys.py +56 -0
- odxtools/compumethods/compuinversevalue.py +7 -0
- odxtools/compumethods/compumethod.py +93 -12
- odxtools/compumethods/compuphystointernal.py +56 -0
- odxtools/compumethods/compurationalcoeffs.py +20 -9
- odxtools/compumethods/compuscale.py +30 -35
- odxtools/compumethods/createanycompumethod.py +28 -161
- odxtools/compumethods/identicalcompumethod.py +31 -6
- odxtools/compumethods/linearcompumethod.py +69 -189
- odxtools/compumethods/linearsegment.py +190 -0
- odxtools/compumethods/ratfunccompumethod.py +106 -0
- odxtools/compumethods/ratfuncsegment.py +87 -0
- odxtools/compumethods/scalelinearcompumethod.py +132 -26
- odxtools/compumethods/scaleratfunccompumethod.py +113 -0
- odxtools/compumethods/tabintpcompumethod.py +119 -99
- odxtools/compumethods/texttablecompumethod.py +107 -43
- odxtools/createanydiagcodedtype.py +10 -67
- odxtools/database.py +167 -87
- odxtools/dataobjectproperty.py +15 -25
- odxtools/decodestate.py +9 -15
- odxtools/description.py +47 -0
- odxtools/determinenumberofitems.py +4 -5
- odxtools/diagcodedtype.py +36 -106
- odxtools/diagcomm.py +24 -12
- odxtools/diagdatadictionaryspec.py +33 -34
- odxtools/diaglayercontainer.py +46 -54
- odxtools/diaglayers/basevariant.py +128 -0
- odxtools/diaglayers/basevariantraw.py +123 -0
- odxtools/diaglayers/diaglayer.py +432 -0
- odxtools/{diaglayerraw.py → diaglayers/diaglayerraw.py} +105 -120
- odxtools/diaglayers/ecushareddata.py +96 -0
- odxtools/diaglayers/ecushareddataraw.py +87 -0
- odxtools/diaglayers/ecuvariant.py +124 -0
- odxtools/diaglayers/ecuvariantraw.py +129 -0
- odxtools/diaglayers/functionalgroup.py +110 -0
- odxtools/diaglayers/functionalgroupraw.py +106 -0
- odxtools/{diaglayer.py → diaglayers/hierarchyelement.py} +209 -448
- odxtools/diaglayers/hierarchyelementraw.py +58 -0
- odxtools/diaglayers/protocol.py +64 -0
- odxtools/diaglayers/protocolraw.py +91 -0
- odxtools/diagnostictroublecode.py +8 -9
- odxtools/diagservice.py +56 -43
- odxtools/diagvariable.py +113 -0
- odxtools/docrevision.py +5 -7
- odxtools/dopbase.py +15 -17
- odxtools/dtcdop.py +168 -50
- odxtools/dynamicendmarkerfield.py +134 -0
- odxtools/dynamiclengthfield.py +41 -37
- odxtools/dyndefinedspec.py +177 -0
- odxtools/dynenddopref.py +38 -0
- odxtools/ecuvariantmatcher.py +6 -7
- odxtools/element.py +13 -15
- odxtools/encodestate.py +199 -22
- odxtools/endofpdufield.py +31 -18
- odxtools/environmentdata.py +8 -1
- odxtools/environmentdatadescription.py +198 -38
- odxtools/exceptions.py +11 -2
- odxtools/field.py +10 -10
- odxtools/functionalclass.py +3 -5
- odxtools/inputparam.py +3 -12
- odxtools/leadinglengthinfotype.py +37 -18
- odxtools/library.py +66 -0
- odxtools/loadfile.py +64 -0
- odxtools/matchingparameter.py +3 -3
- odxtools/message.py +0 -7
- odxtools/minmaxlengthtype.py +61 -33
- odxtools/modification.py +3 -5
- odxtools/multiplexer.py +128 -73
- odxtools/multiplexercase.py +13 -14
- odxtools/multiplexerdefaultcase.py +15 -12
- odxtools/multiplexerswitchkey.py +4 -5
- odxtools/nameditemlist.py +29 -5
- odxtools/negoutputparam.py +3 -5
- odxtools/odxcategory.py +83 -0
- odxtools/odxlink.py +60 -51
- odxtools/odxtypes.py +37 -5
- odxtools/outputparam.py +4 -15
- odxtools/parameterinfo.py +218 -67
- odxtools/parameters/codedconstparameter.py +16 -24
- odxtools/parameters/dynamicparameter.py +5 -4
- odxtools/parameters/lengthkeyparameter.py +60 -26
- odxtools/parameters/matchingrequestparameter.py +23 -11
- odxtools/parameters/nrcconstparameter.py +45 -46
- odxtools/parameters/parameter.py +54 -56
- odxtools/parameters/parameterwithdop.py +15 -25
- odxtools/parameters/physicalconstantparameter.py +15 -18
- odxtools/parameters/reservedparameter.py +6 -2
- odxtools/parameters/systemparameter.py +55 -11
- odxtools/parameters/tableentryparameter.py +3 -2
- odxtools/parameters/tablekeyparameter.py +103 -49
- odxtools/parameters/tablestructparameter.py +47 -48
- odxtools/parameters/valueparameter.py +16 -20
- odxtools/paramlengthinfotype.py +52 -32
- odxtools/parentref.py +16 -2
- odxtools/physicaldimension.py +3 -8
- odxtools/progcode.py +26 -11
- odxtools/protstack.py +3 -5
- odxtools/py.typed +0 -0
- odxtools/relateddoc.py +7 -9
- odxtools/request.py +120 -10
- odxtools/response.py +123 -23
- odxtools/scaleconstr.py +3 -3
- odxtools/servicebinner.py +1 -1
- odxtools/singleecujob.py +12 -10
- odxtools/snrefcontext.py +29 -0
- odxtools/specialdata.py +3 -5
- odxtools/specialdatagroup.py +7 -9
- odxtools/specialdatagroupcaption.py +3 -6
- odxtools/standardlengthtype.py +80 -14
- odxtools/state.py +3 -5
- odxtools/statechart.py +13 -19
- odxtools/statetransition.py +7 -17
- odxtools/staticfield.py +31 -25
- odxtools/subcomponent.py +288 -0
- odxtools/swvariable.py +21 -0
- odxtools/table.py +7 -8
- odxtools/tablerow.py +19 -11
- odxtools/teammember.py +3 -5
- odxtools/templates/comparam-spec.odx-c.xml.jinja2 +4 -24
- odxtools/templates/comparam-subset.odx-cs.xml.jinja2 +5 -26
- odxtools/templates/diag_layer_container.odx-d.xml.jinja2 +15 -31
- odxtools/templates/{index.xml.xml.jinja2 → index.xml.jinja2} +1 -1
- odxtools/templates/macros/printAudience.xml.jinja2 +1 -1
- odxtools/templates/macros/printBaseVariant.xml.jinja2 +53 -0
- odxtools/templates/macros/printCompanyData.xml.jinja2 +4 -7
- odxtools/templates/macros/printComparam.xml.jinja2 +6 -4
- odxtools/templates/macros/printComparamRef.xml.jinja2 +5 -12
- odxtools/templates/macros/printCompuMethod.xml.jinja2 +147 -0
- odxtools/templates/macros/printDOP.xml.jinja2 +27 -133
- odxtools/templates/macros/printDescription.xml.jinja2 +18 -0
- odxtools/templates/macros/printDiagComm.xml.jinja2 +1 -1
- odxtools/templates/macros/printDiagLayer.xml.jinja2 +222 -0
- odxtools/templates/macros/printDiagVariable.xml.jinja2 +66 -0
- odxtools/templates/macros/printDynDefinedSpec.xml.jinja2 +48 -0
- odxtools/templates/macros/printDynamicEndmarkerField.xml.jinja2 +16 -0
- odxtools/templates/macros/printDynamicLengthField.xml.jinja2 +1 -1
- odxtools/templates/macros/printEcuSharedData.xml.jinja2 +30 -0
- odxtools/templates/macros/printEcuVariant.xml.jinja2 +53 -0
- odxtools/templates/macros/printEcuVariantPattern.xml.jinja2 +1 -1
- odxtools/templates/macros/printElementId.xml.jinja2 +8 -3
- odxtools/templates/macros/printEndOfPdu.xml.jinja2 +1 -1
- odxtools/templates/macros/printEnvDataDesc.xml.jinja2 +1 -1
- odxtools/templates/macros/printFunctionalClass.xml.jinja2 +1 -1
- odxtools/templates/macros/printFunctionalGroup.xml.jinja2 +40 -0
- odxtools/templates/macros/printHierarchyElement.xml.jinja2 +24 -0
- odxtools/templates/macros/printLibrary.xml.jinja2 +21 -0
- odxtools/templates/macros/printMux.xml.jinja2 +4 -3
- odxtools/templates/macros/printOdxCategory.xml.jinja2 +28 -0
- odxtools/templates/macros/printParam.xml.jinja2 +11 -12
- odxtools/templates/macros/printProtStack.xml.jinja2 +1 -1
- odxtools/templates/macros/printProtocol.xml.jinja2 +30 -0
- odxtools/templates/macros/printRequest.xml.jinja2 +1 -1
- odxtools/templates/macros/printResponse.xml.jinja2 +1 -1
- odxtools/templates/macros/printService.xml.jinja2 +3 -2
- odxtools/templates/macros/printSingleEcuJob.xml.jinja2 +5 -26
- odxtools/templates/macros/printSpecialData.xml.jinja2 +1 -1
- odxtools/templates/macros/printState.xml.jinja2 +1 -1
- odxtools/templates/macros/printStateChart.xml.jinja2 +1 -1
- odxtools/templates/macros/printStateTransition.xml.jinja2 +1 -1
- odxtools/templates/macros/printStaticField.xml.jinja2 +1 -1
- odxtools/templates/macros/printStructure.xml.jinja2 +1 -1
- odxtools/templates/macros/printSubComponent.xml.jinja2 +104 -0
- odxtools/templates/macros/printTable.xml.jinja2 +4 -5
- odxtools/templates/macros/printUnitSpec.xml.jinja2 +3 -5
- odxtools/uds.py +2 -10
- odxtools/unit.py +4 -8
- odxtools/unitgroup.py +3 -5
- odxtools/unitspec.py +17 -17
- odxtools/utils.py +38 -20
- odxtools/variablegroup.py +32 -0
- odxtools/version.py +2 -2
- odxtools/{write_pdx_file.py → writepdxfile.py} +20 -10
- odxtools/xdoc.py +3 -5
- {odxtools-6.7.0.dist-info → odxtools-9.3.0.dist-info}/METADATA +20 -21
- odxtools-9.3.0.dist-info/RECORD +228 -0
- {odxtools-6.7.0.dist-info → odxtools-9.3.0.dist-info}/WHEEL +1 -1
- odxtools/createcompanydatas.py +0 -17
- odxtools/createsdgs.py +0 -19
- odxtools/load_file.py +0 -13
- odxtools/load_odx_d_file.py +0 -6
- odxtools/load_pdx_file.py +0 -8
- odxtools/templates/macros/printVariant.xml.jinja2 +0 -216
- odxtools-6.7.0.dist-info/RECORD +0 -182
- /odxtools/{diaglayertype.py → diaglayers/diaglayertype.py} +0 -0
- {odxtools-6.7.0.dist-info → odxtools-9.3.0.dist-info}/LICENSE +0 -0
- {odxtools-6.7.0.dist-info → odxtools-9.3.0.dist-info}/entry_points.txt +0 -0
- {odxtools-6.7.0.dist-info → odxtools-9.3.0.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,222 @@
|
|
1
|
+
{#- -*- mode: sgml; tab-width: 1; indent-tabs-mode: nil -*-
|
2
|
+
#
|
3
|
+
# SPDX-License-Identifier: MIT
|
4
|
+
-#}
|
5
|
+
|
6
|
+
{%- import('macros/printElementId.xml.jinja2') as peid %}
|
7
|
+
{%- import('macros/printDOP.xml.jinja2') as pdop %}
|
8
|
+
{%- import('macros/printTable.xml.jinja2') as pt %}
|
9
|
+
{%- import('macros/printFunctionalClass.xml.jinja2') as pfc %}
|
10
|
+
{%- import('macros/printStructure.xml.jinja2') as pst %}
|
11
|
+
{%- import('macros/printEndOfPdu.xml.jinja2') as peopdu %}
|
12
|
+
{%- import('macros/printStaticField.xml.jinja2') as psf %}
|
13
|
+
{%- import('macros/printDynamicLengthField.xml.jinja2') as pdlf %}
|
14
|
+
{%- import('macros/printDynamicEndmarkerField.xml.jinja2') as pdemf %}
|
15
|
+
{%- import('macros/printMux.xml.jinja2') as pm %}
|
16
|
+
{%- import('macros/printEnvData.xml.jinja2') as ped %}
|
17
|
+
{%- import('macros/printEnvDataDesc.xml.jinja2') as pedd %}
|
18
|
+
{%- import('macros/printUnitSpec.xml.jinja2') as punit %}
|
19
|
+
{%- import('macros/printService.xml.jinja2') as ps %}
|
20
|
+
{%- import('macros/printSingleEcuJob.xml.jinja2') as psej %}
|
21
|
+
{%- import('macros/printRequest.xml.jinja2') as prq %}
|
22
|
+
{%- import('macros/printResponse.xml.jinja2') as presp %}
|
23
|
+
{%- import('macros/printStateChart.xml.jinja2') as psc %}
|
24
|
+
{%- import('macros/printAudience.xml.jinja2') as paud %}
|
25
|
+
{%- import('macros/printSubComponent.xml.jinja2') as psubcomp %}
|
26
|
+
{%- import('macros/printLibrary.xml.jinja2') as plib %}
|
27
|
+
{%- import('macros/printSpecialData.xml.jinja2') as psd %}
|
28
|
+
{%- import('macros/printEcuVariantPattern.xml.jinja2') as pvpat %}
|
29
|
+
{%- import('macros/printAdminData.xml.jinja2') as pad %}
|
30
|
+
|
31
|
+
{%- macro printDiagLayerAttribs(dl) -%}
|
32
|
+
{#- #} {{-peid.printElementIdAttribs(dl)}}{# -#}
|
33
|
+
{%- endmacro -%}
|
34
|
+
|
35
|
+
{%- macro printDiagLayerSubtags(dl) -%}
|
36
|
+
{%- set dlr = dl.diag_layer_raw %}
|
37
|
+
{{ peid.printElementIdSubtags(dlr)|indent(1) }}
|
38
|
+
{%- if dlr.admin_data is not none %}
|
39
|
+
{{ pad.printAdminData(dlr.admin_data) }}
|
40
|
+
{%- endif %}
|
41
|
+
{%- if dlr.company_datas %}
|
42
|
+
<COMPANY-DATAS>
|
43
|
+
{%- for cd in dlr.company_datas %}
|
44
|
+
{{ pcd.printCompanyData(cd) }}
|
45
|
+
{%- endfor %}
|
46
|
+
</COMPANY-DATAS>
|
47
|
+
{%- endif %}
|
48
|
+
{%- if dlr.functional_classes %}
|
49
|
+
<FUNCT-CLASSS>
|
50
|
+
{%- for fc in dlr.functional_classes %}
|
51
|
+
{{ pfc.printFunctionalClass(fc)|indent(3) }}
|
52
|
+
{%- endfor%}
|
53
|
+
</FUNCT-CLASSS>
|
54
|
+
{%- endif %}
|
55
|
+
{%- if dlr.diag_data_dictionary_spec is not none %}
|
56
|
+
{%- set ddds = dlr.diag_data_dictionary_spec %}
|
57
|
+
<DIAG-DATA-DICTIONARY-SPEC>
|
58
|
+
{%- if ddds.dtc_dops %}
|
59
|
+
<DTC-DOPS>
|
60
|
+
{%- for dop in ddds.dtc_dops -%}
|
61
|
+
{{ pdop.printDtcDop(dop)|indent(3) }}
|
62
|
+
{%- endfor %}
|
63
|
+
</DTC-DOPS>
|
64
|
+
{%- endif %}
|
65
|
+
{%- if ddds.env_data_descs %}
|
66
|
+
<ENV-DATA-DESCS>
|
67
|
+
{%- for env_data_desc in ddds.env_data_descs -%}
|
68
|
+
{{ pedd.printEnvDataDesc(env_data_desc)|indent(3) }}
|
69
|
+
{%- endfor %}
|
70
|
+
</ENV-DATA-DESCS>
|
71
|
+
{%- endif %}
|
72
|
+
{%- if ddds.data_object_props %}
|
73
|
+
<DATA-OBJECT-PROPS>
|
74
|
+
{%- for dop in ddds.data_object_props %}
|
75
|
+
{{- pdop.printDataObjectProp(dop)|indent(3) }}
|
76
|
+
{%- endfor %}
|
77
|
+
</DATA-OBJECT-PROPS>
|
78
|
+
{%- endif %}
|
79
|
+
{%- if ddds.structures %}
|
80
|
+
<STRUCTURES>
|
81
|
+
{%- for st in ddds.structures %}
|
82
|
+
{{ pst.printStructure(st)|indent(3) }}
|
83
|
+
{%- endfor %}
|
84
|
+
</STRUCTURES>
|
85
|
+
{%- endif %}
|
86
|
+
{%- if ddds.static_fields %}
|
87
|
+
<STATIC-FIELDS>
|
88
|
+
{%- for sf in ddds.static_fields %}
|
89
|
+
{{ psf.printStaticField(sf)|indent(3) }}
|
90
|
+
{%- endfor %}
|
91
|
+
</STATIC-FIELDS>
|
92
|
+
{%- endif %}
|
93
|
+
{%- if ddds.dynamic_length_fields %}
|
94
|
+
<DYNAMIC-LENGTH-FIELDS>
|
95
|
+
{%- for dlf in ddds.dynamic_length_fields %}
|
96
|
+
{{ pdlf.printDynamicLengthField(dlf)|indent(3) }}
|
97
|
+
{%- endfor %}
|
98
|
+
</DYNAMIC-LENGTH-FIELDS>
|
99
|
+
{%- endif %}
|
100
|
+
{%- if ddds.dynamic_endmarker_fields %}
|
101
|
+
<DYNAMIC-ENDMARKER-FIELDS>
|
102
|
+
{%- for demf in ddds.dynamic_endmarker_fields %}
|
103
|
+
{{ pdemf.printDynamicEndmarkerField(demf)|indent(3) }}
|
104
|
+
{%- endfor %}
|
105
|
+
</DYNAMIC-ENDMARKER-FIELDS>
|
106
|
+
{%- endif %}
|
107
|
+
{%- if ddds.end_of_pdu_fields %}
|
108
|
+
<END-OF-PDU-FIELDS>
|
109
|
+
{%- for eopdu in ddds.end_of_pdu_fields %}
|
110
|
+
{{ peopdu.printEndOfPdu(eopdu)|indent(3) }}
|
111
|
+
{%- endfor %}
|
112
|
+
</END-OF-PDU-FIELDS>
|
113
|
+
{%- endif %}
|
114
|
+
{%- if ddds.muxs %}
|
115
|
+
<MUXS>
|
116
|
+
{%- for mux in ddds.muxs %}
|
117
|
+
{{ pm.printMux(mux)|indent(3) }}
|
118
|
+
{%- endfor %}
|
119
|
+
</MUXS>
|
120
|
+
{%- endif %}
|
121
|
+
{%- if ddds.env_datas %}
|
122
|
+
<ENV-DATAS>
|
123
|
+
{%- for env_data in ddds.env_datas %}
|
124
|
+
{{ ped.printEnvData(env_data)|indent(3) }}
|
125
|
+
{%- endfor %}
|
126
|
+
</ENV-DATAS>
|
127
|
+
{%- endif %}
|
128
|
+
{%- if ddds.unit_spec %}
|
129
|
+
{{ punit.printUnitSpec(ddds.unit_spec)|indent(2) }}
|
130
|
+
{%- endif %}
|
131
|
+
{%- if ddds.tables %}
|
132
|
+
<TABLES>
|
133
|
+
{%- for table in ddds.tables -%}
|
134
|
+
{{ pt.printTable(table)|indent(3) }}
|
135
|
+
{%- endfor %}
|
136
|
+
</TABLES>
|
137
|
+
{{- psd.printSpecialDataGroups(ddds.sdgs)|indent(2, first=True) }}
|
138
|
+
{%- endif %}
|
139
|
+
</DIAG-DATA-DICTIONARY-SPEC>
|
140
|
+
{%- endif %}
|
141
|
+
{%- if dlr.diag_comms_raw %}
|
142
|
+
<DIAG-COMMS>
|
143
|
+
{%- for dc in dlr.diag_comms_raw %}
|
144
|
+
|
145
|
+
{#- use some serious duck typing to determine the kind of diag-comm
|
146
|
+
#- object. this would not be necessary if something like
|
147
|
+
#- isinstance() was available in jinja...
|
148
|
+
#}
|
149
|
+
|
150
|
+
{%- if hasattr(dc, "ref_id") %}
|
151
|
+
{#- -> reference to a diag-comm object #}
|
152
|
+
<DIAG-COMM-REF ID-REF="{{dc.ref_id}}" />
|
153
|
+
{%- elif hasattr(dc, "request") %}
|
154
|
+
{#- -> service #}
|
155
|
+
{{ ps.printService(dc)|indent(2) }}
|
156
|
+
{%- elif hasattr(dc, "prog_codes") %}
|
157
|
+
{#- -> single-ECU job #}
|
158
|
+
{{ psej.printSingleEcuJob(dc)|indent(2) }}
|
159
|
+
{%- else %}
|
160
|
+
<!-- Error: database contains an unrecognized DIAG-COMM. -->
|
161
|
+
{%- endif %}
|
162
|
+
{%- endfor %}
|
163
|
+
</DIAG-COMMS>
|
164
|
+
{%- endif %}
|
165
|
+
{%- if dlr.requests %}
|
166
|
+
<REQUESTS>
|
167
|
+
{%- for req in dlr.requests %}
|
168
|
+
{{ prq.printRequest(req)|indent(2) }}
|
169
|
+
{%- endfor %}
|
170
|
+
</REQUESTS>
|
171
|
+
{%- endif %}
|
172
|
+
{%- if dlr.positive_responses %}
|
173
|
+
<POS-RESPONSES>
|
174
|
+
{%- for resp in dlr.positive_responses %}
|
175
|
+
{{ presp.printResponse(resp, "POS-RESPONSE")|indent(2) }}
|
176
|
+
{%- endfor %}
|
177
|
+
</POS-RESPONSES>
|
178
|
+
{%- endif %}
|
179
|
+
{%- if dlr.negative_responses %}
|
180
|
+
<NEG-RESPONSES>
|
181
|
+
{%- for resp in dlr.negative_responses %}
|
182
|
+
{{ presp.printResponse(resp, "NEG-RESPONSE")|indent(2) }}
|
183
|
+
{%- endfor %}
|
184
|
+
</NEG-RESPONSES>
|
185
|
+
{%- endif %}
|
186
|
+
{%- if dlr.global_negative_responses %}
|
187
|
+
<GLOBAL-NEG-RESPONSES>
|
188
|
+
{%- for resp in dlr.global_negative_responses %}
|
189
|
+
{{ presp.printResponse(resp, "GLOBAL-NEG-RESPONSE")|indent(2) }}
|
190
|
+
{%- endfor %}
|
191
|
+
</GLOBAL-NEG-RESPONSES>
|
192
|
+
{%- endif %}
|
193
|
+
{%- if dlr.state_charts %}
|
194
|
+
<STATE-CHARTS>
|
195
|
+
{%- for sc in dlr.state_charts %}
|
196
|
+
{{ psc.printStateChart(sc) }}
|
197
|
+
{%- endfor %}
|
198
|
+
</STATE-CHARTS>
|
199
|
+
{%- endif %}
|
200
|
+
{%- if dlr.additional_audiences %}
|
201
|
+
<ADDITIONAL-AUDIENCES>
|
202
|
+
{%- for audience in dlr.additional_audiences %}
|
203
|
+
{{ paud.printAdditionalAudience(audience)|indent(2) }}
|
204
|
+
{%- endfor %}
|
205
|
+
</ADDITIONAL-AUDIENCES>
|
206
|
+
{%- endif %}
|
207
|
+
{%- if dlr.sub_components %}
|
208
|
+
<SUB-COMPONENTS>
|
209
|
+
{%- for sc in dlr.sub_components %}
|
210
|
+
{{ psubcomp.printSubComponent(sc)|indent(2) }}
|
211
|
+
{%- endfor %}
|
212
|
+
</SUB-COMPONENTS>
|
213
|
+
{%- endif %}
|
214
|
+
{%- if dlr.libraries %}
|
215
|
+
<LIBRARYS>
|
216
|
+
{%- for lib in dlr.libraries %}
|
217
|
+
{{ plib.printLibrary(lib)|indent(2) }}
|
218
|
+
{%- endfor %}
|
219
|
+
</LIBRARYS>
|
220
|
+
{%- endif %}
|
221
|
+
{{- psd.printSpecialDataGroups(dlr.sdgs)|indent(0, first=True) }}
|
222
|
+
{%- endmacro -%}
|
@@ -0,0 +1,66 @@
|
|
1
|
+
{#- -*- mode: sgml; tab-width: 2; indent-tabs-mode: nil -*-
|
2
|
+
#
|
3
|
+
# SPDX-License-Identifier: MIT
|
4
|
+
-#}
|
5
|
+
{%- import('macros/printElementId.xml.jinja2') as peid %}
|
6
|
+
{%- import('macros/printAdminData.xml.jinja2') as pad %}
|
7
|
+
{%- import('macros/printDescription.xml.jinja2') as pd %}
|
8
|
+
|
9
|
+
{%- macro printDiagVariable(diag_var) -%}
|
10
|
+
<DIAG-VARIABLE {{-peid.printElementIdAttribs(diag_var)}}>
|
11
|
+
{{ peid.printElementIdSubtags(diag_variable)|indent(2) }}
|
12
|
+
{%- if diag_variable.admin_data is not none %}
|
13
|
+
{{ pad.printAdminData(diag_variable.admin_data)|indent(2) }}
|
14
|
+
{%- endif %}
|
15
|
+
<VARIABLE-GROUP-REF ID-REF="{{ diag_var.ref_id }}" />
|
16
|
+
{%- if diag_variable.sw_variables %}
|
17
|
+
<SW-VARIABLES>
|
18
|
+
{%- for sw_var in diag_variable.sw_variables %}
|
19
|
+
<SW-VARIABLE {{-peid.printElementIdAttribs(sw_var)}}>
|
20
|
+
{{ peid.printElementIdSubtags(sw_var)|indent(6) }}
|
21
|
+
{%- if sw_var.origin is not none %}
|
22
|
+
<ORIGIN>{{ sw_var.origin }}</ORIGIN>
|
23
|
+
{%- endif %}
|
24
|
+
</SW-VARIABLE>
|
25
|
+
{%- endfor %}
|
26
|
+
</SW-VARIABLES>
|
27
|
+
{%- endif %}
|
28
|
+
{%- if diag_variable.comm_relations %}
|
29
|
+
<COMM-RELATIONS>
|
30
|
+
{%- for comm_relation in diag_variable.comm_relations %}
|
31
|
+
<COMM-RELATION>
|
32
|
+
{{ pd.printDescription(comm_relation.description) }}
|
33
|
+
<RELATION-TYPE>{{comm_relation.relation_type}}</RELATION-TYPE>
|
34
|
+
{%- if comm_relation.diag_comm_ref is not none %}
|
35
|
+
<DIAG-COMM-REF ID-REF="{{comm_relation.diag_comm_ref.ref_id}}" />
|
36
|
+
{%- endif %}
|
37
|
+
{%- if comm_relation.diag_comm_snref is not none %}
|
38
|
+
<DIAG-COMM-SNREF SHORT-NAME="{{comm_relation.diag_comm_snref}}" />
|
39
|
+
{%- endif %}
|
40
|
+
{%- if comm_relation.in_param_if_ref is not none %}
|
41
|
+
<IN-PARAM-IF-REF ID-REF="{{comm_relation.in_param_if_ref.ref_id}}" />
|
42
|
+
{%- endif %}
|
43
|
+
{%- if comm_relation.in_param_if_snref is not none %}
|
44
|
+
<IN-PARAM-IF-SNREF SHORT-NAME="{{comm_relation.in_param_if_snref}}" />
|
45
|
+
{%- endif %}
|
46
|
+
{%- if comm_relation.out_param_if_ref is not none %}
|
47
|
+
<OUT-PARAM-IF-REF ID-REF="{{comm_relation.out_param_if_ref.ref_id}}" />
|
48
|
+
{%- endif %}
|
49
|
+
{%- if comm_relation.out_param_if_snref is not none %}
|
50
|
+
<OUT-PARAM-IF-SNREF SHORT-NAME="{{comm_relation.out_param_if_snref}}" />
|
51
|
+
{%- endif %}
|
52
|
+
{%- if comm_relation.value_type_raw is not none %}
|
53
|
+
<VALUE-TYPE>{{comm_relation.value_type_raw.value}}</VALUE-TYPE>
|
54
|
+
{%- endif %}
|
55
|
+
<COMM-RELATION>
|
56
|
+
{%- endfor %}
|
57
|
+
</COMM-RELATIONS>
|
58
|
+
{%- endif %}
|
59
|
+
</DIAG-VARIABLE>
|
60
|
+
{%- endmacro -%}
|
61
|
+
|
62
|
+
{%- macro printVariableGroup(var_group) -%}
|
63
|
+
<VARIABLE-GROUP {{-peid.printElementIdAttribs(var_group)}}>
|
64
|
+
{{ peid.printElementIdSubtags(diag_variable)|indent(2) }}
|
65
|
+
</VARIABLE-GROUP>
|
66
|
+
{%- endmacro -%}
|
@@ -0,0 +1,48 @@
|
|
1
|
+
{#- -*- mode: sgml; tab-width: 2; indent-tabs-mode: nil -*-
|
2
|
+
#
|
3
|
+
# SPDX-License-Identifier: MIT
|
4
|
+
-#}
|
5
|
+
|
6
|
+
{%- macro printDynDefinedSpec(dd_spec) -%}
|
7
|
+
<DYN-DEFINED-SPEC>
|
8
|
+
{%- if dd_spec.dyn_id_def_mode_infos %}
|
9
|
+
<DYN-ID-DEF-MODE-INFOS>
|
10
|
+
{%- for diddmi in dd_spec.dyn_id_def_mode_infos %}
|
11
|
+
<DYN-ID-DEF-MODE-INFO>
|
12
|
+
<DEF-MODE>{{ diddmi.def_mode }}</DEF-MODE>
|
13
|
+
{%- if diddmi.clear_dyn_def_message_ref is not none %}
|
14
|
+
<CLEAR-DYN-DEF-MESSAGE-REF ID-REF="{{diddmi.clear_dyn_def_message_ref.ref_id}}" />
|
15
|
+
{%- endif %}
|
16
|
+
{%- if diddmi.clear_dyn_def_message_snref is not none %}
|
17
|
+
<CLEAR-DYN-DEF-MESSAGE-SNREF SHORT-NAME="{{diddmi.clear_dyn_def_message_snref}}" />
|
18
|
+
{%- endif %}
|
19
|
+
{%- if diddmi.read_dyn_def_message_ref is not none %}
|
20
|
+
<READ-DYN-DEF-MESSAGE-REF ID-REF="{{diddmi.read_dyn_def_message_ref.ref_id}}" />
|
21
|
+
{%- endif %}
|
22
|
+
{%- if diddmi.read_dyn_def_message_snref is not none %}
|
23
|
+
<READ-DYN-DEF-MESSAGE-SNREF SHORT-NAME="{{diddmi.read_dyn_def_message_snref}}" />
|
24
|
+
{%- endif %}
|
25
|
+
{%- if diddmi.supported_dyn_ids %}
|
26
|
+
<SUPPORTED-DYN-IDS>
|
27
|
+
{%- for dynid in diddmi.supported_dyn_ids %}
|
28
|
+
<SUPPORTED-DYN-ID>{{ dynid.hex() }}</SUPPORTED-DYN-ID>
|
29
|
+
{%- endfor %}
|
30
|
+
</SUPPORTED-DYN-IDS>
|
31
|
+
{%- endif %}
|
32
|
+
{%- if diddmi.selection_table_refs %}
|
33
|
+
<SELECTION-TABLE-REFS>
|
34
|
+
{%- for seltref in diddmi.selection_table_refs %}
|
35
|
+
{%- if hasattr(seltref, "ref_id") %}
|
36
|
+
<SELECTION-TABLE-REF ID-REF="{{ seltref.ref_id }}" />
|
37
|
+
{%- else %}
|
38
|
+
<SELECTION-TABLE-SNREF SHORT-NAME="{{ seltref }}" />
|
39
|
+
{%- endif %}
|
40
|
+
{%- endfor %}
|
41
|
+
</SELECTION-TABLE-REFS>
|
42
|
+
{%- endif %}
|
43
|
+
</DYN-ID-DEF-MODE-INFO>
|
44
|
+
{%- endfor %}
|
45
|
+
</DYN-ID-DEF-MODE-INFOS>
|
46
|
+
{%- endif %}
|
47
|
+
</DYN-DEFINED-SPEC>
|
48
|
+
{%- endmacro -%}
|
@@ -0,0 +1,16 @@
|
|
1
|
+
{#- -*- mode: sgml; tab-width: 1; indent-tabs-mode: nil -*-
|
2
|
+
#
|
3
|
+
# SPDX-License-Identifier: MIT
|
4
|
+
-#}
|
5
|
+
|
6
|
+
{%- import('macros/printElementId.xml.jinja2') as peid %}
|
7
|
+
|
8
|
+
{%- macro printStaticField(demf) -%}
|
9
|
+
<DYNAMIC-ENDMARKER-FIELD {{-peid.printElementIdAttribs(demf)}}>
|
10
|
+
{{ peid.printElementIdSubtags(demf)|indent(1) }}
|
11
|
+
<BASIC-STRUCTURE-REF ID-REF="{{demf.structure_ref.ref_id}}" />
|
12
|
+
<DYN-END-DOP-REF ID-REF="{{demf.dyn_end_dop_ref.ref_id}}">
|
13
|
+
<TERMINATION-VALUE>{{demf.dyn_end_dop_ref.termination_value_raw}}</TERMINATION-VALUE>
|
14
|
+
</DYN-END-DOP-REF>
|
15
|
+
</DYNAMIC-ENDMARKER-FIELD>
|
16
|
+
{%- endmacro -%}
|
@@ -6,7 +6,7 @@
|
|
6
6
|
{%- import('macros/printElementId.xml.jinja2') as peid %}
|
7
7
|
|
8
8
|
{%- macro printDynamicLengthField(dlf) -%}
|
9
|
-
<DYNAMIC-LENGTH-FIELD
|
9
|
+
<DYNAMIC-LENGTH-FIELD {{-peid.printElementIdAttribs(dlf)}}>
|
10
10
|
{{ peid.printElementIdSubtags(dlf)|indent(1) }}
|
11
11
|
<BASIC-STRUCTURE-REF ID-REF="{{dlf.structure_ref.ref_id}}" />
|
12
12
|
<OFFSET>{{dlf.offset}}</OFFSET>
|
@@ -0,0 +1,30 @@
|
|
1
|
+
{#- -*- mode: sgml; tab-width: 2; indent-tabs-mode: nil -*-
|
2
|
+
#
|
3
|
+
# SPDX-License-Identifier: MIT
|
4
|
+
-#}
|
5
|
+
|
6
|
+
{%- import('macros/printDiagLayer.xml.jinja2') as pdl %}
|
7
|
+
|
8
|
+
{%- macro printEcuSharedData(ecu_shared_data) -%}
|
9
|
+
<ECU-SHARED-DATA {{- pdl.printDiagLayerAttribs(ecu_shared_data) -}}>
|
10
|
+
{{ pdl.printDiagLayerSubtags(ecu_shared_data) | indent(2) }}
|
11
|
+
{%- set dlr = ecu_shared_data.ecu_shared_data_raw %}
|
12
|
+
|
13
|
+
{%- if dlr.diag_variables %}
|
14
|
+
<DIAG-VARIABLES>
|
15
|
+
{%- for dv in dlr.diag_variables -%}
|
16
|
+
{{ pdv.printDiagVariable(dv)|indent(4) }}
|
17
|
+
{%- endfor -%}
|
18
|
+
</DIAG-VARIABLES>
|
19
|
+
{%- endif %}
|
20
|
+
|
21
|
+
{%- if dlr.variable_groups %}
|
22
|
+
<VARIABLE-GROUPS>
|
23
|
+
{%- for vg in dlr.variable_groups -%}
|
24
|
+
{{ pdv.printVariableGroup(vg)|indent(4) }}
|
25
|
+
{%- endfor -%}
|
26
|
+
</VARIABLE-GROUPS>
|
27
|
+
{%- endif %}
|
28
|
+
|
29
|
+
</ECU-SHARED-DATA>
|
30
|
+
{%- endmacro %}
|
@@ -0,0 +1,53 @@
|
|
1
|
+
{#- -*- mode: sgml; tab-width: 2; indent-tabs-mode: nil -*-
|
2
|
+
#
|
3
|
+
# SPDX-License-Identifier: MIT
|
4
|
+
-#}
|
5
|
+
|
6
|
+
{%- import('macros/printHierarchyElement.xml.jinja2') as phe %}
|
7
|
+
{%- import('macros/printComparamRef.xml.jinja2') as pcom %}
|
8
|
+
{%- import('macros/printParentRef.xml.jinja2') as pparref %}
|
9
|
+
{%- import('macros/printEcuVariantPattern.xml.jinja2') as pvpat %}
|
10
|
+
{%- import('macros/printDynDefinedSpec.xml.jinja2') as pdynspec %}
|
11
|
+
|
12
|
+
{%- macro printEcuVariant(ecu_variant) -%}
|
13
|
+
<ECU-VARIANT {{- phe.printHierarchyElementAttribs(ecu_variant) -}}>
|
14
|
+
{{ phe.printHierarchyElementSubtags(ecu_variant) | indent(2) }}
|
15
|
+
{%- set dlr = ecu_variant.diag_layer_raw %}
|
16
|
+
|
17
|
+
{%- if dlr.diag_variables %}
|
18
|
+
<DIAG-VARIABLES>
|
19
|
+
{%- for dv in dlr.diag_variables -%}
|
20
|
+
{{ pdv.printDiagVariable(dv)|indent(4) }}
|
21
|
+
{%- endfor -%}
|
22
|
+
</DIAG-VARIABLES>
|
23
|
+
{%- endif %}
|
24
|
+
|
25
|
+
{%- if dlr.variable_groups %}
|
26
|
+
<VARIABLE-GROUPS>
|
27
|
+
{%- for vg in dlr.variable_groups -%}
|
28
|
+
{{ pdv.printVariableGroup(vg)|indent(4) }}
|
29
|
+
{%- endfor -%}
|
30
|
+
</VARIABLE-GROUPS>
|
31
|
+
{%- endif %}
|
32
|
+
|
33
|
+
{%- if dlr.dyn_defined_spec %}
|
34
|
+
{{ pdynspec.printPrintDefinedSpec(dlr.dyn_defined_spec)|indent(4) }}
|
35
|
+
{%- endif %}
|
36
|
+
|
37
|
+
{%- if dlr.ecu_variant_patterns %}
|
38
|
+
<ECU-VARIANT-PATTERNS>
|
39
|
+
{%- for vp in dlr.ecu_variant_patterns -%}
|
40
|
+
{{ pvpat.printEcuVariantPattern(vp)|indent(4) }}
|
41
|
+
{%- endfor -%}
|
42
|
+
</ECU-VARIANT-PATTERNS>
|
43
|
+
{%- endif %}
|
44
|
+
|
45
|
+
{%- if dlr.parent_refs %}
|
46
|
+
<PARENT-REFS>
|
47
|
+
{%- for parent in dlr.parent_refs -%}
|
48
|
+
{{ pparref.printParentRef(parent)|indent(4) }}
|
49
|
+
{%- endfor %}
|
50
|
+
</PARENT-REFS>
|
51
|
+
{%- endif %}
|
52
|
+
</ECU-VARIANT>
|
53
|
+
{%- endmacro %}
|
@@ -9,7 +9,7 @@
|
|
9
9
|
|
10
10
|
{%- macro printMatchingParameter(mp) -%}
|
11
11
|
<MATCHING-PARAMETER>
|
12
|
-
<EXPECTED-VALUE>{{mp.expected_value}}</EXPECTED-VALUE>
|
12
|
+
<EXPECTED-VALUE>{{mp.expected_value | e}}</EXPECTED-VALUE>
|
13
13
|
<DIAG-COMM-SNREF SHORT-NAME="{{mp.diag_comm_snref}}" />
|
14
14
|
{#- TODO: OUT-PARAM-IF-SNPATHREF #}
|
15
15
|
<OUT-PARAM-IF-SNREF SHORT-NAME="{{mp.out_param_if}}" />
|
@@ -3,12 +3,17 @@
|
|
3
3
|
# SPDX-License-Identifier: MIT
|
4
4
|
-#}
|
5
5
|
|
6
|
+
{%- import('macros/printDescription.xml.jinja2') as pd %}
|
7
|
+
|
8
|
+
{%- macro printElementIdAttribs(obj) -%}
|
9
|
+
{#- #} {{- make_xml_attrib("ID", obj.odx_id.local_id) }}
|
10
|
+
{#- #} {{- make_xml_attrib("OID", getattr(obj, "oid", none)) -}}
|
11
|
+
{%- endmacro -%}
|
12
|
+
|
6
13
|
{%- macro printElementIdSubtags(obj) -%}
|
7
14
|
<SHORT-NAME>{{ obj.short_name }}</SHORT-NAME>
|
8
15
|
{%- if obj.long_name %}
|
9
16
|
<LONG-NAME>{{ obj.long_name|e }}</LONG-NAME>
|
10
17
|
{%- endif %}
|
11
|
-
{
|
12
|
-
<DESC>{{ obj.description }}</DESC>
|
13
|
-
{%- endif %}
|
18
|
+
{{- pd.printDescription(obj.description) }}
|
14
19
|
{%- endmacro -%}
|
@@ -6,7 +6,7 @@
|
|
6
6
|
{%- import('macros/printElementId.xml.jinja2') as peid %}
|
7
7
|
|
8
8
|
{%- macro printEndOfPdu(eopdu) -%}
|
9
|
-
<END-OF-PDU-FIELD
|
9
|
+
<END-OF-PDU-FIELD {{-peid.printElementIdAttribs(eopdu)}}>
|
10
10
|
{{ peid.printElementIdSubtags(eopdu)|indent(1) }}
|
11
11
|
<BASIC-STRUCTURE-REF ID-REF="{{eopdu.structure_ref.ref_id}}" />
|
12
12
|
{%- if eopdu.max_number_of_items is not none %}
|
@@ -6,7 +6,7 @@
|
|
6
6
|
{%- import('macros/printElementId.xml.jinja2') as peid %}
|
7
7
|
|
8
8
|
{%- macro printEnvDataDesc(env_data_desc) %}
|
9
|
-
<ENV-DATA-DESC
|
9
|
+
<ENV-DATA-DESC {{-peid.printElementIdAttribs(env_data_desc)}}>
|
10
10
|
{{ peid.printElementIdSubtags(env_data_desc)|indent(1) }}
|
11
11
|
<PARAM-SNREF SHORT-NAME="{{env_data_desc.param_snref}}"/>
|
12
12
|
<ENV-DATA-REFS>
|
@@ -7,7 +7,7 @@
|
|
7
7
|
{%- import('macros/printElementId.xml.jinja2') as peid %}
|
8
8
|
|
9
9
|
{%- macro printFunctionalClass(fc) -%}
|
10
|
-
<FUNCT-CLASS
|
10
|
+
<FUNCT-CLASS {{-peid.printElementIdAttribs(fc)}}>
|
11
11
|
{{ peid.printElementIdSubtags(fc)|indent(1) }}
|
12
12
|
</FUNCT-CLASS>
|
13
13
|
{%- endmacro -%}
|
@@ -0,0 +1,40 @@
|
|
1
|
+
{#- -*- mode: sgml; tab-width: 2; indent-tabs-mode: nil -*-
|
2
|
+
#
|
3
|
+
# SPDX-License-Identifier: MIT
|
4
|
+
-#}
|
5
|
+
|
6
|
+
{%- import('macros/printHierarchyElement.xml.jinja2') as phe %}
|
7
|
+
{%- import('macros/printComparamRef.xml.jinja2') as pcom %}
|
8
|
+
{%- import('macros/printParentRef.xml.jinja2') as pparref %}
|
9
|
+
|
10
|
+
{%- macro printFunctionalGroup(functional_group) -%}
|
11
|
+
<FUNCTIONAL-GROUP {{- phe.printHierarchyElementAttribs(functional_group) -}}>
|
12
|
+
{{ phe.printHierarchyElementSubtags(functional_group) | indent(2) }}
|
13
|
+
|
14
|
+
{%- set dlr = functional_group.functional_group_raw %}
|
15
|
+
|
16
|
+
{%- if dlr.diag_variables %}
|
17
|
+
<DIAG-VARIABLES>
|
18
|
+
{%- for dv in dlr.diag_variables -%}
|
19
|
+
{{ pdv.printDiagVariable(dv)|indent(4) }}
|
20
|
+
{%- endfor -%}
|
21
|
+
</DIAG-VARIABLES>
|
22
|
+
{%- endif %}
|
23
|
+
|
24
|
+
{%- if dlr.variable_groups %}
|
25
|
+
<VARIABLE-GROUPS>
|
26
|
+
{%- for vg in dlr.variable_groups -%}
|
27
|
+
{{ pdv.printVariableGroup(vg)|indent(4) }}
|
28
|
+
{%- endfor -%}
|
29
|
+
</VARIABLE-GROUPS>
|
30
|
+
{%- endif %}
|
31
|
+
|
32
|
+
{%- if dlr.parent_refs %}
|
33
|
+
<PARENT-REFS>
|
34
|
+
{%- for parent in dlr.parent_refs -%}
|
35
|
+
{{ pparref.printParentRef(parent)|indent(4) }}
|
36
|
+
{%- endfor %}
|
37
|
+
</PARENT-REFS>
|
38
|
+
{%- endif %}
|
39
|
+
</FUNCTIONAL-GROUP>
|
40
|
+
{%- endmacro %}
|
@@ -0,0 +1,24 @@
|
|
1
|
+
{#- -*- mode: sgml; tab-width: 1; indent-tabs-mode: nil -*-
|
2
|
+
#
|
3
|
+
# SPDX-License-Identifier: MIT
|
4
|
+
-#}
|
5
|
+
|
6
|
+
{%- import('macros/printDiagLayer.xml.jinja2') as pdl %}
|
7
|
+
{%- import('macros/printComparamRef.xml.jinja2') as pcom %}
|
8
|
+
|
9
|
+
{%- macro printHierarchyElementAttribs(helem) -%}
|
10
|
+
{{- pdl.printDiagLayerAttribs(helem) -}}
|
11
|
+
{%- endmacro -%}
|
12
|
+
|
13
|
+
{%- macro printHierarchyElementSubtags(helem) -%}
|
14
|
+
{%- set dlr = helem.hierarchy_element_raw %}
|
15
|
+
{{- pdl.printDiagLayerSubtags(helem) }}
|
16
|
+
{%- if dlr.comparam_refs %}
|
17
|
+
<COMPARAM-REFS>
|
18
|
+
{%- for cp in dlr.comparam_refs -%}
|
19
|
+
{{ pcom.printComparamRef(cp)|indent(2) }}
|
20
|
+
{%- endfor %}
|
21
|
+
</COMPARAM-REFS>
|
22
|
+
{%- endif %}
|
23
|
+
|
24
|
+
{%- endmacro %}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
{#- -*- mode: sgml; tab-width: 1; indent-tabs-mode: nil -*-
|
2
|
+
#
|
3
|
+
# SPDX-License-Identifier: MIT
|
4
|
+
-#}
|
5
|
+
|
6
|
+
{%- import('macros/printElementId.xml.jinja2') as peid %}
|
7
|
+
|
8
|
+
{%- macro printLibrary(library) %}
|
9
|
+
<LIBRARY{#- #} {{-peid.printElementIdAttribs(library)}}{# -#}>
|
10
|
+
{{ peid.printElementIdSubtags(library)|indent(1) }}
|
11
|
+
<CODE-FILE>{{library.code_file}}</CODE-FILE>
|
12
|
+
{%- if library.encryption is not none %}
|
13
|
+
<ENCRYPTION>{{library.encryption}}</ENCRYPTION>
|
14
|
+
{%- endif %}
|
15
|
+
<SYNTAX>{{library.syntax}}</SYNTAX>
|
16
|
+
<REVISION>{{library.revision}}</REVISION>
|
17
|
+
{%- if library.entrypoint is not none %}
|
18
|
+
<ENTRYPOINT>{{library.entrypoint}}</ENTRYPOINT>
|
19
|
+
{%- endif %}
|
20
|
+
</LIBRARY>
|
21
|
+
{%- endmacro %}
|
@@ -4,10 +4,11 @@
|
|
4
4
|
-#}
|
5
5
|
|
6
6
|
{%- import('macros/printElementId.xml.jinja2') as peid %}
|
7
|
+
{%- import('macros/printCompuMethod.xml.jinja2') as pcm %}
|
7
8
|
{%- import('macros/printDOP.xml.jinja2') as pdop %}
|
8
9
|
|
9
10
|
{%- macro printMux(mux) %}
|
10
|
-
<MUX
|
11
|
+
<MUX {{-peid.printElementIdAttribs(mux)}}
|
11
12
|
{{-make_bool_xml_attrib("IS-VISIBLE", mux.is_visible_raw)}}
|
12
13
|
{#- #}>
|
13
14
|
{{ peid.printElementIdSubtags(mux)|indent(1) }}
|
@@ -41,8 +42,8 @@
|
|
41
42
|
{%- if case.structure_snref is not none %}
|
42
43
|
<STRUCTURE-SNREF SHORT_NAME="{{case.structure_snref}}"/>
|
43
44
|
{%- endif %}
|
44
|
-
{{
|
45
|
-
{{
|
45
|
+
{{ pcm.printLimit("LOWER-LIMIT", case.lower_limit) }}
|
46
|
+
{{ pcm.printLimit("UPPER-LIMIT", case.upper_limit) }}
|
46
47
|
</CASE>
|
47
48
|
{%- endfor %}
|
48
49
|
</CASES>
|
@@ -0,0 +1,28 @@
|
|
1
|
+
{#- -*- mode: sgml; tab-width: 1; indent-tabs-mode: nil -*-
|
2
|
+
#
|
3
|
+
# SPDX-License-Identifier: MIT
|
4
|
+
-#}
|
5
|
+
|
6
|
+
{%- import('macros/printElementId.xml.jinja2') as peid %}
|
7
|
+
{%- import('macros/printAdminData.xml.jinja2') as pad -%}
|
8
|
+
{%- import('macros/printCompanyData.xml.jinja2') as pcd -%}
|
9
|
+
{%- import('macros/printSpecialData.xml.jinja2') as psd %}
|
10
|
+
|
11
|
+
{%- macro printOdxCategoryAttribs(obj) -%}
|
12
|
+
{#- #} {{- peid.printElementIdAttribs(obj) }}
|
13
|
+
{%- endmacro -%}
|
14
|
+
|
15
|
+
{%- macro printOdxCategorySubtags(obj) -%}
|
16
|
+
{{ peid.printElementIdSubtags(obj) }}
|
17
|
+
{%- if obj.admin_data %}
|
18
|
+
{{pad.printAdminData(obj.admin_data)|indent(2)}}
|
19
|
+
{%- endif %}
|
20
|
+
{%- if obj.company_datas %}
|
21
|
+
<COMPANY-DATAS>
|
22
|
+
{%- for cd in obj.company_datas %}
|
23
|
+
{{pcd.printCompanyData(cd)|indent(3)}}
|
24
|
+
{%- endfor %}
|
25
|
+
</COMPANY-DATAS>
|
26
|
+
{%- endif %}
|
27
|
+
{{- psd.printSpecialDataGroups(obj.sdgs)|indent(2, first=True) }}
|
28
|
+
{%- endmacro -%}
|