![]() |
S32 SDK
|
Error Reporting Module Peripheral Driver.
This section describes the programming interface of the ERM driver.
Data Structures | |
struct | erm_interrupt_config_t |
ERM interrupt notification configuration structure Implements : erm_interrupt_config_t_Class. More... | |
struct | erm_user_config_t |
ERM user configuration structure Implements : erm_user_config_t_Class. More... | |
Variables | |
ERM_Type *const | g_ermBase [ERM_INSTANCE_COUNT] |
Table of base addresses for ERM instances. More... | |
ERM DRIVER API | |
void | ERM_DRV_Init (uint32_t instance, uint8_t channelCnt, const erm_user_config_t *userConfigArr) |
Initializes the ERM module. More... | |
void | ERM_DRV_Deinit (uint32_t instance) |
Sets the default configuration. More... | |
void | ERM_DRV_SetInterruptConfig (uint32_t instance, uint8_t channel, erm_interrupt_config_t interruptCfg) |
Sets interrupt notification. More... | |
void | ERM_DRV_GetInterruptConfig (uint32_t instance, uint8_t channel, erm_interrupt_config_t *const interruptPtr) |
Gets interrupt notification. More... | |
void | ERM_DRV_ClearEvent (uint32_t instance, uint8_t channel, erm_ecc_event_t eccEvent) |
Clears error event and the corresponding interrupt notification. More... | |
erm_ecc_event_t | ERM_DRV_GetErrorDetail (uint32_t instance, uint8_t channel, uint32_t *addressPtr) |
Gets the address of the last ECC event in Memory n and ECC event. More... | |
void ERM_DRV_ClearEvent | ( | uint32_t | instance, |
uint8_t | channel, | ||
erm_ecc_event_t | eccEvent | ||
) |
Clears error event and the corresponding interrupt notification.
This function clears the record of an event. If the corresponding interrupt is enabled, the interrupt notification will be cleared
[in] | instance | The ERM instance number |
[in] | channel | The configured memory channel |
[in] | eccEvent | The types of ECC events |
Definition at line 144 of file erm_driver.c.
void ERM_DRV_Deinit | ( | uint32_t | instance | ) |
Sets the default configuration.
This function sets the default configuration
[in] | instance | The ERM instance number |
Definition at line 84 of file erm_driver.c.
erm_ecc_event_t ERM_DRV_GetErrorDetail | ( | uint32_t | instance, |
uint8_t | channel, | ||
uint32_t * | addressPtr | ||
) |
Gets the address of the last ECC event in Memory n and ECC event.
This function gets the address of the last ECC event in Memory n and the types of the event
[in] | instance | The ERM instance number |
[in] | channel | The examined memory channel |
[out] | addressPtr | The pointer to address of the last ECC event in Memory n with ECC event |
Definition at line 164 of file erm_driver.c.
void ERM_DRV_GetInterruptConfig | ( | uint32_t | instance, |
uint8_t | channel, | ||
erm_interrupt_config_t *const | interruptPtr | ||
) |
Gets interrupt notification.
This function gets the current interrupt configuration of the available events (which interrupts are enabled/disabled)
[in] | instance | The ERM instance number |
[in] | channel | The examined memory channel |
[out] | interruptPtr | The pointer to the ERM interrupt configuration structure |
Definition at line 122 of file erm_driver.c.
void ERM_DRV_Init | ( | uint32_t | instance, |
uint8_t | channelCnt, | ||
const erm_user_config_t * | userConfigArr | ||
) |
Initializes the ERM module.
This function initializes ERM driver based on user configuration input, channelCnt takes values between 1 and the maximum channel count supported by the hardware
[in] | instance | The ERM instance number |
[in] | channelCnt | The number of channels |
[in] | userConfigArr | The pointer to the array of ERM user configure structure |
Definition at line 56 of file erm_driver.c.
void ERM_DRV_SetInterruptConfig | ( | uint32_t | instance, |
uint8_t | channel, | ||
erm_interrupt_config_t | interruptCfg | ||
) |
Sets interrupt notification.
This function sets interrupt notification based on interrupt notification configuration input
[in] | instance | The ERM instance number |
[in] | channel | The configured memory channel |
[in] | interruptCfg | The ERM interrupt configuration structure |
Definition at line 101 of file erm_driver.c.
ERM_Type* const g_ermBase[ERM_INSTANCE_COUNT] |
Table of base addresses for ERM instances.
Definition at line 43 of file erm_driver.c.