28 #include <ode_robots/primitive.h>
29 #include <ode_robots/joint.h>
30 #include <ode_robots/oneaxisservo.h>
31 #include <ode_robots/oderobot.h>
32 #include <ode_robots/sensor.h>
33 #include <ode_robots/raysensorbank.h>
108 const std::string& name,
const std::string& revision,
double transparency);
Class for a bank (collection) of ray sensors.
Definition: raysensorbank.h:36
unsigned int numAxes
number of axes with moving masses
Definition: discus.h:43
Data structure for accessing the ODE.
Definition: odehandle.h:44
double transparency
Definition: discus.h:91
virtual int getSensorNumberIntern()
overload this function in a subclass to specific the number of custom sensors
Definition: discus.cpp:183
SliderServo * servo[maxservono]
Definition: discus.h:85
virtual void setMotorsIntern(const double *motors, int motornumber)
overload this function in a subclass to do specific sensor handling, not needed for generic motors ...
Definition: discus.cpp:148
static DiscusConf getDefaultConf()
default configuration
Definition: discus.h:116
double irCharacter
characteristics of sensor ( where x is the range-distance)
Definition: discus.h:58
Matrixd Matrix
Definition: osgforwarddecl.h:47
Interface class for graphic primitives like spheres, boxes, and meshes, which can be drawn by OSG...
Definition: osgprimitive.h:62
double stabdiameter
diameter of capsule relative to diameter of body
Definition: discus.h:42
virtual ~Discus()
Definition: discus.cpp:90
double spheremass
Definition: discus.h:44
bool irSide
4 IR senors to both side in y direction (collides with irAxis2)
Definition: discus.h:55
double sensor
Definition: types.h:29
Discus(const OdeHandle &odeHandle, const OsgHandle &osgHandle, const DiscusConf &conf, const std::string &name, double transparency=0.5)
constructor
Definition: discus.cpp:53
configuration object for the Discus robot.
Definition: discus.h:38
bool irAxis2
Definition: discus.h:52
Data structure for accessing the OpenSceneGraph.
Definition: osghandle.h:79
virtual void update()
update the OSG notes here, if overwritten, call OdeRobot::update()!
Definition: discus.cpp:96
Abstract class for sensors that can be plugged into a robot.
Definition: sensor.h:43
double motorpowerfactor
power factor for servos w.r.t. pendularmass
Definition: discus.h:47
virtual void sense(GlobalData &globalData) override
this function is called each controlstep before control.
Definition: discus.cpp:162
bool irAxis3
Definition: discus.h:53
bool drawIRs
Definition: discus.h:56
SliderJoint * joint[maxservono]
Definition: discus.h:86
double pendularrange
fraction of the diameter the pendular masses can move to one side
Definition: discus.h:48
bool irRing
IR sensors in a ring in x,z plane (collides with irAxis1 and irAxis3)
Definition: discus.h:54
std::list< Sensor * > sensors
list of sensors that are mounted at the robot. (e.g. AxisOrientationSensor)
Definition: discus.h:66
OSGPrimitive * axis[maxservono]
Definition: discus.h:87
Interface class for primitives represented in the physical and graphical world.
Definition: primitive.h:80
RaySensor * irSensorTempl
template for creation of the other ir sensors (if 0 then IRSensor(irCharacter))
Definition: discus.h:59
double motor_ir_before_sensors
if true motor sensors and ir sensors are given before additional sensors
Definition: discus.h:60
bool irAxis1
Definition: discus.h:51
Data structure holding all essential global information.
Definition: globaldata.h:57
std::list< SensorAttachment > sensors
Definition: oderobot.h:269
double pendularrangeN
fraction of the diameter the normal pendular masses can move to one side
Definition: discus.h:49
virtual void placeIntern(const osg::Matrix &pose)
wrapper to for
Definition: discus.cpp:156
void addSensor(Sensor *s)
adds a sensor to the list of sensors
Definition: discus.h:68
double irsensorscale
range of the ir sensors in units of diameter
Definition: discus.h:57
double diameter
Definition: discus.h:40
bool motorsensor
motor values as sensors
Definition: discus.h:50
double brake
if nonzero the robot brakes (deaccelerates actively/magically) (velocity dependend torque) ...
Definition: discus.h:61
A spherical robot with 3 internal masses, which can slide on their orthogonal axes.
Definition: discus.h:75
OsgHandle osgHandle
Definition: oderobot.h:278
RaySensorBank irSensorBank
a collection of ir sensors
Definition: discus.h:90
OdeHandle odeHandle
Definition: oderobot.h:277
double pendulardiameter
automatically set
Definition: discus.h:45
virtual int getSensorsIntern(sensor *sensors, int sensornumber)
Writes the sensor values to an array in the memory.
Definition: discus.cpp:116
Abstract class for ODE robots.
Definition: oderobot.h:64
void init()
initialises some internal variables
Definition: discus.cpp:80
virtual Primitive * getMainPrimitive() const
return the primitive of the robot that is used for tracking and camera following
Definition: discus.h:158
double pendularmass
Definition: discus.h:46
objects
enum for the objects of the robot
Definition: discus.h:79
bool created
Definition: discus.h:92
double relativewidth
Definition: discus.h:41
static const int maxservono
Definition: discus.h:82
general servo motor to achieve position control
Definition: oneaxisservo.h:38
virtual void doInternalStuff(GlobalData &globalData)
this function is called in each simulation timestep (always after control).
Definition: discus.cpp:168
virtual void create(const osg::Matrix &pose)
creates vehicle at desired position and orientation
Definition: discus.cpp:194
std::list< MotorAttachment > motors
Definition: oderobot.h:270
Class for Ray-based sensors.
Definition: raysensor.h:54
virtual void destroy()
destroys vehicle and space
Definition: discus.cpp:315
int c
Definition: hexapod.cpp:56
DiscusConf conf
Definition: discus.h:89
virtual int getMotorNumberIntern()
overload this function in a subclass to specific the number of custom sensors
Definition: discus.cpp:179