test

Dependencies:   mbed ros_lib_kinetic nhk19mr2_can_info splitData SerialHalfDuplex_HM

Committer:
shimizuta
Date:
Mon Mar 11 10:38:07 2019 +0000
Revision:
50:36741e8ab197
Parent:
27:79b4b932a6dd
a

Who changed what in which revision?

UserRevisionLine numberNew contents of line
shimizuta 11:e81425872740 1 #ifndef INCLUDED_ONELEG_H
shimizuta 11:e81425872740 2 #define INCLUDED_ONELEG_H
shimizuta 11:e81425872740 3 ///足先の座標を保存するクラス。x,yやサーボの角度の保存を行う。他の足を考慮した処理は別のクラスに任せる。
shimizuta 11:e81425872740 4 class OneLeg
shimizuta 11:e81425872740 5 {
shimizuta 27:79b4b932a6dd 6 float rad_[2]; //足についてるサーボの目標角度。
shimizuta 27:79b4b932a6dd 7 float x_m_;
shimizuta 27:79b4b932a6dd 8 float y_m_;
shimizuta 27:79b4b932a6dd 9 float between_servo_half_m_;
shimizuta 27:79b4b932a6dd 10 float leglength1_[2];
shimizuta 27:79b4b932a6dd 11 float leglength2_[2];
shimizuta 27:79b4b932a6dd 12 void SetRad(float rad, int servo_num);
shimizuta 11:e81425872740 13
shimizuta 27:79b4b932a6dd 14 public:
shimizuta 27:79b4b932a6dd 15 OneLeg(){};
shimizuta 27:79b4b932a6dd 16 OneLeg(float between_servo_half_m, float leglength1[2], float leglength2[2]);
shimizuta 27:79b4b932a6dd 17 void MoveServo(int servo_num);
shimizuta 27:79b4b932a6dd 18 float GetRad(int servo_num);
shimizuta 27:79b4b932a6dd 19 float GetX_m();
shimizuta 27:79b4b932a6dd 20 float GetY_m();
shimizuta 27:79b4b932a6dd 21 int SetXY_m(float x_m, float y_m);
shimizuta 11:e81425872740 22 };
shimizuta 11:e81425872740 23
shimizuta 11:e81425872740 24 #endif