Skip to content
Conny Gustafsson edited this page Jun 19, 2023 · 9 revisions

This wiki is used to document the state and progress of Python AUTOSAR v0.5.

Background

The current code base of Python AUTOSAR has become stale and old. This initiative aims to rewrite it while making a number of design changes.

Key design changes

New element class hierarchy

  • Attempt to follow the AUTOSAR XML schema as much as possible.
  • Allowing kwargs in constructor methods drastically reduces the number of arguments needed.

Modern coding style

  • Snake-case naming on variables and method names (attempt to follow PEP8).
  • Modern type-hinting, this forces Python 3.10+.
  • Python Enum classes for enumeration types.

XML reading and writing

  • New element class hierarchy drastically reduces repetition (redundancy) in XML reader & writer implementations.

Unit testing

  • Unit tests reads and writes only the XML element under test. No more writing and matching entire ARXML files.

Project limitations

  • Support AUTOSAR classic platform only.
  • Support only newer AUTOSAR schema versions, starting with R21-11. Versions R20-11 and R22-11 might be added later on depending on complexity.
  • Don't support XML-based blueprints or variant handling of any kind. (Python AUTOSAR offers a more powerful alternative).

Roadmap

As this is a full rewrite of the code base it it will take some time until it has the same set of features as is available in v0.4.

Below is a rough idea of a roadmap:

v0.5.0: Data types

v0.5.1: Constants

v0.5.2: Port interfaces

v0.5.3: Components and ports

v0.5.4: Component (internal) behavior

(There will probably be some intermediate versions here since behavior is a huge area.)

v0.5.?: System description

v0.6.0: Stable release

In short, version 0.5 will remain a development version and once it's stable enough it will be relabeled as v0.6.

Supported Elements

Supported elements will be listed here. If an element is not mentioned below it's not yet fully supported. Partially supported elements or elements that is currently being implemented are not listed.

Most notably, at the moment the Workspace class isn't implemented. Instead use a Document object to place your packages (see code examples).

Collectable Elements

Collectable elements are those that can be added to an ARPackage.

  • BaseType
  • CompuMethod
  • DataConstraint
  • Unit

Non-collectable Elements

Non-collectible elements are those that are used as sub-elements of collectible elements or other non-collectible elements.

Documentation elements

  • DocumentationBlock
  • EmphasisText
  • MultiLanguageLongName
  • MultiLanguageOverviewParagraph
  • MultiLanguageParagraph
  • MultiLanguageVerbatim
  • Subscript
  • Superscript
  • TechnicalTerm
Clone this wiki locally