広田 勇斗
/
Omni_2017_a
Omni_2017_a
Fork of Omni_2017_z by
Diff: 2017_3/2017_3_z.h
- Revision:
- 2:82c337a18500
- Parent:
- 1:fa8227369eb0
diff -r fa8227369eb0 -r 82c337a18500 2017_3/2017_3_z.h --- a/2017_3/2017_3_z.h Sat Aug 05 02:36:16 2017 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,27 +0,0 @@ -#ifndef _OMNI_3_H_ -#define _OMNI_3_H_ -#include "mbed.h" -#include "MD.h" -#include "MD_PID.h" - -class Omni_3{ -public: - Omni_3(PinName pin_pwm_F1, PinName pin_pwm_F2, PinName pin_dere_F1, PinName pin_dere_F2, PinName pin_channelA_F, PinName pin_channelB_F, - PinName pin_pwm_L1, PinName pin_pwm_L2, PinName pin_dere_L1, PinName pin_dere_L2, PinName pin_channelA_L, PinName pin_channelB_L, - PinName pin_pwm_R1, PinName pin_pwm_R2, PinName pin_dere_R1, PinName pin_dere_R2, PinName pin_channelA_R, PinName pin_channelB_R, - int rev = 1); - void Drive( double arg_x, double arg_y, double arg_rota, - double F_Gain = 1.0, double L_Gain = 1.0, double R_Gain = 1.0); - -private: - void Matrix(double speed[3], double duty[3]); - int rev; - MD_PID *md_f1; - MD_PID *md_f2; - MD_PID *md_l1; - MD_PID *md_l2; - MD_PID *md_r1; - MD_PID *md_r2; -}; -#endif -