Bresdin O'Malley / Mbed 2 deprecated servo_control_shield_v1

Dependencies:   Servo mbed

Files at this revision

API Documentation at this revision

Comitter:
bomalley
Date:
Thu Mar 12 18:31:10 2015 +0000
Commit message:
Servo control for shield NMHU (New Mexico Highlands University) KL-46Z.; This will control two servos. at the same time back and forth.

Changed in this revision

Servo.lib Show annotated file Show diff for this revision Revisions of this file
main.cpp Show annotated file Show diff for this revision Revisions of this file
mbed.bld Show annotated file Show diff for this revision Revisions of this file
diff -r 000000000000 -r 6138ceae43f5 Servo.lib
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Servo.lib	Thu Mar 12 18:31:10 2015 +0000
@@ -0,0 +1,1 @@
+http://developer.mbed.org/users/simon/code/Servo/#36b69a7ced07
diff -r 000000000000 -r 6138ceae43f5 main.cpp
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Thu Mar 12 18:31:10 2015 +0000
@@ -0,0 +1,24 @@
+#include "mbed.h"
+#include "Servo.h"
+
+#define WAITTIME 0.2
+
+/* 
+*   Written by: Bresdin O'Malley 2015
+*   Servo control for shield NMHU (New Mexico Highlands University) KL-46Z.
+*   This will control two servos.
+
+*/
+
+Servo myservo1(PTC9);
+Servo myservo2(PTC8);
+
+int main() { 
+while(true) {   
+    for(float p=0; p<1.0; p += 0.1) {
+        myservo1.write(p);
+        myservo2.write(p);
+        wait(WAITTIME);
+    }
+    }
+}
\ No newline at end of file
diff -r 000000000000 -r 6138ceae43f5 mbed.bld
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Thu Mar 12 18:31:10 2015 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/mbed_official/code/mbed/builds/7e07b6fb45cf
\ No newline at end of file