AM263Px MCU+ SDK: CCM

| AM263Px MCU+ SDK 26.00.00 |

CCM

# Features Supported

The Compute Compare Module (CCM) is the R5F sub-system’s implementation for the lockstep error detection logic. The R5F sub-system, when bootstrapped to lockstep mode, has a logic that compares the outputs of the two cores and asserts an interrupt whenever an error is detected. There is also a logic to test the comparison logic.

The CCM module provides APIs to:

- Initialize the R5F CCM for the operating modes and verify the config
- Perform Self-test of the supported operating modes (normal and error forcing)
- Inject an error
- Read back the static config registers
- Clear errors that have occurred due to error injection or actual fault

# SysConfig Features

- None

# Features NOT Supported

- None

# Important Usage Guidelines

- None

# Example Usage

The following shows an example of SDL R5F CCM API usage by the application.

Initialize the R5F CCM instance

retVal = SDL_CCM_init(SDL_R5SS0_CCM);
if (result != SDL_PASS)
{
DebugP_log("CCM_Test_init: Error result = %d\n", result);
retValue = -1;
}
else
{
DebugP_log("\nCCM_Test_init: CCM Init complete \n");
}

Verify the configuration

result = SDL_CCM_verifyConfig(0);
if (result != SDL_PASS)
{
DebugP_log("R5F-CPU example application CCM_Test_init: Error result = %d\n", result);
retValue = -1;
}
else
{
DebugP_log("\nR5F-CPU example application CCM_Test_init: CCM Init complete \n");
}

Perform a self-test:

result = SDL_CCM_selfTest(SDL_R5SS0_CCM,
SDL_CCM_MONITOR_TYPE_OUTPUT_COMPARE_BLOCK,
SDL_CCM_SELFTEST_TYPE_NORMAL, 0U,
10000000);
if (result != SDL_PASS )
{
DebugP_log("\n R5F-CPU example application CCM self test failed");
retVal = -1;
}
else
{
DebugP_log("\n R5F-CPU example application CCM Self Test complete");
}

Inject an error:

result = SDL_CCM_injectError(SDL_R5SS0_CCM, SDL_CCM_MONITOR_TYPE_OUTPUT_COMPARE_BLOCK);
if (result != SDL_PASS ) {
DebugP_log("\n R5F-CPU example application CCM inject failed");
retVal = -1;
} else {
DebugP_log("\n R5F-CPU example application CCM inject Test complete");
}

# API

APIs for CCM MODULE

SDL_CCM_MONITOR_TYPE_OUTPUT_COMPARE_BLOCK
@ SDL_CCM_MONITOR_TYPE_OUTPUT_COMPARE_BLOCK
Definition: sdl_ip_ccm.h:80
SDL_CCM_init
int32_t SDL_CCM_init(SDL_CCM_Inst instance, uint32_t index)
Initialization API for CCM module.
DebugP_log
#define DebugP_log(format,...)
Function to log a string to the enabled console.
Definition: DebugP.h:235
SDL_CCM_SELFTEST_TYPE_NORMAL
@ SDL_CCM_SELFTEST_TYPE_NORMAL
Definition: sdl_ip_ccm.h:106
SDL_CCM_selfTest
int32_t SDL_CCM_selfTest(SDL_CCM_Inst instance, SDL_CCM_MonitorType monitorType, SDL_CCM_SelfTestType testType, uint32_t polarityInversionMask, uint32_t timeoutCnt)
Executes a self-test of the CCM module. The types of self-tests supported are described in detail in ...
SDL_CCM_verifyConfig
int32_t SDL_CCM_verifyConfig(SDL_CCM_Inst instance)
Verifies the configuration done as part of SDL_CCM_init is as expected.
SDL_R5SS0_CCM
#define SDL_R5SS0_CCM
Definition: sdl_soc_ccm.h:70
SDL_CCM_injectError
int32_t SDL_CCM_injectError(SDL_CCM_Inst instance, SDL_CCM_MonitorType monitorType)
Forces an error to be generated for the selected monitor type. After injecting the error,...