53#define sgn(x) (((x) == 0.0) ? 0.0 : ((x) / fabs(x)))
54#define pi (4 * atan(1.0))
75 virtual double getX()
override;
83 virtual double getY()
override;
91 virtual double getZ()
override;
138 virtual int command(
int argc,
const char *
const *argv)
override;
148 virtual void setdest(
double x_dest,
double y_dest,
double z_dest,
double speed);
158 virtual void setdest(
double x_dest,
double y_dest,
double z_dest);
173 virtual void setX(
double x)
override;
181 virtual void setY(
double y)
override;
189 virtual void setZ(
double z)
override;
197 virtual void update(
double now);
virtual void setY(double y) override
Set the projection on y-axis of the node postion.
virtual double getY() override
Get the current projection on y-axis of the node postion If necessary (updating time expired),...
double lastUpdateTime_
Time when last update of the coordinates was computed.
virtual void setZ(double z) override
Set the projection on z-axis of the node postion.
virtual bool isDestReached() const
UWSMPosition()
UWSMPosition constructor.
virtual void update(double now)
Update both the current position coordinates.
virtual double getX() override
Get the current projection on x-axis of the node postion If necessary (updating time expired),...
double getSpeed() const
Get the current speed of the node.
virtual double getZdest() const
Get the z coordinate of the destination point.
virtual double getYdest() const
Get the y coordinate of the destination point.
double speed_
Speed of the node.
virtual void setdest(double x_dest, double y_dest, double z_dest, double speed)
virtual int command(int argc, const char *const *argv) override
TCL command interpreter.
double Zdest_
Position along z-axis of the destination point.
double trgTime_
Time when the TCL command setdest is invoked.
virtual void setX(double x) override
Set the projection on x-axis of the node postion.
virtual double getXdest() const
Get the x coordinate of the destination point.
virtual ~UWSMPosition()=default
UWSMPosition destructor.
double Xdest_
Position along x-axis of the destination point.
double Ydest_
Position along y-axis of the destination point.
virtual double getZ() override
Get the current projection on z-axis of the node postion If necessary (updating time expired),...
double Xsorg_
Position along x-axis of the starting point.
double Zsorg_
Position along z-axis of the starting point.
double Ysorg_
Position along y-axis of the starting point.