Percepio Trace Recorder
v4.6.6
|
Macros | |
#define | xTraceISRGetCurrentNesting(puiValue) TRC_COMMA_EXPR_TO_STATEMENT_EXPR_2(*(puiValue) = pxTraceISRInfo->coreInfos[TRC_CFG_GET_CURRENT_CORE()].stackIndex, TRC_SUCCESS) |
Gets current trace ISR nesting level. More... | |
#define | xTraceISRGetCurrentNestingReturned() (pxTraceISRInfo->coreInfos[TRC_CFG_GET_CURRENT_CORE()].stackIndex) |
#define | xTraceISRGetCurrent(pxISRHandle) (xTraceISRGetCurrentNestingReturned() >= 0 ? (*(pxISRHandle) = pxTraceISRInfo->coreInfos[TRC_CFG_GET_CURRENT_CORE()].handleStack[xTraceISRGetCurrentNestingReturned()], TRC_SUCCESS) : TRC_FAIL) |
Gets current trace ISR nesting level. More... | |
Functions | |
traceResult | xTraceISRRegister (const char *szName, uint32_t uiPriority, TraceISRHandle_t *pxISRHandle) |
Registers trace ISR. More... | |
traceResult | xTraceISRBegin (TraceISRHandle_t xISRHandle) |
Registers the beginning of an Interrupt Service Routine. More... | |
traceResult | xTraceISREnd (TraceBaseType_t xIsTaskSwitchRequired) |
Registers the end of an Interrupt Service Routine. More... | |
#define xTraceISRGetCurrent | ( | pxISRHandle | ) | (xTraceISRGetCurrentNestingReturned() >= 0 ? (*(pxISRHandle) = pxTraceISRInfo->coreInfos[TRC_CFG_GET_CURRENT_CORE()].handleStack[xTraceISRGetCurrentNestingReturned()], TRC_SUCCESS) : TRC_FAIL) |
Gets current trace ISR nesting level.
This routine gets the current trace ISR nesting level for the CPU on which it is called.
[out] | puiValue | Value. |
TRC_FAIL | Failure |
TRC_SUCCESS | Success |
#define xTraceISRGetCurrentNesting | ( | puiValue | ) | TRC_COMMA_EXPR_TO_STATEMENT_EXPR_2(*(puiValue) = pxTraceISRInfo->coreInfos[TRC_CFG_GET_CURRENT_CORE()].stackIndex, TRC_SUCCESS) |
Gets current trace ISR nesting level.
This routine gets the current trace ISR nesting level for the CPU on which it is called.
[out] | puiValue | Value. |
TRC_FAIL | Failure |
TRC_SUCCESS | Success |
#define xTraceISRGetCurrentNestingReturned | ( | ) | (pxTraceISRInfo->coreInfos[TRC_CFG_GET_CURRENT_CORE()].stackIndex) |
traceResult xTraceISRBegin | ( | TraceISRHandle_t | xISRHandle | ) |
Registers the beginning of an Interrupt Service Routine.
This routine register the beginning of an ISR using a TraceISRHandle_t. See xTraceISRRegister for and example of using ISR tracing.
[in] | xISRHandle | Pointer to initialized ISR trace handle. |
TRC_FAIL | Failure |
TRC_SUCCESS | Success |
traceResult xTraceISREnd | ( | TraceBaseType_t | xIsTaskSwitchRequired | ) |
Registers the end of an Interrupt Service Routine.
This routine register the end of an ISR using a TraceISRHandle_t. See xTraceISRRegister for and example of using ISR tracing.
The parameter uxIsTaskSwitchRequired indicates if the interrupt has requested a task-switch (= 1), e.g., by signaling a semaphore. Otherwise (= 0) the interrupt is assumed to return to the previous context.
[in] | xIsTaskSwitchRequired | Task switch required. |
TRC_FAIL | Failure |
TRC_SUCCESS | Success |
traceResult xTraceISRRegister | ( | const char * | szName, |
uint32_t | uiPriority, | ||
TraceISRHandle_t * | pxISRHandle | ||
) |
Registers trace ISR.
This routine stores a name and priority level for an Interrupt Service Routine, to allow for better visualization. Returns a TraceISRHandle_t used by xTraceISRBegin/xTraceISREnd.
Example: #define PRIO_OF_ISR_TIMER1 3 // the hardware priority of the interrupt TraceISRHandle_t xISRTimer1Handle = 0; // The ID set by the recorder ... xTraceISRRegister("ISRTimer1", PRIO_OF_ISR_TIMER1, &xISRTimer1Handle); ... void ISR_handler() { xTraceISRBegin(xISRTimer1Handle); ... xTraceISREnd(0); }
[in] | szName | Name. |
[in] | uiPriority | Priority. |
[out] | pxISRHandle | Pointer to uninitialized ISR trace handle. |
TRC_FAIL | Failure |
TRC_SUCCESS | Success |