Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Revision 1:679934743c5e, committed 2019-09-28
- Comitter:
- b28nguye
- Date:
- Sat Sep 28 17:28:05 2019 +0000
- Parent:
- 0:110dc3bbf9c1
- Commit message:
- import to Mbed Studio
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 |
--- a/Servo.lib Fri Sep 27 15:21:03 2019 +0000 +++ b/Servo.lib Sat Sep 28 17:28:05 2019 +0000 @@ -1,1 +1,1 @@ -https://os.mbed.com/users/simon/code/Servo/#22b2abaa0f44 +https://os.mbed.com/users/b28nguye/code/Servo/#22b2abaa0f44
--- a/main.cpp Fri Sep 27 15:21:03 2019 +0000
+++ b/main.cpp Sat Sep 28 17:28:05 2019 +0000
@@ -1,6 +1,7 @@
// Continuously sweep the servo through it's full range
#include "mbed.h"
#include "Servo.h"
+#include "stdio.h"
Servo servo_1(D3);
Servo servo_2(D5);
@@ -44,13 +45,17 @@
}
int main() {
- printf ("test start");
+ printf ("\n test start\n");
wait(1.0);
//test_write(servo_1);
- test_position(servo_1);
+ //test_position(servo_1);
int x = 0;
+ char n;
+ int y;
while (1){
- printf ("Test %d ", x);
+ printf ("Test %d \n", x);
x +=1;
+ scanf("%1c", &n);
+ printf("You said, %c \n", n);
}
}
\ No newline at end of file