![]() |
Visual Servoing Platform version 3.7.0
|
#include <vpRobot.h>
Public Types | |
| enum | vpRobotStateType { STATE_STOP , STATE_VELOCITY_CONTROL , STATE_POSITION_CONTROL , STATE_ACCELERATION_CONTROL , STATE_FORCE_TORQUE_CONTROL } |
| enum | vpControlFrameType { REFERENCE_FRAME , ARTICULAR_FRAME , JOINT_STATE = ARTICULAR_FRAME , END_EFFECTOR_FRAME , CAMERA_FRAME , TOOL_FRAME = CAMERA_FRAME , MIXT_FRAME } |
Public Member Functions | |
| vpRobot (void) | |
| vpRobot (const vpRobot &robot) | |
| virtual | ~vpRobot () |
Inherited functionalities from vpRobot | |
| virtual void | get_eJe (vpMatrix &_eJe)=0 |
| virtual void | get_fJe (vpMatrix &_fJe)=0 |
| virtual void | getDisplacement (const vpRobot::vpControlFrameType frame, vpColVector &q)=0 |
| double | getMaxTranslationVelocity (void) const |
| double | getMaxRotationVelocity (void) const |
| int | getNDof () const |
| virtual void | getPosition (const vpRobot::vpControlFrameType frame, vpColVector &position)=0 |
| vpColVector | getPosition (const vpRobot::vpControlFrameType frame) |
| virtual vpRobotStateType | getRobotState (void) const |
| virtual void | init ()=0 |
| vpRobot & | operator= (const vpRobot &robot) |
| void | setMaxRotationVelocity (double maxVr) |
| void | setMaxTranslationVelocity (double maxVt) |
| virtual void | setPosition (const vpRobot::vpControlFrameType frame, const vpColVector &q)=0 |
| virtual vpRobotStateType | setRobotState (const vpRobot::vpRobotStateType newState) |
| virtual void | setVelocity (const vpRobot::vpControlFrameType frame, const vpColVector &vel)=0 |
| void | setVerbose (bool verbose) |
Static Public Member Functions | |
Static Public Member Functions inherited from vpRobot | |
| static vpColVector | saturateVelocities (const vpColVector &v_in, const vpColVector &v_max, bool verbose=false) |
Protected Member Functions | |
Protected Member Functions Inherited from vpRobot | |
| vpControlFrameType | setRobotFrame (vpRobot::vpControlFrameType newFrame) |
| vpControlFrameType | getRobotFrame (void) const |
Protected Attributes | |
| double | maxTranslationVelocity |
| double | maxRotationVelocity |
| int | nDof |
| vpMatrix | eJe |
| int | eJeAvailable |
| vpMatrix | fJe |
| int | fJeAvailable |
| int | areJointLimitsAvailable |
| double * | qmin |
| double * | qmax |
| bool | verbose_ |
Static Protected Attributes | |
| static const double | maxTranslationVelocityDefault = 0.2 |
| static const double | maxRotationVelocityDefault = 0.7 |
Class that defines a generic virtual robot.
group_robot_real_template
Robot control frames.
| Enumerator | |
|---|---|
| REFERENCE_FRAME | Corresponds to a fixed reference frame attached to the robot structure. |
| ARTICULAR_FRAME | Corresponds to the joint state. This value is deprecated. You should rather use vpRobot::JOINT_STATE. |
| JOINT_STATE | Corresponds to the joint state. |
| END_EFFECTOR_FRAME | Corresponds to robot end-effector frame. |
| CAMERA_FRAME | Corresponds to a frame attached to the camera mounted on the robot end-effector. |
| TOOL_FRAME | Corresponds to a frame attached to the tool (camera, gripper...) mounted on the robot end-effector. This value is equal to vpRobot::CAMERA_FRAME. |
| MIXT_FRAME | Corresponds to a "virtual" frame where translations are expressed in the reference frame, and rotations in the camera frame. |
Robot control states.
| vpRobot::vpRobot | ( | void | ) |
Definition at line 49 of file vpRobot.cpp.
References areJointLimitsAvailable, CAMERA_FRAME, eJe, eJeAvailable, fJe, fJeAvailable, maxRotationVelocity, maxRotationVelocityDefault, maxTranslationVelocity, maxTranslationVelocityDefault, nDof, qmax, qmin, STATE_STOP, verbose_, and vpRobot().
Referenced by init(), operator=(), vpRobot(), vpRobot(), vpRobotAfma6::vpRobotAfma6(), vpRobotBiclops::vpRobotBiclops(), vpRobotBiclops::vpRobotBiclops(), vpRobotFranka::vpRobotFranka(), vpRobotFranka::vpRobotFranka(), vpRobotFranka::vpRobotFranka(), vpRobotPtu46::vpRobotPtu46(), vpRobotSimulator::vpRobotSimulator(), vpRobotViper650::vpRobotViper650(), and vpRobotViper850::vpRobotViper850().
| vpRobot::vpRobot | ( | const vpRobot & | robot | ) |
Definition at line 56 of file vpRobot.cpp.
References areJointLimitsAvailable, CAMERA_FRAME, eJe, eJeAvailable, fJe, fJeAvailable, maxRotationVelocity, maxRotationVelocityDefault, maxTranslationVelocity, maxTranslationVelocityDefault, nDof, qmax, qmin, STATE_STOP, verbose_, and vpRobot().
|
virtual |
Destructor that free allocated memory.
Definition at line 68 of file vpRobot.cpp.
|
pure virtual |
Get the robot Jacobian expressed in the end-effector frame.
Implemented in vpRobotAfma6, vpRobotBiclops, vpRobotCamera, vpRobotFlirPtu, vpRobotFranka, vpRobotKinova, vpRobotPioneer, vpRobotPololuPtu, vpRobotPtu46, vpRobotTemplate, vpRobotViper650, vpRobotViper850, vpSimulatorAfma6, vpSimulatorCamera, vpSimulatorPioneer, vpSimulatorPioneerPan, and vpSimulatorViper850.
|
pure virtual |
Get the robot Jacobian expressed in the robot reference (or world) frame.
Implemented in vpRobotAfma6, vpRobotBiclops, vpRobotFlirPtu, vpRobotFranka, vpRobotKinova, vpRobotPololuPtu, vpRobotPtu46, vpRobotTemplate, vpRobotViper650, vpRobotViper850, vpSimulatorAfma6, and vpSimulatorViper850.
|
pure virtual |
Get a displacement (frame as to ve specified) between two successive position control.
Implemented in vpRobotAfma6, vpRobotBiclops, vpRobotFlirPtu, vpRobotKinova, vpRobotPtu46, vpRobotTemplate, vpRobotViper650, vpRobotViper850, vpSimulatorAfma6, and vpSimulatorViper850.
References getMaxRotationVelocity(), and getMaxTranslationVelocity().
| double vpRobot::getMaxRotationVelocity | ( | void | ) | const |
Get the maximal rotation velocity that can be sent to the robot during a velocity control.
Definition at line 272 of file vpRobot.cpp.
References maxRotationVelocity.
Referenced by vpSimulatorAfma6::computeArticularVelocity(), vpSimulatorViper850::computeArticularVelocity(), vpSimulatorAfma6::findHighestPositioningSpeed(), vpSimulatorViper850::findHighestPositioningSpeed(), getDisplacement(), vpRobotPololuPtu::setPosition(), vpSimulatorAfma6::setPosition(), vpRobotAfma6::setVelocity(), vpRobotCamera::setVelocity(), vpRobotFlirPtu::setVelocity(), vpRobotFranka::setVelocity(), vpRobotKinova::setVelocity(), vpRobotPioneer::setVelocity(), vpRobotPololuPtu::setVelocity(), vpRobotTemplate::setVelocity(), vpRobotUniversalRobots::setVelocity(), vpRobotViper650::setVelocity(), vpRobotViper850::setVelocity(), vpSimulatorAfma6::setVelocity(), vpSimulatorCamera::setVelocity(), vpSimulatorPioneer::setVelocity(), vpSimulatorPioneerPan::setVelocity(), and vpSimulatorViper850::setVelocity().
| double vpRobot::getMaxTranslationVelocity | ( | void | ) | const |
Get the maximal translation velocity that can be sent to the robot during a velocity control.
Definition at line 250 of file vpRobot.cpp.
References maxTranslationVelocity.
Referenced by getDisplacement(), vpSimulatorAfma6::setPosition(), vpRobotAfma6::setVelocity(), vpRobotCamera::setVelocity(), vpRobotFlirPtu::setVelocity(), vpRobotFranka::setVelocity(), vpRobotKinova::setVelocity(), vpRobotPioneer::setVelocity(), vpRobotTemplate::setVelocity(), vpRobotUniversalRobots::setVelocity(), vpRobotViper650::setVelocity(), vpRobotViper850::setVelocity(), vpSimulatorAfma6::setVelocity(), vpSimulatorCamera::setVelocity(), vpSimulatorPioneer::setVelocity(), vpSimulatorPioneerPan::setVelocity(), and vpSimulatorViper850::setVelocity().
|
inline |
| vpColVector vpRobot::getPosition | ( | const vpRobot::vpControlFrameType | frame | ) |
Return the current robot position in the specified frame.
Definition at line 215 of file vpRobot.cpp.
References getPosition().
|
pure virtual |
Get the robot position (frame has to be specified).
Implemented in vpRobotAfma6, vpRobotBiclops, vpRobotCamera, vpRobotFlirPtu, vpRobotFranka, vpRobotKinova, vpRobotPololuPtu, vpRobotPtu46, vpRobotTemplate, vpRobotUniversalRobots, vpRobotViper650, vpRobotViper850, vpSimulatorAfma6, vpSimulatorCamera, vpSimulatorPioneer, vpSimulatorPioneerPan, and vpSimulatorViper850.
References getPosition().
Referenced by getPosition(), and getPosition().
|
inlineprotected |
Definition at line 180 of file vpRobot.h.
Referenced by vpSimulatorAfma6::computeArticularVelocity(), and vpSimulatorViper850::computeArticularVelocity().
|
inlinevirtual |
Definition at line 152 of file vpRobot.h.
Referenced by vpRobotBiclops::getPosition(), vpRobotBiclops::getVelocity(), vpRobotAfma6::setPosition(), vpRobotBiclops::setPosition(), vpRobotCamera::setPosition(), vpRobotFranka::setPosition(), vpRobotPololuPtu::setPosition(), vpRobotPtu46::setPosition(), vpRobotUniversalRobots::setPosition(), vpRobotViper650::setPosition(), vpRobotViper850::setPosition(), vpSimulatorAfma6::setPosition(), vpSimulatorCamera::setPosition(), vpSimulatorViper850::setPosition(), vpRobotAfma6::setRobotState(), vpRobotBiclops::setRobotState(), vpRobotFlirPtu::setRobotState(), vpRobotFranka::setRobotState(), vpRobotPololuPtu::setRobotState(), vpRobotPtu46::setRobotState(), vpRobotUniversalRobots::setRobotState(), vpRobotViper650::setRobotState(), vpRobotViper850::setRobotState(), vpSimulatorAfma6::setRobotState(), vpSimulatorViper850::setRobotState(), vpRobotAfma6::setVelocity(), vpRobotBiclops::setVelocity(), vpRobotCamera::setVelocity(), vpRobotFlirPtu::setVelocity(), vpRobotFranka::setVelocity(), vpRobotKinova::setVelocity(), vpRobotPololuPtu::setVelocity(), vpRobotPtu46::setVelocity(), vpRobotTemplate::setVelocity(), vpRobotUniversalRobots::setVelocity(), vpRobotViper650::setVelocity(), vpRobotViper850::setVelocity(), vpSimulatorAfma6::setVelocity(), vpSimulatorCamera::setVelocity(), vpSimulatorPioneer::setVelocity(), vpSimulatorPioneerPan::setVelocity(), vpSimulatorViper850::setVelocity(), vpRobotFlirPtu::stopMotion(), vpRobotFranka::stopMotion(), vpRobotViper650::stopMotion(), vpRobotViper850::stopMotion(), vpSimulatorAfma6::stopMotion(), and vpSimulatorViper850::stopMotion().
|
pure virtual |
Implemented in vpRobotAfma6, vpRobotBiclops, vpRobotFlirPtu, vpRobotKinova, vpRobotPioneer, vpRobotPtu46, vpRobotTemplate, vpRobotUniversalRobots, vpRobotViper650, vpRobotViper850, vpSimulatorAfma6, and vpSimulatorViper850.
References operator=(), setMaxRotationVelocity(), setMaxTranslationVelocity(), and vpRobot().
Referenced by vpRobotFranka::connect(), vpRobotCamera::vpRobotCamera(), vpRobotFranka::vpRobotFranka(), vpRobotFranka::vpRobotFranka(), vpRobotFranka::vpRobotFranka(), vpSimulatorCamera::vpSimulatorCamera(), vpSimulatorPioneer::vpSimulatorPioneer(), and vpSimulatorPioneerPan::vpSimulatorPioneerPan().
Copy operator.
Definition at line 81 of file vpRobot.cpp.
References areJointLimitsAvailable, eJe, eJeAvailable, fJe, fJeAvailable, maxRotationVelocity, maxTranslationVelocity, nDof, qmax, qmin, verbose_, and vpRobot().
Referenced by init().
|
static |
Saturate velocities.
| v_in | : Vector of input velocities to saturate. Translation velocities should be expressed in m/s while rotation velocities in rad/s. |
| v_max | : Vector of maximal allowed velocities. Maximal translation velocities should be expressed in m/s while maximal rotation velocities in rad/s. |
| verbose | : Print a message indicating which axis causes the saturation. |
| vpRobotException::dimensionError | : If the input vectors have different dimensions. |
The code below shows how to use this static method in order to saturate a velocity skew vector.
Definition at line 162 of file vpRobot.cpp.
References vpException::dimensionError, and vpArray2D< Type >::size().
Referenced by vpRobotAfma6::setVelocity(), vpRobotCamera::setVelocity(), vpRobotFlirPtu::setVelocity(), vpRobotFranka::setVelocity(), vpRobotKinova::setVelocity(), vpRobotPioneer::setVelocity(), vpRobotTemplate::setVelocity(), vpRobotUniversalRobots::setVelocity(), vpRobotViper650::setVelocity(), vpRobotViper850::setVelocity(), vpSimulatorCamera::setVelocity(), vpSimulatorPioneer::setVelocity(), and vpSimulatorPioneerPan::setVelocity().
| void vpRobot::setMaxRotationVelocity | ( | double | w_max | ) |
Set the maximal rotation velocity that can be sent to the robot during a velocity control.
| w_max | : Maximum rotational velocity expressed in rad/s. |
Definition at line 259 of file vpRobot.cpp.
References maxRotationVelocity.
Referenced by init(), vpRobotViper650::setMaxRotationVelocity(), vpRobotViper850::setMaxRotationVelocity(), and vpSimulatorAfma6::setPosition().
| void vpRobot::setMaxTranslationVelocity | ( | double | v_max | ) |
Set the maximal translation velocity that can be sent to the robot during a velocity control.
| v_max | : Maximum translation velocity expressed in m/s. |
Definition at line 238 of file vpRobot.cpp.
References maxTranslationVelocity.
Referenced by init(), and vpSimulatorAfma6::setPosition().
|
pure virtual |
Set a displacement (frame has to be specified) in position control.
Implemented in vpRobotAfma6, vpRobotBiclops, vpRobotFlirPtu, vpRobotFranka, vpRobotKinova, vpRobotPololuPtu, vpRobotPtu46, vpRobotTemplate, vpRobotUniversalRobots, vpRobotViper650, vpRobotViper850, vpSimulatorAfma6, and vpSimulatorViper850.
References setRobotState().
|
protected |
Definition at line 206 of file vpRobot.cpp.
Referenced by vpSimulatorAfma6::init(), vpSimulatorViper850::init(), vpSimulatorAfma6::setVelocity(), vpSimulatorCamera::setVelocity(), vpSimulatorPioneer::setVelocity(), vpSimulatorPioneerPan::setVelocity(), and vpSimulatorViper850::setVelocity().
|
virtual |
Reimplemented in vpRobotAfma6, vpRobotBiclops, vpRobotFlirPtu, vpRobotFranka, vpRobotPololuPtu, vpRobotPtu46, vpRobotUniversalRobots, vpRobotViper650, vpRobotViper850, vpSimulatorAfma6, and vpSimulatorViper850.
Definition at line 200 of file vpRobot.cpp.
Referenced by setPosition(), vpRobotCamera::setPosition(), vpSimulatorCamera::setPosition(), vpRobotAfma6::setRobotState(), vpRobotBiclops::setRobotState(), vpRobotFlirPtu::setRobotState(), vpRobotFranka::setRobotState(), vpRobotPololuPtu::setRobotState(), vpRobotPtu46::setRobotState(), vpRobotUniversalRobots::setRobotState(), vpRobotViper650::setRobotState(), vpRobotViper850::setRobotState(), vpSimulatorAfma6::setRobotState(), vpSimulatorViper850::setRobotState(), vpRobotCamera::setVelocity(), vpSimulatorCamera::setVelocity(), vpSimulatorPioneer::setVelocity(), vpSimulatorPioneerPan::setVelocity(), vpSimulatorAfma6::stopMotion(), and vpSimulatorViper850::stopMotion().
|
pure virtual |
Set the velocity (frame has to be specified) that will be applied to the velocity controller.
Implemented in vpRobotAfma6, vpRobotBiclops, vpRobotCamera, vpRobotFlirPtu, vpRobotFranka, vpRobotKinova, vpRobotPioneer, vpRobotPololuPtu, vpRobotPtu46, vpRobotTemplate, vpRobotUniversalRobots, vpRobotViper650, vpRobotViper850, vpSimulatorAfma6, vpSimulatorCamera, vpSimulatorPioneer, vpSimulatorPioneerPan, and vpSimulatorViper850.
|
inline |
Definition at line 167 of file vpRobot.h.
References verbose_.
Referenced by vpRobotAfma6::vpRobotAfma6(), vpRobotViper650::vpRobotViper650(), and vpRobotViper850::vpRobotViper850().
|
protected |
Definition at line 111 of file vpRobot.h.
Referenced by operator=(), vpRobot(), and vpRobot().
|
protected |
robot Jacobian expressed in the end-effector frame
Definition at line 103 of file vpRobot.h.
Referenced by vpRobotAfma6::get_eJe(), vpRobotBiclops::get_eJe(), vpRobotCamera::get_eJe(), vpRobotFlirPtu::get_eJe(), vpRobotFlirPtu::get_eJe(), vpRobotKinova::get_eJe(), vpRobotPioneer::get_eJe(), vpRobotPololuPtu::get_eJe(), vpRobotPololuPtu::get_eJe(), vpRobotPtu46::get_eJe(), vpRobotViper650::get_eJe(), vpRobotViper850::get_eJe(), vpSimulatorCamera::get_eJe(), operator=(), vpRobot(), and vpRobot().
|
protected |
is the robot Jacobian expressed in the end-effector frame available
Definition at line 105 of file vpRobot.h.
Referenced by operator=(), vpRobot(), and vpRobot().
|
protected |
robot Jacobian expressed in the robot reference frame available
Definition at line 107 of file vpRobot.h.
Referenced by vpRobotAfma6::get_fJe(), vpRobotBiclops::get_fJe(), vpRobotFlirPtu::get_fJe(), vpRobotFlirPtu::get_fJe(), vpRobotKinova::get_fJe(), vpRobotPololuPtu::get_fJe(), vpRobotPololuPtu::get_fJe(), vpRobotPtu46::get_fJe(), vpRobotViper650::get_fJe(), vpRobotViper850::get_fJe(), operator=(), vpRobot(), and vpRobot().
|
protected |
is the robot Jacobian expressed in the robot reference frame available
Definition at line 109 of file vpRobot.h.
Referenced by operator=(), vpRobot(), and vpRobot().
|
protected |
Definition at line 97 of file vpRobot.h.
Referenced by getMaxRotationVelocity(), vpRobotFlirPtu::init(), vpRobotKinova::init(), vpRobotTemplate::init(), operator=(), setMaxRotationVelocity(), vpRobotPtu46::setVelocity(), vpRobot(), vpRobot(), vpRobotViper650::vpRobotViper650(), and vpRobotViper850::vpRobotViper850().
|
staticprotected |
Definition at line 98 of file vpRobot.h.
Referenced by vpRobotFlirPtu::init(), vpRobotKinova::init(), vpRobotTemplate::init(), vpRobot(), and vpRobot().
|
protected |
Definition at line 95 of file vpRobot.h.
Referenced by getMaxTranslationVelocity(), vpRobotFlirPtu::init(), vpRobotKinova::init(), vpRobotTemplate::init(), operator=(), setMaxTranslationVelocity(), vpRobot(), and vpRobot().
|
staticprotected |
Definition at line 96 of file vpRobot.h.
Referenced by vpRobotFlirPtu::init(), vpRobotKinova::init(), vpRobotTemplate::init(), vpRobot(), and vpRobot().
|
protected |
number of degrees of freedom
Definition at line 101 of file vpRobot.h.
Referenced by vpRobotPololuPtu::get_eJe(), vpRobotPololuPtu::get_eJe(), vpRobotPololuPtu::get_fJe(), vpRobotPololuPtu::get_fJe(), vpRobotKinova::getJointPosition(), getNDof(), vpRobotPololuPtu::getPosition(), vpRobotFlirPtu::init(), vpRobotKinova::init(), vpRobotTemplate::init(), vpRobotUniversalRobots::init(), operator=(), vpRobotUniversalRobots::readPosFile(), vpRobotKinova::setDoF(), vpRobotKinova::setJointVelocity(), vpRobotKinova::setPosition(), vpRobotPololuPtu::setPosition(), vpRobotFlirPtu::setVelocity(), vpRobotKinova::setVelocity(), vpRobotPololuPtu::setVelocity(), vpRobotTemplate::setVelocity(), vpRobot(), vpRobot(), and vpRobotPololuPtu::vpRobotPololuPtu().
|
protected |
Definition at line 113 of file vpRobot.h.
Referenced by operator=(), vpRobot(), vpRobot(), and ~vpRobot().
|
protected |
Definition at line 112 of file vpRobot.h.
Referenced by operator=(), vpRobot(), vpRobot(), and ~vpRobot().
|
protected |
Definition at line 115 of file vpRobot.h.
Referenced by vpRobotAfma6::init(), vpRobotViper650::init(), vpRobotViper850::init(), vpSimulatorAfma6::initialiseCameraRelativeToObject(), vpSimulatorViper850::initialiseCameraRelativeToObject(), operator=(), vpSimulatorAfma6::setPosition(), vpSimulatorViper850::setPosition(), setVerbose(), vpRobotWireFrameSimulator::setVerbose(), vpSimulatorAfma6::updateArticularPosition(), vpSimulatorViper850::updateArticularPosition(), vpRobot(), vpRobot(), vpRobotAfma6::vpRobotAfma6(), vpRobotViper650::vpRobotViper650(), and vpRobotViper850::vpRobotViper850().