Servo

Dependencies:   mbed MODSERIAL Servo FastPWM

Revision:
0:60a8a60074a7
Child:
1:f6898c9b8c44
diff -r 000000000000 -r 60a8a60074a7 main.cpp
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Fri Oct 11 08:16:22 2019 +0000
@@ -0,0 +1,26 @@
+#include "mbed.h"
+//#include "HIDScope.h"
+//#include "QEI.h"
+#include "MODSERIAL.h"
+//#include "BiQuad.h"
+#include "FastPWM.h"
+//#include <math.h>
+#include "Servo.h"
+
+Serial pc(USBTX, USBRX);
+
+Servo servomotor(D3);
+
+int main()
+{ 
+    
+    while( true ) 
+    { 
+        servomotor.write(0.2);
+        wait(0.5);
+        servomotor.write(0.4);
+        wait(0.5);
+        pc.printf("hello");
+    }
+    return 0;
+}
\ No newline at end of file