cogu / autosar

A set of python modules for working with AUTOSAR XML files
MIT License
353 stars 160 forks source link

SWC-IMPLEMENTATION / CONSTANT-SPECIFICATION-MAPPING-SET / APPLICATION-SW-COMPONENT-TYPE support #104

Closed WeWonderMax closed 3 months ago

WeWonderMax commented 4 months ago

Hi !

First of all thank you for your work on this project, helped me quite a lot.

I'm trying to build a "ARXML checker" that would basically compare 2 ARXML that should be identical.

I based my work on your object-oriented logic by simply iterating over each ports (previously extracted in a dict since your package does not support that feature yet as i understand) and getting each sub-elements with nested loops.

So far I processed many (sub) elements and it is working as expected.

Nonetheless I have a few questions and I hope you can help me out:

Thank you for your time, have a good one.

cogu commented 4 months ago

Which release are you using? v0.41? v0.5.2? For v0.4.1 SwcImplementation and ApplicationSwComponent are already implemented. For v0.5.2 they are not, but also ports are not implemented so I have no idea what you mean by the looping thing. Are you looping over elements?

ApplicationSwComponent will be (partially) supported in v0.5.3, SwcImplementation will be supported in v0.5.4. I have never seen the constant-specification-mapping-set element before. Not sure when I will implement that but it will be sometime after v0.5.4 and before v0.6.0.

WeWonderMax commented 3 months ago

i use v0.5.2 basically i extract the ports like this first with xpath and all:

{ "Name": "svcRearWiperControlMain_setRearWiperIOCtrl", "Interface": "/ARRoot/org/.../PortInterfaces/If_RearWiperControlSvcProv_setRearWiperIOCtrl", "Init_value": "/ARRoot/org/.../ConstAppl/initValueDef_If_RearWiperControlSvcProv_setRearWiperIOCtrl", "Data_element": "/ARRoot/org/.../PortInterfaces/If_RearWiperControlSvcProv_setRearWiperIOCtrl/data" },

then your module comes into play to find the refs (document.find) and sub elements (operations,elements....)

I'm looking forward to the next versions as it would be a complete solution for me

cogu commented 3 months ago