Explicit Periodic Trigger Slip Definition

This MotoHawk™ block allows the developer to install periodic trigger slip monitoring on a per trigger basis into the application.

Block ID

Periodic Trigger Slip Def

Library

motohawk_tasking_lib/Trigger Blocks

Description

Periodic Trigger Slip

Periodic triggers, like the periodic form of the Common Event Trigger, execute work periodically. Tasks are used by the developer to prioritize the importance of the work such that a task of higher relative priority will execute its work in preference to work assigned to a lower priority task. Preferential work execution can mean that some work can be late in its execution. That is, it slips relative to its intended rate of execution. This MotoHawk™ block allows the developer to install code that will monitor the execution of a periodic trigger and detect when the trigger's execution has slipped. Additionally it offers an option to issue a module reset if such tardiness in execution warrants it.

Periodic triggers are grouped for monitoring based upon their rate of execution and their priority of execution (which is implied by the task that is associated with the trigger). This is why such triggers are often referred to as Rate Groups. Thus two independent triggers with an execution rate of 5ms that target (say) the FGNDTask will be treated as one body of work. While potentially independent, to be on time requires that both complete their execution, which is why they are grouped together.

This block is similar to the Global Periodic Trigger Slip & Execution Metrics block. Its key point of difference is that it allows each periodic trigger group to have its own definition. A definition must be supplied for all the periodic trigger groups used by the application, but a definition can choose to not install slip detection on a particular trigger group. Supplying a definition for all available triggers ensures a trigger group is not inadvertently missed.

Trigger group slip is detected when an instance of trigger group execution does not complete in time. Elapsed Time is a measure of the time between the trigger group being requested to execute and that execution completing. The allowed time for completion is calculated by multiplying the slip tolerance attribute by the trigger group's periodic rate of execution. For example, a 5ms trigger group that took more than 2ms to complete its execution would be said to not have completed in time (which is known as a Slip Event) if the slip tolerance attribute was 40% (5ms x 0.4 = 2ms).

Execution Metrics

This Global Periodic Trigger Slip & Execution Metrics can still be used with explicit slip definitions. All that is required is for the Install Slip Detection of the global block be left unchecked.

Use the Global Trigger Execution Metric Reset block to have the application reset attributes related to observed slip.

OS Support

This behavior is not supported on classic modules.

Block Parameters

Defn

Parameter Field Values Comments/Description
Reference Task Single quote enclosed alpha-numeric The name of the Task that the periodic trigger group executes within. A 5ms periodic trigger group that executes in (say) the FGNDTask is not the same periodic trigger group as a 5ms trigger that executes in (say) the BGNDTask. They have difference execution priorities that require them to be grouped separately so far as slip detection is concerned and therefore separate definitions will need to exist.
Method of periodic execution specification Dropdown Specifies the method that the block will use to identify the periodic trigger group. This allows both TIME_PERIODIC and RTIx_PERIODIC triggers to be easily identified. Legacy periodic triggers will also be identified.
Triggers Period of Execution Numeric Specify the trigger group of interest. Data format is based upon the Method of periodic execution specification
Install Slip Detection Checkbox Check to install slip detection into the application for the specified trigger group. Uncheck to prevent code generation related to slip detection from occurring for this trigger group. Thus some trigger groups may support slip while others don't.

Config

Parameter Field Values Comments/Description
Condition Dropdown Define the condition of the slip strategy for this trigger group. Slip will be actively detected when the strategy is Enabled. Supports calibration. Only visible when Install Slip Detection is checked. An Enabled condition will only become active if that is the condition on start-up out of reset.
Reset On Slip Checkbox When checked the module will reset if this trigger group is considered to have slipped. Supports calibration. Only visible when Install Slip Detection is checked
Slip Tolerance Spin Dialog (0-199%) Defines the percentage of the trigger group's periodic interval that an instance of trigger group execution must complete within to avoid being considered late. For example a 5ms trigger group that completed 2ms after being scheduled to occur would be considered to have suffered a slip event if the Slip Tolerance was set to 40% (5ms x 0.4 = 2ms). A typical value is 100%, which implies that execution will complete before the trigger group would be scheduled to occur again. Supports calibration. Only visible when Install Slip Detection is checked.
Slip OK Down Count Positive Non Zero Integer Each time a trigger group meets its timing (i.e. no slip event observed) a counter decrements by this value until that counter reaches zero. Supports calibration. Only visible when Install Slip Detection is checked.
Slip Fail Up Count Positive Non Zero Integer Each time a trigger group fails to meet its timing (i.e. a slip event is observed) a counter increments by this value. If the value of the counter equals or exceeds the Slip Threshold then a slip failure is considered to have been observed. Supports calibration. Only visible when Install Slip Detection is checked.
Slip Threshold Positive Non Zero Integer Defines count threshold that when reached or exceeded is considered a slip failure. A slip failure can result in a reset if the Reset On Slip is checked. Supports calibration. Only visible when Detect Slip is checked.

Slip Instrumentation

Parameter Field Values Comments/Description
Allow Calibration of * attributes Checkbox Check to have Slip Definition attributes exposed to calibration. Only visible when Detect Slip is checked.
Read Access Level Dropdown Defines the read access level of the calibrations. Only visible when Allow Calibration of * attributes and Detect Slip are checked.
Write Access Level Dropdown Defines the write access level of the calibrations. Only visible when Allow Calibration of * attributes and Install Slip Detection are checked.
Instrumentation Group Single quote enclosed alphanumeric Defines the instrumentation group that will be associated to any calibrations exposed to instrumentation. Only visible when Allow Calibration of * attributes and DInstall Slip Detection are checked.
Expose Status to Instrumentation Checkbox A status variable is exposed to Instrumentation indicating the status of each trigger group when this is checked. Only visible when Install Slip Detection is checked.
Read Access Level Dropdown Defines the read access level of the status variables. Only visible when Expose Status to Instrumentation and Install Slip Detection are checked.
Instrumentation Group Single quote enclosed alphanumeric Defines the instrumentation group that will be associated to status variables. Only visible when Expose Status to Instrumentation and Install Slip Detection are checked.