RTEMS 6.1-rc1
Data Structures | Typedefs | Functions
timetick.h File Reference
#include <stdint.h>

Go to the source code of this file.

Data Structures

struct  SyTickDelayCounter_t
 
struct  _TimeEvent
 

Typedefs

typedef struct _TimeEvent TimeEvent
 

Functions

uint32_t TimeTick_Configure (void)
 
void TimeTick_Increment (uint32_t dwInc)
 
uint32_t GetDelayInTicks (uint32_t startTick, uint32_t endTick)
 
uint32_t GetTicks (void)
 
void Wait (volatile uint32_t dwMs)
 
void Sleep (volatile uint32_t dwMs)
 
void SetTimeEvent (TimeEvent *pEvent)
 

Detailed Description

Purpose

Methods and definitions for Global time tick and wait functions.

Defines a common and simplest use of Time Tick, to increase tickCount every 1ms, the application can get this value through GetTickCount().

Usage
  1. Configure the System Tick with TimeTick_Configure() when MCK changed
    Note
    Must be done before any invoke of GetTickCount(), Wait() or Sleep().
  2. Uses GetTickCount to get current tick value.
  3. Uses Wait to wait several ms.
  4. Uses Sleep to enter wait for interrupt mode to wait several ms.