armodel 1.4.3__py3-none-any.whl → 1.6.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.
- armodel/cli/arxml_dump_cli.py +14 -14
- armodel/cli/memory_section_cli.py +76 -0
- armodel/cli/system_signal_cli.py +74 -0
- armodel/lib/__init__.py +2 -1
- armodel/lib/system_signal.py +37 -0
- armodel/models/__init__.py +6 -3
- armodel/models/annotation.py +27 -3
- armodel/models/ar_object.py +18 -6
- armodel/models/ar_package.py +248 -30
- armodel/models/ar_ref.py +115 -45
- armodel/models/bsw_module_template.py +66 -28
- armodel/models/common_structure.py +150 -150
- armodel/models/communication.py +1 -1
- armodel/models/data_prototype.py +41 -6
- armodel/models/datatype.py +11 -5
- armodel/models/fibex/__init__.py +0 -0
- armodel/models/fibex/can_communication.py +122 -0
- armodel/models/fibex/fibex_4_can/__init__.py +0 -0
- armodel/models/fibex/fibex_4_lin/__init__.py +0 -0
- armodel/models/fibex/fibex_4_multiplatform.py +138 -0
- armodel/models/fibex/fibex_core/__init__.py +0 -0
- armodel/models/fibex/fibex_core/core_communication.py +627 -0
- armodel/models/fibex/fibex_core/core_topology.py +180 -0
- armodel/models/fibex/fibex_core.py +341 -0
- armodel/models/fibex/lin_communication.py +38 -0
- armodel/models/fibex/lin_topology.py +7 -0
- armodel/models/general_structure.py +119 -10
- armodel/models/implementation.py +4 -5
- armodel/models/internal_behavior.py +63 -0
- armodel/models/m2/__init__.py +0 -0
- armodel/models/m2/autosar_templates/__init__.py +0 -0
- armodel/models/m2/autosar_templates/common_structure/__init__.py +188 -0
- armodel/models/m2/autosar_templates/common_structure/constants.py +0 -0
- armodel/models/m2/autosar_templates/ecuc_description_template.py +268 -0
- armodel/models/m2/autosar_templates/sw_component_template/__init__.py +0 -0
- armodel/models/m2/autosar_templates/sw_component_template/communication.py +316 -0
- armodel/models/m2/autosar_templates/sw_component_template/components/__init__.py +0 -0
- armodel/models/m2/autosar_templates/sw_component_template/components/instance_refs.py +149 -0
- armodel/models/m2/autosar_templates/sw_component_template/port_interface.py +236 -0
- armodel/models/m2/autosar_templates/sw_component_template/swc_internal_behavior/__init__.py +203 -0
- armodel/models/m2/autosar_templates/sw_component_template/swc_internal_behavior/access_count.py +13 -0
- armodel/models/m2/autosar_templates/sw_component_template/swc_internal_behavior/data_elements.py +54 -0
- armodel/models/m2/autosar_templates/sw_component_template/swc_internal_behavior/mode_declaration_group.py +39 -0
- armodel/models/m2/autosar_templates/sw_component_template/swc_internal_behavior/server_call.py +26 -0
- armodel/models/m2/autosar_templates/sw_component_template/swc_internal_behavior/trigger.py +10 -0
- armodel/models/m2/autosar_templates/system_template/__init__.py +321 -0
- armodel/models/m2/autosar_templates/system_template/data_mapping.py +88 -0
- armodel/models/m2/autosar_templates/system_template/network_management.py +554 -0
- armodel/models/m2/autosar_templates/system_template/transport_protocols.py +7 -0
- armodel/models/m2/msr/__init__.py +0 -0
- armodel/models/m2/msr/asam_hdo/__init__.py +0 -0
- armodel/models/m2/msr/asam_hdo/units.py +105 -0
- armodel/models/m2/msr/data_dictionary/__init__.py +0 -0
- armodel/models/m2/msr/data_dictionary/auxillary_objects.py +42 -0
- armodel/models/m2/msr/data_dictionary/data_def_properties.py +295 -0
- armodel/models/m2/msr/documentation/__init__.py +0 -0
- armodel/models/m2/msr/documentation/block_elements.py +18 -0
- armodel/models/mode_declaration.py +8 -0
- armodel/models/multilanguage_data.py +15 -0
- armodel/models/per_instance_memory.py +34 -6
- armodel/models/port_prototype.py +15 -159
- armodel/models/rpt_scenario.py +20 -0
- armodel/models/sw_component.py +48 -187
- armodel/models/system_template/__init__.py +0 -0
- armodel/models/system_template/network_management.py +7 -0
- armodel/models/system_template/transport_protocols.py +7 -0
- armodel/models/timing.py +91 -0
- armodel/parser/abstract_arxml_parser.py +11 -2
- armodel/parser/arxml_parser.py +1101 -227
- armodel/tests/test_armodel/models/test_ar_package.py +1 -1
- armodel/tests/test_armodel/models/test_ar_ref.py +3 -3
- armodel/tests/test_armodel/models/test_bsw_module_template.py +5 -5
- armodel/tests/test_armodel/models/test_common_structure.py +3 -3
- armodel/tests/test_armodel/models/test_data_dictionary.py +5 -5
- armodel/tests/test_armodel/models/test_data_prototype.py +2 -2
- armodel/tests/test_armodel/models/test_datatype.py +8 -8
- armodel/tests/test_armodel/models/test_port_interface.py +6 -6
- armodel/tests/test_armodel/parser/test_parse_bswmd.py +16 -8
- armodel/tests/test_armodel/parser/test_sw_components.py +6 -6
- armodel/writer/arxml_writer.py +1046 -181
- {armodel-1.4.3.dist-info → armodel-1.6.0.dist-info}/METADATA +48 -1
- armodel-1.6.0.dist-info/RECORD +127 -0
- {armodel-1.4.3.dist-info → armodel-1.6.0.dist-info}/entry_points.txt +3 -1
- armodel-1.4.3.dist-info/RECORD +0 -78
- {armodel-1.4.3.dist-info → armodel-1.6.0.dist-info}/LICENSE +0 -0
- {armodel-1.4.3.dist-info → armodel-1.6.0.dist-info}/WHEEL +0 -0
- {armodel-1.4.3.dist-info → armodel-1.6.0.dist-info}/top_level.txt +0 -0
armodel/models/datatype.py
CHANGED
|
@@ -4,9 +4,8 @@ from typing import List
|
|
|
4
4
|
from .ar_object import ARLiteral, ARNumerical
|
|
5
5
|
from .ar_ref import RefType
|
|
6
6
|
from .ar_package import Referrable
|
|
7
|
-
from .general_structure import ARElement, ARObject
|
|
7
|
+
from .general_structure import ARElement, ARObject
|
|
8
8
|
from .data_prototype import ApplicationCompositeElementDataPrototype, ApplicationRecordElement
|
|
9
|
-
from .data_dictionary import SwDataDefProps
|
|
10
9
|
from .common_structure import ImplementationDataTypeElement, ModeRequestTypeMap
|
|
11
10
|
|
|
12
11
|
class ImplementationProps(Referrable, metaclass=ABCMeta):
|
|
@@ -56,16 +55,23 @@ class AtpType(ARElement, metaclass=ABCMeta):
|
|
|
56
55
|
super().__init__(parent, short_name)
|
|
57
56
|
|
|
58
57
|
|
|
59
|
-
class AutosarDataType(AtpType, metaclass=ABCMeta):
|
|
58
|
+
class AutosarDataType(AtpType, metaclass = ABCMeta):
|
|
60
59
|
def __init__(self, parent: ARObject, short_name: str):
|
|
61
60
|
if type(self) == AutosarDataType:
|
|
62
61
|
raise NotImplementedError("AutosarDataType is an abstract class.")
|
|
63
62
|
|
|
64
63
|
super().__init__(parent, short_name)
|
|
65
|
-
self.sw_data_def_props = None # type: SwDataDefProps
|
|
66
64
|
|
|
65
|
+
self.swDataDefProps = None # type: SwDataDefProps
|
|
67
66
|
|
|
68
|
-
|
|
67
|
+
def getSwDataDefProps(self):
|
|
68
|
+
return self.swDataDefProps
|
|
69
|
+
|
|
70
|
+
def setSwDataDefProps(self, value):
|
|
71
|
+
self.swDataDefProps = value
|
|
72
|
+
return self
|
|
73
|
+
|
|
74
|
+
class ApplicationDataType(AutosarDataType, metaclass = ABCMeta):
|
|
69
75
|
def __init__(self, parent: ARObject, short_name: str):
|
|
70
76
|
if type(self) == ApplicationDataType:
|
|
71
77
|
raise NotImplementedError("ApplicationDataType is an abstract class.")
|
|
File without changes
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
from ..general_structure import Identifiable
|
|
2
|
+
from ..ar_object import ARObject, ARPositiveInteger
|
|
3
|
+
from .fibex_core.core_communication import Frame, FrameTriggering
|
|
4
|
+
|
|
5
|
+
class RxIdentifierRange(ARObject):
|
|
6
|
+
def __init__(self):
|
|
7
|
+
super().__init__()
|
|
8
|
+
|
|
9
|
+
self.lowerCanId = None # type: ARPositiveInteger
|
|
10
|
+
self.upperCanId = None # type: ARPositiveInteger
|
|
11
|
+
|
|
12
|
+
def getLowerCanId(self) -> ARPositiveInteger:
|
|
13
|
+
return self.lowerCanId
|
|
14
|
+
|
|
15
|
+
def setLowerCanId(self, value: ARPositiveInteger):
|
|
16
|
+
self.lowerCanId = value
|
|
17
|
+
return self
|
|
18
|
+
|
|
19
|
+
def getUpperCanId(self) -> ARPositiveInteger:
|
|
20
|
+
return self.upperCanId
|
|
21
|
+
|
|
22
|
+
def setUpperCanId(self, value: ARPositiveInteger):
|
|
23
|
+
self.upperCanId = value
|
|
24
|
+
return self
|
|
25
|
+
|
|
26
|
+
class CanFrame(Frame):
|
|
27
|
+
def __init__(self, parent: ARObject, short_name: str):
|
|
28
|
+
super().__init__(parent, short_name)
|
|
29
|
+
|
|
30
|
+
class CanFrameTriggering(FrameTriggering):
|
|
31
|
+
def __init__(self, parent, short_name):
|
|
32
|
+
super().__init__(parent, short_name)
|
|
33
|
+
|
|
34
|
+
self.absolutelyScheduledTimings = []
|
|
35
|
+
self.canAddressingMode = None
|
|
36
|
+
self.canFdFrameSupport = None
|
|
37
|
+
self.canFrameRxBehavior = None
|
|
38
|
+
self.canFrameTxBehavior = None
|
|
39
|
+
self.canXlFrameTriggeringProps = None
|
|
40
|
+
self.identifier = None
|
|
41
|
+
self.j1939requestable = None
|
|
42
|
+
self.rxIdentifierRange = None # type: RxIdentifierRange
|
|
43
|
+
self.rxMask = None
|
|
44
|
+
self.txMask = None
|
|
45
|
+
|
|
46
|
+
def getAbsolutelyScheduledTimings(self):
|
|
47
|
+
return self.absolutelyScheduledTimings
|
|
48
|
+
|
|
49
|
+
def setAbsolutelyScheduledTimings(self, value):
|
|
50
|
+
self.absolutelyScheduledTimings = value
|
|
51
|
+
return self
|
|
52
|
+
|
|
53
|
+
def getCanAddressingMode(self):
|
|
54
|
+
return self.canAddressingMode
|
|
55
|
+
|
|
56
|
+
def setCanAddressingMode(self, value):
|
|
57
|
+
self.canAddressingMode = value
|
|
58
|
+
return self
|
|
59
|
+
|
|
60
|
+
def getCanFdFrameSupport(self):
|
|
61
|
+
return self.canFdFrameSupport
|
|
62
|
+
|
|
63
|
+
def setCanFdFrameSupport(self, value):
|
|
64
|
+
self.canFdFrameSupport = value
|
|
65
|
+
return self
|
|
66
|
+
|
|
67
|
+
def getCanFrameRxBehavior(self):
|
|
68
|
+
return self.canFrameRxBehavior
|
|
69
|
+
|
|
70
|
+
def setCanFrameRxBehavior(self, value):
|
|
71
|
+
self.canFrameRxBehavior = value
|
|
72
|
+
return self
|
|
73
|
+
|
|
74
|
+
def getCanFrameTxBehavior(self):
|
|
75
|
+
return self.canFrameTxBehavior
|
|
76
|
+
|
|
77
|
+
def setCanFrameTxBehavior(self, value):
|
|
78
|
+
self.canFrameTxBehavior = value
|
|
79
|
+
return self
|
|
80
|
+
|
|
81
|
+
def getCanXlFrameTriggeringProps(self):
|
|
82
|
+
return self.canXlFrameTriggeringProps
|
|
83
|
+
|
|
84
|
+
def setCanXlFrameTriggeringProps(self, value):
|
|
85
|
+
self.canXlFrameTriggeringProps = value
|
|
86
|
+
return self
|
|
87
|
+
|
|
88
|
+
def getIdentifier(self):
|
|
89
|
+
return self.identifier
|
|
90
|
+
|
|
91
|
+
def setIdentifier(self, value):
|
|
92
|
+
self.identifier = value
|
|
93
|
+
return self
|
|
94
|
+
|
|
95
|
+
def getJ1939requestable(self):
|
|
96
|
+
return self.j1939requestable
|
|
97
|
+
|
|
98
|
+
def setJ1939requestable(self, value):
|
|
99
|
+
self.j1939requestable = value
|
|
100
|
+
return self
|
|
101
|
+
|
|
102
|
+
def getRxIdentifierRange(self) -> RxIdentifierRange:
|
|
103
|
+
return self.rxIdentifierRange
|
|
104
|
+
|
|
105
|
+
def setRxIdentifierRange(self, value: RxIdentifierRange):
|
|
106
|
+
self.rxIdentifierRange = value
|
|
107
|
+
return self
|
|
108
|
+
|
|
109
|
+
def getRxMask(self):
|
|
110
|
+
return self.rxMask
|
|
111
|
+
|
|
112
|
+
def setRxMask(self, value):
|
|
113
|
+
self.rxMask = value
|
|
114
|
+
return self
|
|
115
|
+
|
|
116
|
+
def getTxMask(self):
|
|
117
|
+
return self.txMask
|
|
118
|
+
|
|
119
|
+
def setTxMask(self, value):
|
|
120
|
+
self.txMask = value
|
|
121
|
+
return self
|
|
122
|
+
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
from typing import List
|
|
2
|
+
|
|
3
|
+
from ..m2.msr.documentation.block_elements import DocumentationBlock
|
|
4
|
+
from ..ar_ref import RefType
|
|
5
|
+
from ..ar_object import ARObject, ARPositiveInteger
|
|
6
|
+
from .fibex_core.core_communication import FibexElement
|
|
7
|
+
|
|
8
|
+
class FrameMapping(ARObject):
|
|
9
|
+
def __init__(self):
|
|
10
|
+
super().__init__()
|
|
11
|
+
|
|
12
|
+
self.introduction = None # type: DocumentationBlock
|
|
13
|
+
self.sourceFrameRef = None # type: RefType
|
|
14
|
+
self.targetFrameRef = None # type: RefType
|
|
15
|
+
|
|
16
|
+
def getIntroduction(self):
|
|
17
|
+
return self.introduction
|
|
18
|
+
|
|
19
|
+
def setIntroduction(self, value):
|
|
20
|
+
self.introduction = value
|
|
21
|
+
return self
|
|
22
|
+
|
|
23
|
+
def getSourceFrameRef(self):
|
|
24
|
+
return self.sourceFrameRef
|
|
25
|
+
|
|
26
|
+
def setSourceFrameRef(self, value):
|
|
27
|
+
self.sourceFrameRef = value
|
|
28
|
+
return self
|
|
29
|
+
|
|
30
|
+
def getTargetFrameRef(self):
|
|
31
|
+
return self.targetFrameRef
|
|
32
|
+
|
|
33
|
+
def setTargetFrameRef(self, value):
|
|
34
|
+
self.targetFrameRef = value
|
|
35
|
+
return self
|
|
36
|
+
|
|
37
|
+
class ISignalMapping(ARObject):
|
|
38
|
+
def __init__(self):
|
|
39
|
+
super().__init__()
|
|
40
|
+
|
|
41
|
+
self.introduction = None # type: DocumentationBlock
|
|
42
|
+
self.sourceSignalRef = None # type: RefType
|
|
43
|
+
self.targetSignalRef = None # type: RefType
|
|
44
|
+
|
|
45
|
+
def getIntroduction(self):
|
|
46
|
+
return self.introduction
|
|
47
|
+
|
|
48
|
+
def setIntroduction(self, value):
|
|
49
|
+
self.introduction = value
|
|
50
|
+
return self
|
|
51
|
+
|
|
52
|
+
def getSourceSignalRef(self):
|
|
53
|
+
return self.sourceSignalRef
|
|
54
|
+
|
|
55
|
+
def setSourceSignalRef(self, value):
|
|
56
|
+
self.sourceSignalRef = value
|
|
57
|
+
return self
|
|
58
|
+
|
|
59
|
+
def getTargetSignalRef(self):
|
|
60
|
+
return self.targetSignalRef
|
|
61
|
+
|
|
62
|
+
def setTargetSignalRef(self, value):
|
|
63
|
+
self.targetSignalRef = value
|
|
64
|
+
return self
|
|
65
|
+
|
|
66
|
+
class IPduMapping(ARObject):
|
|
67
|
+
def __init__(self):
|
|
68
|
+
super().__init__()
|
|
69
|
+
|
|
70
|
+
self.introduction = None # type: DocumentationBlock
|
|
71
|
+
self.pdurTpChunkSize = None # type: ARPositiveInteger
|
|
72
|
+
self.sourceIpduRef = None # type: RefType
|
|
73
|
+
self.targetIpduRef = None # type: RefType
|
|
74
|
+
|
|
75
|
+
def getIntroduction(self):
|
|
76
|
+
return self.introduction
|
|
77
|
+
|
|
78
|
+
def setIntroduction(self, value):
|
|
79
|
+
self.introduction = value
|
|
80
|
+
return self
|
|
81
|
+
|
|
82
|
+
def getPdurTpChunkSize(self):
|
|
83
|
+
return self.pdurTpChunkSize
|
|
84
|
+
|
|
85
|
+
def setPdurTpChunkSize(self, value):
|
|
86
|
+
self.pdurTpChunkSize = value
|
|
87
|
+
return self
|
|
88
|
+
|
|
89
|
+
def getSourceIpduRef(self):
|
|
90
|
+
return self.sourceIpduRef
|
|
91
|
+
|
|
92
|
+
def setSourceIpduRef(self, value):
|
|
93
|
+
self.sourceIpduRef = value
|
|
94
|
+
return self
|
|
95
|
+
|
|
96
|
+
def getTargetIpduRef(self):
|
|
97
|
+
return self.targetIpduRef
|
|
98
|
+
|
|
99
|
+
def setTargetIpduRef(self, value):
|
|
100
|
+
self.targetIpduRef = value
|
|
101
|
+
return self
|
|
102
|
+
|
|
103
|
+
class Gateway(FibexElement):
|
|
104
|
+
def __init__(self, parent: ARObject, short_name: str):
|
|
105
|
+
super().__init__(parent, short_name)
|
|
106
|
+
|
|
107
|
+
self.ecuRef = None # type: RefType
|
|
108
|
+
self.frameMappings = [] # type: List[FrameMapping]
|
|
109
|
+
self.iPduMappings = [] # type: List[IPduMapping]
|
|
110
|
+
self.signalMappings = [] # type: List[ISignalMapping]
|
|
111
|
+
|
|
112
|
+
def getEcuRef(self):
|
|
113
|
+
return self.ecuRef
|
|
114
|
+
|
|
115
|
+
def setEcuRef(self, value):
|
|
116
|
+
self.ecuRef = value
|
|
117
|
+
return self
|
|
118
|
+
|
|
119
|
+
def getFrameMappings(self) -> List[FrameMapping]:
|
|
120
|
+
return self.frameMappings
|
|
121
|
+
|
|
122
|
+
def addFrameMapping(self, mapping: FrameMapping):
|
|
123
|
+
self.frameMappings.append(mapping)
|
|
124
|
+
return self
|
|
125
|
+
|
|
126
|
+
def getIPduMappings(self) -> List[FrameMapping]:
|
|
127
|
+
return self.iPduMappings
|
|
128
|
+
|
|
129
|
+
def addIPduMappings(self, mapping: FrameMapping):
|
|
130
|
+
self.iPduMappings.append(mapping)
|
|
131
|
+
return self
|
|
132
|
+
|
|
133
|
+
def getSignalMappings(self) -> List[FrameMapping]:
|
|
134
|
+
return self.signalMappings
|
|
135
|
+
|
|
136
|
+
def addSignalMapping(self, mapping: FrameMapping):
|
|
137
|
+
self.signalMappings.append(mapping)
|
|
138
|
+
return self
|
|
File without changes
|