OSDiffTick

Syntax

#include <revolution/os.h>

#define OSDiffTick(tick1, tick0)        ((s32) (tick1) - (s32) (tick0))

Arguments

tick1 Ticks at OS_TIMER_CLOCK Hz.
tick0 Ticks at OS_TIMER_CLOCK Hz.

Return Values

Time in ticks as a s32 value.

Description

Takes two tick values (returned by the OSGetTick function) and returns the difference between them, assuming that the tick values are s32-type. (In other words, tick1 - tick0.)

See Also

Time Functions, OSTicksToCycles, OSTicksToSeconds, OSTicksToMilliseconds, OSTicksToMicroseconds, OSSecondsToTicks, OSMicrosecondsToTicks

Revision History

2006/03/01 Initial version.


CONFIDENTIAL