PRD_getticks
2-294
C Interface
Syntax
num = PRD_getticks();
Parameters
Void
Return Value
LgUns
num
/* current tick counter */
Reentrant
yes
Description
PRD_getticks returns the current period tick count as a 32-bit value.
If the periodic functions are being driven by the on-device timer, the tick
value is the number of low resolution clock ticks that have occurred since
the program started running. When the number of ticks reaches the
maximum value that can be stored in 32 bits, the value wraps back to 0.
See the CLK Module, page 2–39, for more details.
If the periodic functions are being driven programmatically, the tick value
is the number of times PRD_tick has been called.
Example
/* ======== showTicks ======== */
Void showTicks
{
LOG_printf(&trace, "ticks = %d",
PRD_getticks
()
);
}
See Also
PRD_start
PRD_tick
CLK_gethtime
CLK_getltime
STS_delta
PRD_getticks
Get the current tick count