YARP
Yet Another Robot Platform
ControlBoardWrapperVelocityControl Class Reference

#include <ControlBoardWrapper/ControlBoardWrapperVelocityControl.h>

+ Inheritance diagram for ControlBoardWrapperVelocityControl:

Public Member Functions

bool getAxes (int *ax) override
 Get the number of controlled axes. More...
 
bool velocityMove (int j, double v) override
 Start motion at a given speed, single joint. More...
 
bool velocityMove (const double *v) override
 Start motion at a given speed, multiple joints. More...
 
bool velocityMove (const int n_joints, const int *joints, const double *spds) override
 Start motion at a given speed for a subset of joints. More...
 
bool getRefVelocity (const int joint, double *vel) override
 Get the last reference speed set by velocityMove for single joint. More...
 
bool getRefVelocities (double *vels) override
 Get the last reference speed set by velocityMove for all joints. More...
 
bool getRefVelocities (const int n_joint, const int *joints, double *vels) override
 Get the last reference speed set by velocityMove for a group of joints. More...
 
bool setRefAcceleration (int j, double acc) override
 Set reference acceleration for a joint. More...
 
bool setRefAccelerations (const double *accs) override
 Set reference acceleration on all joints. More...
 
bool setRefAccelerations (const int n_joints, const int *joints, const double *accs) override
 Set reference acceleration for a subset of joints. More...
 
bool getRefAcceleration (int j, double *acc) override
 Get reference acceleration for a joint. More...
 
bool getRefAccelerations (double *accs) override
 Get reference acceleration of all joints. More...
 
bool getRefAccelerations (const int n_joints, const int *joints, double *accs) override
 Get reference acceleration for a subset of joints. More...
 
bool stop (int j) override
 Stop motion, single joint. More...
 
bool stop () override
 Stop motion, multiple joints. More...
 
bool stop (const int n_joint, const int *joints) override
 Stop motion for a subset of joints. More...
 
- Public Member Functions inherited from ControlBoardWrapperCommon
bool getAxes (int *ax)
 
bool setRefAcceleration (int j, double acc)
 
bool setRefAccelerations (const double *accs)
 
bool setRefAccelerations (const int n_joints, const int *joints, const double *accs)
 
bool getRefAcceleration (int j, double *acc)
 
bool getRefAccelerations (double *accs)
 
bool getRefAccelerations (const int n_joints, const int *joints, double *accs)
 
bool stop (int j)
 
bool stop ()
 
bool stop (const int n_joint, const int *joints)
 
bool getNumberOfMotors (int *num)
 
bool getCurrent (int m, double *curr)
 
bool getCurrents (double *currs)
 
void printError (const std::string &func_name, const std::string &info, bool result)
 
- Public Member Functions inherited from yarp::dev::IVelocityControl
virtual ~IVelocityControl ()
 Destructor. More...
 

Additional Inherited Members

- Public Attributes inherited from ControlBoardWrapperCommon
WrappedDevice device
 
size_t controlledJoints {0}
 
std::string partName
 
std::mutex rpcDataMutex
 
MultiJointData rpcData
 
std::mutex timeMutex
 
yarp::os::Stamp time
 

Detailed Description

Definition at line 17 of file ControlBoardWrapperVelocityControl.h.

Member Function Documentation

◆ getAxes()

bool ControlBoardWrapperVelocityControl::getAxes ( int *  axes)
inlineoverridevirtual

Get the number of controlled axes.

This command asks the number of controlled axes for the current physical interface. parame axes pointer to storage

Returns
true/false.

Implements yarp::dev::IVelocityControl.

Definition at line 22 of file ControlBoardWrapperVelocityControl.h.

◆ getRefAcceleration()

bool ControlBoardWrapperVelocityControl::getRefAcceleration ( int  j,
double *  acc 
)
inlineoverridevirtual

Get reference acceleration for a joint.

Returns the acceleration used to generate the trajectory profile.

Parameters
jjoint number
accpointer to storage for the return value
Returns
true/false on success/failure

Implements yarp::dev::IVelocityControl.

Definition at line 32 of file ControlBoardWrapperVelocityControl.h.

◆ getRefAccelerations() [1/2]

bool ControlBoardWrapperVelocityControl::getRefAccelerations ( const int  n_joint,
const int *  joints,
double *  accs 
)
inlineoverridevirtual

Get reference acceleration for a subset of joints.

These are the values used during the interpolation of the trajectory.

Parameters
n_jointhow many joints this command is referring to
jointslist of joints controlled. The size of this array is n_joints
accspointer to the array containing acceleration values, one value for each joint, the size of the array is n_joints. The first value will be the new reference for the joint joints[0]. for example: n_joint 3 joints 0 2 4 accs 10 30 40
Returns
true/false on success/failure

Implements yarp::dev::IVelocityControl.

Definition at line 34 of file ControlBoardWrapperVelocityControl.h.

◆ getRefAccelerations() [2/2]

bool ControlBoardWrapperVelocityControl::getRefAccelerations ( double *  accs)
inlineoverridevirtual

Get reference acceleration of all joints.

These are the values used during the interpolation of the trajectory.

Parameters
accspointer to the array that will store the acceleration values.
Returns
true/false on success or failure

Implements yarp::dev::IVelocityControl.

Definition at line 33 of file ControlBoardWrapperVelocityControl.h.

◆ getRefVelocities() [1/2]

bool ControlBoardWrapperVelocityControl::getRefVelocities ( const int  n_joint,
const int *  joints,
double *  vels 
)
overridevirtual

Get the last reference speed set by velocityMove for a group of joints.

Parameters
n_jointhow many joints this command is referring to
jointsof joints controlled. The size of this array is n_joints
velspointer to the array containing the requested values, one value for each joint. The size of the array is n_joints.
Returns
true/false on success/failure

Reimplemented from yarp::dev::IVelocityControl.

Definition at line 157 of file ControlBoardWrapperVelocityControl.cpp.

◆ getRefVelocities() [2/2]

bool ControlBoardWrapperVelocityControl::getRefVelocities ( double *  vels)
overridevirtual

Get the last reference speed set by velocityMove for all joints.

Parameters
velspointer to the array containing the new speed values, one value for each joint
Returns
true/false on success/failure

Reimplemented from yarp::dev::IVelocityControl.

Definition at line 131 of file ControlBoardWrapperVelocityControl.cpp.

◆ getRefVelocity()

bool ControlBoardWrapperVelocityControl::getRefVelocity ( const int  joint,
double *  vel 
)
overridevirtual

Get the last reference speed set by velocityMove for single joint.

Parameters
jjoint number
velreturns the requested reference.
Returns
true/false on success/failure

Reimplemented from yarp::dev::IVelocityControl.

Definition at line 103 of file ControlBoardWrapperVelocityControl.cpp.

◆ setRefAcceleration()

bool ControlBoardWrapperVelocityControl::setRefAcceleration ( int  j,
double  acc 
)
inlineoverridevirtual

Set reference acceleration for a joint.

This value is used during the trajectory generation.

Parameters
jjoint number
accacceleration value
Returns
true/false upon success/failure

Implements yarp::dev::IVelocityControl.

Definition at line 29 of file ControlBoardWrapperVelocityControl.h.

◆ setRefAccelerations() [1/2]

bool ControlBoardWrapperVelocityControl::setRefAccelerations ( const double *  accs)
inlineoverridevirtual

Set reference acceleration on all joints.

This is the valure that is used during the generation of the trajectory.

Parameters
accspointer to the array of acceleration values
Returns
true/false upon success/failure

Implements yarp::dev::IVelocityControl.

Definition at line 30 of file ControlBoardWrapperVelocityControl.h.

◆ setRefAccelerations() [2/2]

bool ControlBoardWrapperVelocityControl::setRefAccelerations ( const int  n_joint,
const int *  joints,
const double *  accs 
)
inlineoverridevirtual

Set reference acceleration for a subset of joints.

This is the valure that is used during the generation of the trajectory.

Parameters
n_jointhow many joints this command is referring to
jointslist of joints controlled. The size of this array is n_joints
accspointer to the array containing acceleration values, one value for each joint, the size of the array is n_joints. The first value will be the new reference for the joint joints[0]. for example: n_joint 3 joints 0 2 4 accs 10 30 40
Returns
true/false on success/failure

Implements yarp::dev::IVelocityControl.

Definition at line 31 of file ControlBoardWrapperVelocityControl.h.

◆ stop() [1/3]

bool ControlBoardWrapperVelocityControl::stop ( )
inlineoverridevirtual

Stop motion, multiple joints.

Returns
true/false on success or failure

Implements yarp::dev::IVelocityControl.

Definition at line 36 of file ControlBoardWrapperVelocityControl.h.

◆ stop() [2/3]

bool ControlBoardWrapperVelocityControl::stop ( const int  n_joint,
const int *  joints 
)
inlineoverridevirtual

Stop motion for a subset of joints.

Parameters
n_jointhow many joints this command is referring to
jointsjoints pointer to the array of joint numbers
Returns
true/false on success or failure

Implements yarp::dev::IVelocityControl.

Definition at line 37 of file ControlBoardWrapperVelocityControl.h.

◆ stop() [3/3]

bool ControlBoardWrapperVelocityControl::stop ( int  j)
inlineoverridevirtual

Stop motion, single joint.

Parameters
jjoint number
Returns
true/false on success or failure

Implements yarp::dev::IVelocityControl.

Definition at line 35 of file ControlBoardWrapperVelocityControl.h.

◆ velocityMove() [1/3]

bool ControlBoardWrapperVelocityControl::velocityMove ( const double *  sp)
overridevirtual

Start motion at a given speed, multiple joints.

Parameters
sppointer to the array containing the new speed values
Returns
true/false upon success/failure

Implements yarp::dev::IVelocityControl.

Definition at line 38 of file ControlBoardWrapperVelocityControl.cpp.

◆ velocityMove() [2/3]

bool ControlBoardWrapperVelocityControl::velocityMove ( const int  n_joint,
const int *  joints,
const double *  spds 
)
overridevirtual

Start motion at a given speed for a subset of joints.

Parameters
n_jointhow many joints this command is referring to
jointsof joints controlled. The size of this array is n_joints
spdspointer to the array containing the new speed values, one value for each joint, the size of the array is n_joints. The first value will be the new reference for the joint joints[0]. for example: n_joint 3 joints 0 2 4 spds 10 30 40
Returns
true/false on success/failure

Implements yarp::dev::IVelocityControl.

Definition at line 74 of file ControlBoardWrapperVelocityControl.cpp.

◆ velocityMove() [3/3]

bool ControlBoardWrapperVelocityControl::velocityMove ( int  j,
double  sp 
)
overridevirtual

Start motion at a given speed, single joint.

Parameters
jjoint number
spspeed value
Returns
bool/false upone success/failure

Implements yarp::dev::IVelocityControl.

Definition at line 15 of file ControlBoardWrapperVelocityControl.cpp.


The documentation for this class was generated from the following files: