OS_GetTick

C Specification

#include <nitro/os.h>
OSTick OS_GetTick( void );
  

Arguments

None.

Return Values

The tick value.

Description

This function acquires the tick value. Tick must be initialized with OS_InitTick before calling this function.
The OSTick tick type is u64.

Internally, this function creates a tick value from the 16-bit timer counter value and the timer's interrupt count counter. Accordingly, if interrupts are disabled for a long period (more than 65536 * OS_SYSTEM_CLOCK/64 Hz or approximately 7.5 frames) the counter will fail to advance, and the difference between the tick value before and after will be inconsistent.

See Also

OS_InitTick, OS_SetTick, OS_GetTickLo

Revision History

04/18/2005 Added warning about disabling interrupts for long periods
02/25/2004 Changed systemClock -> tick
02/23/2004 Changed the system clock value to a full 64 bit
02/04/2004 Initial version