Inherited by iCub::d4c::D4CClient, and iCub::d4c::D4CServer.
|
virtual bool | open (const yarp::os::Property &options)=0 |
| Configure the client or the server part of d4c framework. More...
|
|
virtual void | close ()=0 |
| Stop the client/server and dispose it. More...
|
|
virtual bool | addItem (const yarp::os::Property &options, int &item)=0 |
| Request for the creation of a new d4c entity which can be either a target or an obstacle. More...
|
|
virtual bool | eraseItem (const int item)=0 |
| Remove one item from the items table. More...
|
|
virtual bool | clearItems ()=0 |
| Purge all the items contained in the table. More...
|
|
virtual bool | getItems (yarp::os::Bottle &items)=0 |
| Retrieve the list of all available items. More...
|
|
virtual bool | setProperty (const int item, const yarp::os::Property &options)=0 |
| Allow changing the properties of an existing item. More...
|
|
virtual bool | getProperty (const int item, yarp::os::Property &options)=0 |
| Retrieve the properties of an existing item. More...
|
|
virtual bool | enableField ()=0 |
| Enable the generation of the d4c field. More...
|
|
virtual bool | disableField ()=0 |
| Disable the generation of the d4c field. More...
|
|
virtual bool | getFieldStatus (bool &status)=0 |
| Retrieve the current status of the d4c field. More...
|
|
virtual bool | enableControl ()=0 |
| Enable the control of the robot part. More...
|
|
virtual bool | disableControl ()=0 |
| Disable the control of the robot part. More...
|
|
virtual bool | getControlStatus (bool &status)=0 |
| Retrieve the current status of the robot part control. More...
|
|
virtual bool | enableSimulation ()=0 |
| Enable the simulation of the robot part. More...
|
|
virtual bool | disableSimulation ()=0 |
| Disable the simulation of the robot part. More...
|
|
virtual bool | getSimulationStatus (bool &status)=0 |
| Retrieve the current status of the robot part simulation. More...
|
|
virtual bool | setPeriod (const int period)=0 |
| Allow changing the thread period for d4c field generation. More...
|
|
virtual bool | getPeriod (int &period)=0 |
| Retrieve the current thread period for d4c field generation. More...
|
|
virtual bool | setPointStateToTool ()=0 |
| Allow setting the trajectory state equal to the currently attached tool state (or end-effector state if no tool is attached). More...
|
|
virtual bool | attachToolFrame (const yarp::sig::Vector &x, const yarp::sig::Vector &o)=0 |
| Attach a tool frame to the end-effector. More...
|
|
virtual bool | getToolFrame (yarp::sig::Vector &x, yarp::sig::Vector &o)=0 |
| Retrieve the frame of the tool currently attached to the end-effector. More...
|
|
virtual bool | removeToolFrame ()=0 |
| Remove the tool currently attached to the end-effector. More...
|
|
virtual bool | getTool (yarp::sig::Vector &x, yarp::sig::Vector &o)=0 |
| Retrieve the coordinates of the tool currently attached to the end-effector. More...
|
|
virtual bool | setPointState (const yarp::sig::Vector &x, const yarp::sig::Vector &o, const yarp::sig::Vector &xdot, const yarp::sig::Vector &odot)=0 |
| Allow chainging the trajectory state generated by the d4c framework. More...
|
|
virtual bool | setPointOrientation (const yarp::sig::Vector &o, const yarp::sig::Vector &odot)=0 |
| Allow changing the orientation state of the trajectory generated by the d4c framework. More...
|
|
virtual bool | getPointState (yarp::sig::Vector &x, yarp::sig::Vector &o, yarp::sig::Vector &xdot, yarp::sig::Vector &odot)=0 |
| Retrieve the current trajectory state generated by the d4c framework. More...
|
|
virtual bool | getField (yarp::sig::Vector &field)=0 |
| Retrieve the current field as generated by the d4c framework. More...
|
|
virtual bool | getSimulation (yarp::sig::Vector &xhat, yarp::sig::Vector &ohat, yarp::sig::Vector &qhat)=0 |
| Sample step by step the trajectory the end-effector will follow as constrained by the d4c field. More...
|
|
virtual bool | getActiveIF (std::string &activeIF)=0 |
| Retrieve the interface currently active that controls the limb. More...
|
|
virtual bool | setActiveIF (const std::string &activeIF)=0 |
| Set the active interface for limb control. More...
|
|
virtual bool | getTrajectory (std::deque< yarp::sig::Vector > &trajPos, std::deque< yarp::sig::Vector > &trajOrien, const unsigned int maxIterations=D4C_DEFAULT_MAXITERATIONS, const double Ts=D4C_DEFAULT_TS_DISABLED)=0 |
| Retrieve the complete simulated trajectory as evolved from the current state point. More...
|
|
virtual bool | executeTrajectory (const std::deque< yarp::sig::Vector > &trajPos, const std::deque< yarp::sig::Vector > &trajOrien, const double trajTime)=0 |
| Execute the simulated trajectory provided by the user. More...
|
|
virtual | ~D4C () |
| Destructor.
|
|
The Definition of the D4C Interface.
Definition at line 54 of file d4c.h.
virtual bool iCub::d4c::D4C::addItem |
( |
const yarp::os::Property & |
options, |
|
|
int & |
item |
|
) |
| |
|
pure virtual |
Request for the creation of a new d4c entity which can be either a target or an obstacle.
- Parameters
-
options | contains the set of options in form of a Property object. |
item | here is returned the unique item identifier to be used for later access. |
Options common to all items:
name <string>: example (name item_name), specifies the item name.
type <string>: example (type tag), specifies the item type on whose basis the configuration is properly carried out.
active <string>: example (active on), specifies whether the item should be taken into account for generating the field ("on") or not ("off").
center <(double(x) double(y) double(z))>: example (center (-0.3 0.0 0.1)), specifies the xyz position of the item wrt the robot's root reference frame.
orientation <(double(ax) double(ay) double(az) double(theta))>: example (orientation (1.0 0.0 0.0 3.14)), specifies the orientation of the item's frame in axis/angle representation given wrt the robot's root reference frame.
color <(double(r) double(g) double(b))>: example (color (255.0 0.0 0.0)), specifies the color of the ellipsoid in RGB format.
radius <(double(rx) double(ry) double(rz))>: example (radius (0.01 0.02 0.03)), specifies the dimension of the ellipsoid radii (in [m]) representing the item wrt item's reference frame.
The type "target_msd" implements a target acting as a mass-spring-damper system on the end-effector within the d4c framework.
Options specific to the "target_msd" item:
K <double>: example (K 0.1), specifies the spring stiffness.
D <double>: example (D 0.1), specifies the damping factor.
The type "obstacle_gaussian" implements an obstacle acting as a multivariate gaussian repulsive field within the d4c framework.
Options specific to the "obstacle_gaussian" item:
G <double>: example (G 0.1), specifies the gain of the gaussian field.
cut_tails <string>: example (cut_tails on), specifies whether to cut or not the tails of the gaussian field out of the space occupied by the obstacle.
- Returns
- true/false if successful/failed.
virtual bool iCub::d4c::D4C::open |
( |
const yarp::os::Property & |
options | ) |
|
|
pure virtual |
Configure the client or the server part of d4c framework.
- Parameters
-
options | contains the set of options in form of a Property object. |
Available options for the client are:
remote <string>: example (remote /d4c_server), specifies the server port stem-name to connect to.
local <string>: example (local /d4c_client), specifies the the client stem-name to be used for opening ports.
carrier <string>: example (carrier udp), specifies the protocol used to connect yarp streaming ports.
verbosity <int>: example (verbosity 3), specifies the verbosity level of print-outs messages.
Available options for the server are:
device <string>: example (device cartesiancontrollerclient), specifies the name of the device that implements the cartesian interface.
name <string>: example (name d4c_server), specifies the name of the server to be launched.
robot <string>: example (robot icub), specifies the name of the robot to connect to.
part <string>: example (part right_arm), specifies the robot part to be controlled.
period <int>: example (period 20), specifies the period given in [ms] to generate the d4c field.
offline: example (offline), lets the client/server start in offline mode.
verbosity <int>: example (verbosity 3), specifies the verbosity level of print-outs messages.
- Returns
- true/false if successful/failed.