Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: Task.h
- Revision:
- 1:e95b703c6ad7
- Parent:
- 0:e381c3adaa04
- Child:
- 2:3cb7f5770feb
--- a/Task.h Fri Jan 14 19:51:13 2011 +0000
+++ b/Task.h Fri Jan 14 20:04:13 2011 +0000
@@ -5,6 +5,7 @@
#define DEFAULT_INTERVAL 1000 //1ms
+
class Task
{
@@ -12,8 +13,12 @@
Task();
Task(int _interval);
+
void start();
virtual void tick() = 0;
+ void stop();
+
+ bool isRunning() { return running; }
protected:
@@ -25,6 +30,7 @@
Ticker ticker;
int interval;
+ bool running;
void preTick();