Vishal Kotcherlakota / TimerCapture

Dependents:   bluesync

Files at this revision

API Documentation at this revision

Comitter:
dishbreak
Date:
Wed Jun 10 06:21:13 2015 +0000
Parent:
3:4c06a8b54655
Commit message:
Tuning tick counter to behave correctly.;

Changed in this revision

TimerCapture.cpp Show annotated file Show diff for this revision Revisions of this file
diff -r 4c06a8b54655 -r 3ae9f68bae6a TimerCapture.cpp
--- a/TimerCapture.cpp	Thu May 21 08:34:46 2015 +0000
+++ b/TimerCapture.cpp	Wed Jun 10 06:21:13 2015 +0000
@@ -116,7 +116,7 @@
     LPC_SC->PCLKSEL1 |= (clockSel << 12);
     
     // Set prescaler counter
-    LPC_TIM2->PR = 100000; //should increment once a milisecond.
+    LPC_TIM2->PR = SystemCoreClock/1000; //should increment once a milisecond.
     
 }
        
\ No newline at end of file