Best Practices

To use this ARXF-CP instead of an RXF for 'normal' embedded environments, there are a few things you need to know to get your model running in an AUTOSAR environment:

Existing Models

An SWC must have at least two runnables. If you apply the stereotype CpSWC to an existing class, these runnables are not created: you must add them yourselves.

You need some runnables:

The behavior of how Rhapsody generates the symbol for a runnable can be set via a property, see Profiles

The ARXF-CP uses the RTE generated APIs to enter- and exit exclusive areas as Critical Region handlers, see OS Integration.
You need:

The ARXF-CP uses the RTE generated APIs to write and read inter-runnable variables to store and retrieve ARXF-CP task pointers. You need one inter-runnable per ARXF-CP task structure:

Note that for proper code generation, the ARXF-CP needs stereotyped dependencies between runnables towards inter-runnables and runnables towards exclusive areas. For more details, please refer to the section on the SodiusWillert AUTOSAR Profiles.

For sample implementations of runnables, please refer to the Standard Content of an SWC.

If you want that a class runs in its own OS task and processes its own UML event queue, you need an active class, see Concurrency:

New Models