kinematics-dynamics
|
The CartesianControlClient class implements ICartesianControl client side.
#include <CartesianControlClient.hpp>
Public Member Functions | |
bool | stat (std::vector< double > &x, int *state=nullptr, double *timestamp=nullptr) override |
Current state and position. More... | |
bool | inv (const std::vector< double > &xd, std::vector< double > &q) override |
Inverse kinematics. More... | |
bool | movj (const std::vector< double > &xd) override |
Move in joint space, absolute coordinates. More... | |
bool | relj (const std::vector< double > &xd) override |
Move in joint space, relative coordinates. More... | |
bool | movl (const std::vector< double > &xd) override |
Linear move to target position. More... | |
bool | movv (const std::vector< double > &xdotd) override |
Linear move with given velocity. More... | |
bool | gcmp () override |
Gravity compensation. More... | |
bool | forc (const std::vector< double > &fd) override |
Force control. More... | |
bool | stopControl () override |
Stop control. More... | |
bool | wait (double timeout) override |
Wait until completion. More... | |
bool | tool (const std::vector< double > &x) override |
Change tool. More... | |
bool | act (int command) override |
Actuate tool. More... | |
void | pose (const std::vector< double > &x) override |
Achieve pose. More... | |
void | twist (const std::vector< double > &xdot) override |
Instantaneous velocity steps. More... | |
void | wrench (const std::vector< double > &w) override |
Exert force. More... | |
bool | setParameter (int vocab, double value) override |
Set a configuration parameter. More... | |
bool | getParameter (int vocab, double *value) override |
Retrieve a configuration parameter. More... | |
bool | setParameters (const std::map< int, double > ¶ms) override |
Set multiple configuration parameters. More... | |
bool | getParameters (std::map< int, double > ¶ms) override |
Retrieve multiple configuration parameters. More... | |
bool | open (yarp::os::Searchable &config) override |
bool | close () override |
Public Member Functions inherited from roboticslab::ICartesianControl | |
virtual | ~ICartesianControl ()=default |
Destructor. | |
virtual void | movi (const std::vector< double > &x) |
Private Attributes | |
yarp::os::RpcClient | rpcClient |
yarp::os::BufferedPort< yarp::os::Bottle > | fkInPort |
yarp::os::BufferedPort< yarp::os::Bottle > | commandPort |
FkStreamResponder | fkStreamResponder |
double | fkStreamTimeoutSecs |
|
overridevirtual |
Send control command to actuate the robot's tool, if available.
command | One of available actuator vocabs. |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Apply desired forces in task space.
fd | 6-element vector describing desired force exerted by the TCP in cartesian space; first three elements denote linear force (Newton), last three denote torque (Newton*meters). |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Enable gravity compensation.
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Ask the controller to retrieve a parameter of 'double' type.
vocab | YARP-encoded vocab (parameter key). |
value | Parameter value encoded as a double. |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Ask the controller to retrieve all available parameters at once.
params | Dictionary of YARP-encoded vocabs as keys and their values. |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Perform inverse kinematics (using robot position as initial guess), but do not move.
xd | 6-element vector describing desired position in cartesian space; first three elements denote translation (meters), last three denote rotation in scaled axis-angle representation (radians). |
q | Vector describing current position in joint space (meters or degrees). |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Perform inverse kinematics and move to desired position in joint space using absolute coordinates.
xd | 6-element vector describing desired position in cartesian space; first three elements denote translation (meters), last three denote rotation in scaled axis-angle representation (radians). |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Move to end position along a line trajectory.
xd | 6-element vector describing desired position in cartesian space; first three elements denote translation (meters), last three denote rotation in scaled axis-angle representation (radians). |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Move along a line with constant velocity.
xdotd | 6-element vector describing desired velocity in cartesian space; first three elements denote translational velocity (meters/second), last three denote angular velocity (radians/second). |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Move to desired position instantaneously, no further intermediate calculations are expected other than computing the inverse kinematics.
x | 6-element vector describing desired instantaneous pose in cartesian space; first three elements denote translation (meters), last three denote rotation in scaled axis-angle representation (radians). |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Perform inverse kinematics and move to desired position in joint space using relative coordinates.
xd | 6-element vector describing desired offset in cartesian space; first three elements denote translation (meters), last three denote rotation in scaled axis-angle representation (radians). |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Ask the controller to store or update a parameter of 'double' type.
vocab | YARP-encoded vocab (parameter key). |
value | Parameter value encoded as a double. |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Ask the controller to store or update multiple parameters at once.
params | Dictionary of YARP-encoded vocabs as keys and their values. |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Inform on control state, get robot position and perform forward kinematics.
x | 6-element vector describing current position in cartesian space; first three elements denote translation (meters), last three denote rotation in scaled axis-angle representation (radians). |
state | Identifier for a cartesian control vocab. |
timestamp | Remote encoder acquisition time. |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Halt current control loop if any and cease movement.
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Unload current tool if any and append new tool frame to the kinematic chain.
x | 6-element vector describing new tool tip with regard to current end-effector frame in cartesian space; first three elements denote translation (meters), last three denote rotation in scaled axis-angle representation (radians). |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Move in instantaneous velocity increments.
xdot | 6-element vector describing velocity increments in cartesian space; first three elements denote translational velocity (meters/second), last three denote angular velocity (radians/second). |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Block execution until the movement is completed, errors occur or timeout is reached.
timeout | Timeout in seconds, '0.0' means no timeout. |
Implements roboticslab::ICartesianControl.
|
overridevirtual |
Make the TCP exert the desired force instantaneously.
w | 6-element vector describing desired force exerted by the TCP in cartesian space; first three elements denote linear force (Newton), last three denote torque (Newton*meters). |
Implements roboticslab::ICartesianControl.