![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
u
Revision 0:8793e3992715, committed 2020-08-25
- Comitter:
- 20172573073
- Date:
- Tue Aug 25 16:25:26 2020 +0000
- Commit message:
- u;
Changed in this revision
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Servo.lib Tue Aug 25 16:25:26 2020 +0000 @@ -0,0 +1,1 @@ +https://os.mbed.com/users/jdenkers/code/Servo/#352133517ccc
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Tue Aug 25 16:25:26 2020 +0000 @@ -0,0 +1,20 @@ + #include "mbed.h" + #include "Servo.h" + + Servo Servo1(A5); +int main(){ + Servo1.Enable(1500,20000); + + while(1) { + wait(5); + for (int pos = 1000; pos < 2000; pos += 25) { + + Servo1.SetPosition(pos); + wait_ms(20); + }wait(5); + for (int pos = 2000; pos > 1000; pos -= 25) { + Servo1.SetPosition(pos); + wait_ms(20); + } + } + } \ No newline at end of file
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Tue Aug 25 16:25:26 2020 +0000 @@ -0,0 +1,1 @@ +https://os.mbed.com/users/mbed_official/code/mbed/builds/65be27845400 \ No newline at end of file