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 4:8b83bf379766, committed 2019-12-13
- Comitter:
- smallstone
- Date:
- Fri Dec 13 07:01:49 2019 +0000
- Parent:
- 3:f99d3703a6d9
- Commit message:
- kansat shuusei
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Wed Dec 04 14:09:14 2019 +0000 +++ b/main.cpp Fri Dec 13 07:01:49 2019 +0000 @@ -5,41 +5,36 @@ TB6612 motor2(p23,p28,p27); //pwmb,BIN1,BIN2,can brake// int main() { - wait(10); - motor1=20; - motor2=20; - wait(10); - motor1=0; + motor1=0; //初期はスピード0 motor2=0; wait(20); - motor1=40; - motor2=40; - wait(10); - motor1=0; + motor1=20; //スピード20% + motor2=20; + wait(20); + motor1=0; //スピードをリセットし、次の準備時間 motor2=0; wait(20); - motor1=60; - motor2=60; - wait(10); - motor1=0; + motor1=40; //スピード40% + motor2=40; + wait(20); + motor1=0; //スピードをリセットし、次の準備時間 motor2=0; wait(20); - motor1=80; - motor2=80; - wait(10); - motor1=0; - motor2=0; - motor1=80; - motor2=80; - wait(10); - motor1=0; + motor1=60; //スピード60% + motor2=60; + wait(20); + motor1=0; //スピードをリセットし、次の準備時間 motor2=0; wait(20); - motor1=100; - motor2=100; - wait(10); - motor1=0; + motor1=80; //スピード80% + motor2=80; + wait(20); + motor1=0; //スピードをリセットし、次の準備時間 motor2=0; wait(20); - + motor1=100; //スピード100% + motor2=100; + wait(20); + motor1=0; //スピードをリセットし、次の準備時間 + motor2=0; }