Functions that record events along with data information. More...
Content | |
Event level | |
Defines for parameter level for EventID. | |
Component number | |
Defines for parameter comp_no for EventID. | |
Macros | |
#define | EventID(level, comp_no, msg_no) ((level & 0x30000U) | ((comp_no & 0xFFU) << 8) | (msg_no & 0xFFU)) |
Composed event id from level, component number and message number. | |
Functions | |
uint32_t | EventRecord2 (uint32_t id, uint32_t val1, uint32_t val2) |
Record an event with two 32-bit data values. | |
uint32_t | EventRecord4 (uint32_t id, uint32_t val1, uint32_t val2, uint32_t val3, uint32_t val4) |
Record an event with four 32-bit data values. | |
uint32_t | EventRecordData (uint32_t id, const void *data, uint32_t len) |
Record an event with variable data size. | |
Functions that record events along with data information.
This section describes the functions that are called from the user application or middleware libraries to record events.
Each event has an id that combines level, component number, and message number:
can have an additional event level that is used for filtering. The event level value is defined by EventLevelError, EventLevelAPI, EventLevelOp, or EventLevelDetail and added to the event ID number.
Code example
#define EventID | ( | level, | |
comp_no, | |||
msg_no | |||
) | ((level & 0x30000U) | ((comp_no & 0xFFU) << 8) | (msg_no & 0xFFU)) |
Composed event id from level, component number and message number.
level | Event level of the id |
comp_no | component number of the id |
msg_no | message number of the id |
The macro EventID generates an id value that combines level, component number, and message number. The level value should be set to EventLevelError, EventLevelAPI, EventLevelOp, or EventLevelDetail.
The id value is used by the functions EventRecordData, EventRecord2, and EventRecord4.
uint32_t EventRecord2 | ( | uint32_t | id, |
uint32_t | val1, | ||
uint32_t | val2 | ||
) |
Record an event with two 32-bit data values.
[in] | id | event identifier (level, component number, message number) |
[in] | val1 | first data value |
[in] | val2 | second data value |
Code Example
uint32_t EventRecord4 | ( | uint32_t | id, |
uint32_t | val1, | ||
uint32_t | val2, | ||
uint32_t | val3, | ||
uint32_t | val4 | ||
) |
Record an event with four 32-bit data values.
[in] | id | event identifier (level, component number, message number) |
[in] | val1 | first data value |
[in] | val2 | second data value |
[in] | val3 | third data value |
[in] | val4 | fourth data value |
Code Example
uint32_t EventRecordData | ( | uint32_t | id, |
const void * | data, | ||
uint32_t | len | ||
) |
Record an event with variable data size.
[in] | id | event identifier (level, component number, message number) |
[in] | data | event data buffer |
[in] | len | event data length |
Code Example