31 #include <selforg/inspectable.h>
32 #include <ode_robots/contactsensor.h>
33 #include <ode_robots/torquesensor.h>
37 #include <ode_robots/joint.h>
38 #include <ode_robots/oneaxisservo.h>
39 #include <ode_robots/twoaxisservo.h>
40 #include <ode_robots/spring.h>
44 using namespace ASHIGARU;
45 using namespace lpzrobots;
145 double rate;// What rate should I multiple to real length number
146 double massRate; // what rate should I multiple to real mass number
147 double connectLength; // Length between center of the robot and that of another robot when they are connected each other.
148 double wholeMass; // the whole mass of the robot
150 DynaAX12Conf dyna; // Dynamixel's real configuration
151 HexagonBodyConf body; // Body's real config.
152 FootFrameConf foot; // foot's real config.
153 JointLength jLength; // joint length param
154 ServoParam servoParam; // parameter for servo
168 L0, L1, L2, LEG_POS_MAX
209 virtual void update();
227 virtual int getSensorsIntern(
sensor* sensors,
int sensornumber);
233 virtual void setMotorsIntern(
const double* motors,
int motornumber);
251 virtual int getSegmentsPosition(std::vector<Position> &poslist);
258 virtual void doInternalStuff(
GlobalData& globalData);
260 virtual void sense(
GlobalData& globalData)
override;
273 virtual void destroy();
283 void nameMotor(
const int motorNo,
const char* name);
293 void nameSensor(
const int sensorNo,
const char* name);
300 osg::Vec3d convert_Quat_to_RollPitchYaw(osg::Quat quat);
303 osg::Vec3d calc_COGPosition(
void);
364 typedef std::map<MotorName, OneAxisServo*>
MotorMap;
365 typedef std::map<MotorName, TorqueSensor*>
MTorqMap;
MTorqMap motorTorqSensors
Definition: ashigaru.h:399
virtual double & getContactPoints()
Definition: ashigaru.h:263
Data structure for accessing the ODE.
Definition: odehandle.h:44
Class for sensing the torque that are applied to the joint by a motor.
Definition: torquesensor.h:37
Primitive * footSphere
Definition: ashigaru.h:341
OneAxisServo * tcServo
Definition: ashigaru.h:331
Primitive * femur
Definition: ashigaru.h:338
Matrixd Matrix
Definition: osgforwarddecl.h:47
ImpTransform * shoulder
Definition: ashigaru.h:335
OneAxisServo * ftServo
Definition: ashigaru.h:333
std::map< LegPos, ContactSensor * > LegContactMap
Definition: ashigaru.h:363
std::vector< Joint * > JointList
Definition: ashigaru.h:370
double sensor
Definition: types.h:29
OneAxisServo * ctServo
Definition: ashigaru.h:332
Definition: ashigaru.h:172
SliderJoint * footJoint
Definition: ashigaru.h:330
Data structure for accessing the OpenSceneGraph.
Definition: osghandle.h:79
HingeJoint * ctJoint
Definition: ashigaru.h:328
Spring * footSpring
Definition: ashigaru.h:334
ServoList passiveServos
Definition: ashigaru.h:390
int motorno
Definition: ashigaru.h:375
std::map< LegPos, Leg > LegMap
Definition: ashigaru.h:362
Primitive * coxa
Definition: ashigaru.h:337
bool created
Definition: ashigaru.h:358
std::vector< OneAxisServo * > ServoList
Definition: ashigaru.h:371
std::map< MotorName, TorqueSensor * > MTorqMap
Definition: ashigaru.h:365
Robot ASHIGARU :-) 3 legged robot which could be easily connected each other.
Definition: ashigaru.h:164
osg::Matrix Pose
Definition: pose.h:35
Definition: ashigaru.h:183
AshigaruSensorNames
Definition: ashigarusensormotordefinition.h:27
LegPosUsage
Definition: ashigaru.h:171
LegContactMap legContactSensors
Definition: ashigaru.h:398
Interface class for primitives represented in the physical and graphical world.
Definition: primitive.h:80
Definition: ashigaru.h:177
Trunk trunk
Definition: ashigaru.h:378
Data structure holding all essential global information.
Definition: globaldata.h:57
MotorMap servos
Definition: ashigaru.h:393
Leg struct.
Definition: ashigaru.h:325
ImpTransform * tUpTrans
Definition: ashigaru.h:351
LegPos
Definition: ashigaru.h:167
Interface for inspectable objects.
Definition: inspectable.h:48
ImpTransform * foot
Definition: ashigaru.h:340
virtual int getMotorNumberIntern()
returns number of motors
Definition: ashigaru.h:243
double contactPoints
Definition: ashigaru.h:355
std::map< MotorName, OneAxisServo * > MotorMap
Definition: ashigaru.h:364
LegMap legs
Definition: ashigaru.h:381
LegJointType
Definition: ashigaru.h:175
AshigaruSensorNames SensorName
Definition: ashigaru.h:190
AshigaruConf conf
Inspectable interface.
Definition: ashigaru.h:321
Abstract class for ODE robots.
Definition: oderobot.h:64
std::map< LegPos, HingeJoint * > HingeJointMap
typedefs
Definition: ashigaru.h:361
std::vector< Primitive * > PrimitiveList
Definition: ashigaru.h:369
AshigaruMotorNames
Definition: ashigarusensormotordefinition.h:112
double sensor
Definition: abstractrobot.h:43
Definition: ashigaru.h:180
HingeJoint * tcJoint
Definition: ashigaru.h:327
HingeJoint * ftJoint
Definition: ashigaru.h:329
>ASHIGARU Configuration struct
Definition: ashigarusensormotordefinition.h:222
AshigaruMotorNames MotorName
Definition: ashigaru.h:188
Primitive * shoulderBox
Definition: ashigaru.h:336
Primitive * tibia
Definition: ashigaru.h:339
int sensorno
Definition: ashigaru.h:374
general servo motor to achieve position control
Definition: oneaxisservo.h:38
virtual int getSensorNumberIntern()
returns number of sensors
Definition: ashigaru.h:237
Trunk struct.
Definition: ashigaru.h:347