調整中

Dependencies:   mbed HMC6352 US015 TB6612FNG2 getGPS ATP3011

Committer:
user_
Date:
Wed Oct 27 06:47:49 2021 +0000
Revision:
13:38c5ffe5873a
Parent:
10:0433f48faf74
test;

Who changed what in which revision?

UserRevisionLine numberNew contents of line
user_ 10:0433f48faf74 1 #ifndef _ROTATE_H_
user_ 10:0433f48faf74 2 #define _ROTATE_H_
user_ 10:0433f48faf74 3
user_ 10:0433f48faf74 4 #include "MotorDriver.h"
user_ 10:0433f48faf74 5 #include "mbed.h"
user_ 10:0433f48faf74 6
user_ 13:38c5ffe5873a 7 void ROttate(double angle){
user_ 13:38c5ffe5873a 8 // double time = angle; // 試験で調整してください。
user_ 13:38c5ffe5873a 9 int time = 3; // 試験用のため適当
user_ 13:38c5ffe5873a 10 if (angle > 0) {
user_ 13:38c5ffe5873a 11 MotorDriver('5', 1);
user_ 13:38c5ffe5873a 12 wait(time);
user_ 13:38c5ffe5873a 13 MotorDriver('1', 0);
user_ 13:38c5ffe5873a 14 } elif (angle < 0) {
user_ 13:38c5ffe5873a 15 MotorDriver('6', 1);
user_ 13:38c5ffe5873a 16 wait(time);
user_ 13:38c5ffe5873a 17 MotorDriver('1', 0);
user_ 13:38c5ffe5873a 18 }
user_ 13:38c5ffe5873a 19 }
user_ 10:0433f48faf74 20
user_ 10:0433f48faf74 21 #endif