Final

Dependencies:   mbed

Fork of MiniProject5_LightTracker by Austin Sloop

Revision:
6:992875df04f7
Child:
7:30afa5506e74
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/ServoControl.cpp	Mon Jan 11 21:57:16 2016 +0000
@@ -0,0 +1,15 @@
+//Control Function for servo
+
+#include ServoControl.h
+
+PwnOut ServoSignal(p21);            //P21 is PWM signal out to servo 
+
+void ServoInit(void){
+    ServoSignal.period(0.020);
+}
+
+float ServoSignal(float angle){
+    ServoSignal.pulsewidth_us(1500+10*angle);
+    
+}
+