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.
Dependents: DetectFreqAboveTH RN41
Diff: myTimer.cpp
- Revision:
- 1:685c0f37a569
- Parent:
- 0:04c9087b9ca9
- Child:
- 2:3060a6604f13
--- a/myTimer.cpp Wed Sep 02 04:35:03 2015 +0000
+++ b/myTimer.cpp Sun Sep 27 11:44:47 2015 +0000
@@ -40,4 +40,13 @@
this->start();
return ans;
+}
+
+void myTimer::wait_ms(int waitTime, bool _START, bool _RESET, bool _STOP)
+{
+ int wt= waitTime- this->read_ms(_START, _RESET, _STOP);
+ if(wt <= 0)
+ return;
+ wait_ms(wt);
+ return;
}
\ No newline at end of file