wavelength 1.0.0
Loading...
Searching...
No Matches
periodictimer.h
Go to the documentation of this file.
1#pragma once
2
9public:
18 static unsigned int Handler(void *common);
19
27 int Init();
28
36 int Start();
37
45 int Free();
46
54 int Stop();
55
56 int mThread;
57 int mTimer;
58 unsigned int mInterval;
59};
60
70int CreateThreadWithPriority(void (*entry)(), int priority);
71
79void StartTickThread(void (*entry)());
80
A hardware timer that wakes one thread at a fixed interval.
Definition periodictimer.h:8
int Stop()
Stop the timer.
unsigned int mInterval
Definition periodictimer.h:58
int mTimer
Definition periodictimer.h:57
int Init()
Allocate a 32-bit system clock timer with Handler() at a 6 millisecond interval.
int Free()
Release the timer.
int mThread
Definition periodictimer.h:56
int Start()
Start the timer.
static unsigned int Handler(void *common)
Wake the timer's thread.
void StartTickThread(void(*entry)())
Start a thread the tick timer wakes every 6 milliseconds.
int CreateThreadWithPriority(void(*entry)(), int priority)
Create a dormant C thread with a 2 KiB stack.
void StopTickThread()
Stop and release the tick timer, and delete the lock.