Health Monitoring of a Supervised Entity with DaVinci Developer Adaptive is set up by creating interfaces for the processes to be supervised as well as for the notification process, mapping them to a machine (ECU) and configuring the supervision and notification parameters.

Steps:

  1. Create Supervised Entity Interface
  2. Create Recovery Notification Interface
  3. Create ports for PHM in the Executable Editor
  4. Create Contribution
  5. Create Global Supervision
  6. Create Local Supervision
  7. Create Alive, Deadline or Logical Supervision
  8. Create Transitions

Create Supervised Entity Interface

To supervise a process of your application, you need to create a I_SupervisedEntity Supervised Entity Interface for it.

  1. Open the Platform Health Management Editor.
  2. Right-click on I_Interface Interfaces.
  3. Select Create PHM Supervised Entity Interface.
  4. The Create PHM Supervised Entity Interface wizard opens.
  5. Choose a name for your Supervised Entity.
  6. Choose the Package and the ARXML file where the Supervised Entity Interface should be stored.
  7. Click Finish.
  8. You have created a I_SupervisedEntity Supervised Entity Interface. It is now listed under Interfaces.
  9. Create the Checkpoints for Supervision.
  1. The I_SupervisedEntity Supervised Entity Interface can now be used to create an application port in the Executable.

Create Recovery Notification Interface

To be able to notify state management or the watchdog you need to create a I_SupervisedEntityRecovery Recovery Notification Interface for the corresponding daemon process.

  1. You are in the PHM Editor.
  1. Right-click on I_Interface Interfaces.
  2. Select Create PHM Supervision Recovery Notification Interface.
  3. The Create PHM Supervision Recovery Notification Interface wizard opens.
  4. Choose a name for your Notification Interface.
  5. Choose the Package and the ARXML file where the Notification Interface should be stored.
  6. Click Finish.
  1. You have created a I_SupervisedEntityRecovery Recovery Notification Interface. It is now listed under Interfaces. The I_SupervisedEntityRecovery Recovery Notification Interface can now be used to create a state manager port in the Executable.

Create ports in the Executable

To get the input of a process and to send output to State Management, we need to create ports for those processes in the Executable.

  1. Open the Executable Editor.
  2. Select the SWComponent for the application.
  3. Select the tab Others.
  4. I_Add Add Port Prototype and check Required for your Supervised Entity Interface.
  5. Click Finish.
  6. The port for your Supervised Entity Interface is listed under Ports.
  7. Select the SWComponent for your state manager application.
  8. Select the tab Others.
  9. I_Add Create Port Prototype and check Provided for your Recovery Notification Interface.
  10. Click Finish.
  11. The port for your Recovery Notification Interface is listed under Ports.
  12. Go back to the PHM Editor.
  1. You now have set up the input and output ports for Platform Health Management. You can now add them to your Supervisions.

Create a Contribution

A I_PHMContribution Contribution indicates that the current PHM configuration is part of a broader configuration scheme. At the I_PHMContribution Contribution level we configure the PHM daemon.

  • We select the Checkpoints that we want to supervise,
  • map the related Supervisions to a machine, and can
  • disable the Watchdog for all Global Supervisions related to that Contribution.
  1. You are in the PHM Editor.
  1. Right-click on I_PHMContribution Contributions.
  2. Select Create Platform Health Management Contribution.
  3. The Create Platform Health Management Contribution wizard opens.
  4. Choose a name for your I_PHMContribution Contribution.
  5. Choose the Package and the ARXML file where the I_PHMContribution Contribution should be stored.
  6. Click Finish.
  7. The wizard closes.
  8. Go to the section Checkpoints and I_Add Create and Map the Supervision Checkpoints that you want to supervise in this I_PHMContribution Contribution.
  9. Go to the section Machine and I_Add Map a Machine that was defined in the Machine Editor.
  1. You have created a I_PHMContribution Contribution. It now is listed under I_PHMContribution Contributions. Now, you are able to create I_GlobalSupervision Global and I_LocalSupervision Local Supervisions for this I_PHMContribution Contribution.

Disable Watchdog for a Contribution

At the Contribution level you have two settings concerning the Watchdog in the MICROSAR Adaptive Parameters:

Parameter

Description

Watchdog Alive Notification Cycle Time

The watchdog alive notification cycle time used for alive notifications to the Watchdog Client.

Disable Watchdog Client

Deactivate watchdog for all Global Supervisions in that Contribution.

Create Global Supervision for reporting to State Management

A Global Supervision combines the result of all related Local Supervisions into a single global “worst-of” result. That means that if one Local Supervision reports a status FAILED, EXPIRED or STOPPED the result of the Global Supervision takes on that status and reports it to the State Manager.

  1. You are in the PHM Editor.
  2. A I_PHMContribution Contribution was created.
  1. Right-click on your I_PHMContribution Contribution.
  2. Select I_Add Create Global Supervision.
  3. A new I_GlobalSupervision Global Supervision was added.
  4. Select the new I_GlobalSupervision Global Supervision, name it and fill out the necessary parameters.
  5. To send a Recovery Notification to State Management in case of failure, in the section Recovery Notification add the fitting ports for the Recovery Notification Interface as Health Channels.

Parameters Global Supervision

Parameter

Description

Name

Unique name of the Global Supervision

Description

Choose a good description that explains the Global Supervision to your future self and your colleagues.

Expired Supervision Cycles Tolerance

Defines the acceptable amount of cycles with EXPIRED supervision status of this Global Supervision before it is considered STOPPED.

Supervision Cycle

Defines at which cycle the Global Supervision shall be executed. For example: 0.05 (seconds)

Create Local Supervision for a Process

Get monitoring result of your Supervised Entity and define when monitoring should be active.

  1. You are in the PHM Editor.
  2. You have created a I_GlobalSupervision Global Supervision.
  1. Right-click on your I_GlobalSupervision Global Supervision.
  2. Select I_Add Create Local Supervision.
  3. A new I_LocalSupervision Local Supervision was added. If you expand the I_LocalSupervision Local Supervision you will see two new items: I_Supervision Supervisions and I_CheckpointTransition Transitions.
  4. Select the new I_LocalSupervision Local Supervision, name it and fill out the necessary Supervision parameters.
  5. Configure when the I_LocalSupervision Local Supervision is active in the MICROSAR Adaptive Parameters.

Parameters Local Supervision

Parameter

Description

Name

Unique name of the Local Supervision

Description

Choose a good description that explains the Local Supervision to your future self and your colleagues.

Failed Supervision Cycles Tolerance

Defines the acceptable amount of cycles with FAILED supervision status of this Local Supervision before it is considered EXPIRED.

MICROSAR Adaptive Parameters for Local Supervision

Extension

Parameter

Description

functionGroupStates PHMFunctionGroupStateGroups

Function Group Ref

Name of the Function Group defined in the Software Cluster Editor.

functionGroupStateRefs

functionGroupStateRefs

States of the Function Group when the Local Supervision is active. Which States are available is defined in the Machine Editor.

Create Alive, Deadline or Logical Supervision

  1. You are in the PHM Editor.
  2. You have created a I_LocalSupervision Local Supervision.
  1. Expand your I_LocalSupervision Local Supervision.
  2. Right click on I_Supervision Supervisions.
  3. Select the required Supervision type.
  4. Your Supervision type was added.
  5. Select the Supervision and fill out the necessary parameters.

Supervision Types

For Health Monitoring there are three different Supervision types that can be chosen in the PHM Editor.

Supervision Type

Description

I_AliveSupervision Alive Supervision

Monitors a cyclic checkpoint to ensure it reports at the correct interval. If a monitored application signals its "alive" status too frequently or too infrequently, a violation is identified.

I_DeadlineSupervision Deadline Supervision

Monitors the transition time between two checkpoints of a Supervised Entity to find out if a process is early, timely or late.

I_LogicalSupervision Logical Supervision

Defines the checkpoints and transitions that indicate if the process flow is executed as expected or not.

Parameters Alive Supervision

Parameter

Required/
Optional

Data type

Description

Name

Required

String

Unique name of the Supervision.

Description

Optional

String

Choose a good description that explains the Alive Supervision to your future self and your colleagues.

Alive Reference Cycle

Required

Integer

Time period at which the Alive Supervision mechanism compares the amount of received Alive Indications for the SupervisionCheckpoint against the expectedAliveIndications.

Expected Live Indications

Required

Integer

Defines the amount of expected Alive Indications of the SupervisionCheckpoint within the aliveReferenceCycle.

Max Margin

Required

Integer

Defines the amount of expected Alive Indications of the SupervisionCheckpoint that are acceptable to be additional to the expectedAliveIndications within the aliveReferenceCycle.

Min Margin

Required

Integer

Defines the amount of expected Alive Indications of the SupervisionCheckpoint that are acceptable to be missing to the expectedAliveIndications within the aliveReferenceCycle.

Supervision Checkpoint

Required

Reference

Reference to a checkpoint in the context of Alive Supervision.

References a Checkpoint related to the current I_PHMContribution Contribution.

Max Startup Delay

Optional

Integer

Defines the maximum start-up delay time of the Alive Supervision in seconds.

Must be an integer multiple of watchdogAliveNotificationCycleTime within the interval [0, UINT32_MAX-1].

Parameters Deadline Supervision

Parameter

Required/
Optional

Data type

Description

Name

Required

String

Unique name of the Supervision.

Description

Optional

String

Choose a good description that explains the Deadline Supervision to your future self and your colleagues.

Max Deadline

Required

Integer

The longest time span allowed for a transition between two checkpoints.

Min Deadline

Required

Integer

The shortest time span allowed for the transition between two checkpoints.

Checkpoint Transition

Required

Reference

Checkpoint Transition to be monitored. Defined under I_CheckpointTransition Transitions.

Source

Required

Reference

Source Checkpoint for this transition.

Field is connected to the selected I_CheckpointTransition Transition. You can fill it out in the Deadline Supervision form or in the respective I_CheckpointTransition Transition.

References Checkpoints related to the current I_PHMContribution Contribution.

Target

Required

Reference

Target Checkpoint for this transition.

Field is connected to the selected I_CheckpointTransition Transition. You can fill it out in the Deadline Supervision form or in the respective I_CheckpointTransition Transition.

References Checkpoints related to the current I_PHMContribution Contribution.

Parameters Logical Supervision

Parameter

Required/
Optional

Data type

Description

Name

Required

String

Unique name of the Supervision.

Description

Optional

String

Choose a good description that explains the Logical Supervision to your future self and your colleagues.

Initial Checkpoints

Required

References

Starting points within the logical sequence of a Supervised Entity. Initial Checkpoints define where a particular logical flow begins.

References Checkpoints related to the current I_PHMContribution Contribution.

Transitions

Required

References

Defines how a process is supposed to flow from the Initial Checkpoint to the Final Checkpoint.

References I_CheckpointTransition Transitions.

Final Checkpoints

Required

References

The Final Checkpoint is the endpoint within the logical sequence of a Supervised Entity.

References Checkpoints related to the current I_PHMContribution Contribution.

Transitions for Local Supervisions

Under I_LocalSupervision Local Supervision > I_CheckpointTransition Transitions you can define transition paths between a Source Checkpoint and a Target Checkpoint. Transitions are then referenced in I_DeadlineSupervisionDeadline and I_LogicalSupervision Logical Supervisions.