Xpm_SetUpAnEvent - 2023.1 English

Standalone Library Documentation: BSP and Libraries Document Collection (UG643)

Document ID
UG643
Release Date
2023-05-16
Version
2023.1 English

Sets up one of the event counters to count events based on the Event ID passed.

For supported Event IDs, refer xpm_counter.h. Once invoked, the API searches for an available counter. After finding one, it sets up the counter to count events for the requested event.

Prototype

u32 Xpm_SetUpAnEvent(u32 EventID);

Parameters

The following table lists the Xpm_SetUpAnEvent function arguments.

Table 1. Xpm_SetUpAnEvent Arguments
Name Description
EventID For valid values, refer xpm_counter.h.

Returns

  • Counter Number if successful. For Cortex-R5, valid return values are 0, 1, or 2.
  • XPM_NO_COUNTERS_AVAILABLE (0xFF) if all counters are being used