positive or negative pulse width counter

Dependents:   test_hw_biniou

Revision:
1:d37d6388c179
Parent:
0:89bd4ad6027d
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/PulseWidthCounter.h	Thu Jul 11 19:15:42 2013 +0000
@@ -0,0 +1,22 @@
+#ifndef PULSEWIDTHCOUNTER_H
+#define PULSEWIDTHCOUNTER_H
+#define POSITIVE true
+#define NEGATIVE false
+
+#include "mbed.h"
+
+class PulseWidthCounter  
+{
+private:
+    Timer _time;
+    void start();
+    void stop();
+    InterruptIn interrupt;
+
+public:
+ //   Timer time;
+    PulseWidthCounter(PinName,bool); 
+
+    int count;
+};
+#endif
\ No newline at end of file