test
Dependencies: mbed ros_lib_kinetic nhk19mr2_can_info splitData SerialHalfDuplex_HM
OneLeg.h
00001 #ifndef INCLUDED_ONELEG_H 00002 #define INCLUDED_ONELEG_H 00003 ///足先の座標を保存するクラス。x,yやサーボの角度の保存を行う。他の足を考慮した処理は別のクラスに任せる。 00004 class OneLeg 00005 { 00006 float rad_[2]; //足についてるサーボの目標角度。 00007 float x_m_; 00008 float y_m_; 00009 float between_servo_half_m_; 00010 float leglength1_[2]; 00011 float leglength2_[2]; 00012 void SetRad(float rad, int servo_num); 00013 00014 public: 00015 OneLeg(){}; 00016 OneLeg(float between_servo_half_m, float leglength1[2], float leglength2[2]); 00017 void MoveServo(int servo_num); 00018 float GetRad(int servo_num); 00019 float GetX_m(); 00020 float GetY_m(); 00021 int SetXY_m(float x_m, float y_m); 00022 }; 00023 00024 #endif
Generated on Thu Jul 14 2022 13:15:26 by 1.7.2