YARP
Yet Another Robot Platform
ControlBoardWrapperTorqueControl Class Reference

#include <ControlBoardWrapper/ControlBoardWrapperTorqueControl.h>

+ Inheritance diagram for ControlBoardWrapperTorqueControl:

Public Member Functions

bool getAxes (int *ax) override
 Get the number of controlled axes. More...
 
bool getRefTorques (double *refs) override
 Get the reference value of the torque for all joints. More...
 
bool getRefTorque (int j, double *t) override
 Get the reference value of the torque for a given joint. More...
 
bool setRefTorques (const double *t) override
 Set the reference value of the torque for all joints. More...
 
bool setRefTorque (int j, double t) override
 Set the reference value of the torque for a given joint. More...
 
bool setRefTorques (const int n_joint, const int *joints, const double *t) override
 Set new torque reference for a subset of joints. More...
 
bool getMotorTorqueParams (int j, yarp::dev::MotorTorqueParameters *params) override
 Get a subset of motor parameters (bemf, ktau etc) useful for torque control. More...
 
bool setMotorTorqueParams (int j, const yarp::dev::MotorTorqueParameters params) override
 Set a subset of motor parameters (bemf, ktau etc) useful for torque control. More...
 
bool getTorque (int j, double *t) override
 Get the value of the torque on a given joint (this is the feedback if you have a torque sensor). More...
 
bool getTorques (double *t) override
 Get the value of the torque for all joints (this is the feedback if you have torque sensors). More...
 
bool getTorqueRange (int j, double *min, double *max) override
 Get the full scale of the torque sensor of a given joint. More...
 
bool getTorqueRanges (double *min, double *max) override
 Get the full scale of the torque sensors of all 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::ITorqueControl
virtual ~ITorqueControl ()
 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 16 of file ControlBoardWrapperTorqueControl.h.

Member Function Documentation

◆ getAxes()

bool ControlBoardWrapperTorqueControl::getAxes ( int *  ax)
inlineoverridevirtual

Get the number of controlled axes.

This command asks the number of controlled axes for the current physical interface.

Returns
the number of controlled axes.

Implements yarp::dev::ITorqueControl.

Definition at line 21 of file ControlBoardWrapperTorqueControl.h.

◆ getMotorTorqueParams()

bool ControlBoardWrapperTorqueControl::getMotorTorqueParams ( int  j,
yarp::dev::MotorTorqueParameters params 
)
overridevirtual

Get a subset of motor parameters (bemf, ktau etc) useful for torque control.

Parameters
jjoint number
paramsa struct containing the motor parameters to be retrieved
Returns
true/false on success/failure

Reimplemented from yarp::dev::ITorqueControl.

Definition at line 136 of file ControlBoardWrapperTorqueControl.cpp.

◆ getRefTorque()

bool ControlBoardWrapperTorqueControl::getRefTorque ( int  j,
double *  t 
)
overridevirtual

Get the reference value of the torque for a given joint.

This is NOT the feedback (see getTorque instead).

Parameters
jjoint number
tthe returned reference torque of joint j
Returns
true/false on success/failure

Implements yarp::dev::ITorqueControl.

Definition at line 40 of file ControlBoardWrapperTorqueControl.cpp.

◆ getRefTorques()

bool ControlBoardWrapperTorqueControl::getRefTorques ( double *  t)
overridevirtual

Get the reference value of the torque for all joints.

This is NOT the feedback (see getTorques instead).

Parameters
tpointer to the array of torque values
Returns
true/false on success/failure

Implements yarp::dev::ITorqueControl.

Definition at line 14 of file ControlBoardWrapperTorqueControl.cpp.

◆ getTorque()

bool ControlBoardWrapperTorqueControl::getTorque ( int  j,
double *  t 
)
overridevirtual

Get the value of the torque on a given joint (this is the feedback if you have a torque sensor).

Parameters
jjoint number
tpointer to the result value
Returns
true/false on success/failure

Implements yarp::dev::ITorqueControl.

Definition at line 180 of file ControlBoardWrapperTorqueControl.cpp.

◆ getTorqueRange()

bool ControlBoardWrapperTorqueControl::getTorqueRange ( int  j,
double *  min,
double *  max 
)
overridevirtual

Get the full scale of the torque sensor of a given joint.

Parameters
jjoint number
minminimum torque of the joint j
maxmaximum torque of the joint j
Returns
true/false on success/failure

Implements yarp::dev::ITorqueControl.

Definition at line 229 of file ControlBoardWrapperTorqueControl.cpp.

◆ getTorqueRanges()

bool ControlBoardWrapperTorqueControl::getTorqueRanges ( double *  min,
double *  max 
)
overridevirtual

Get the full scale of the torque sensors of all joints.

Parameters
minpointer to the array that will store minimum torques of the joints
maxpointer to the array that will store maximum torques of the joints
Returns
true/false on success/failure

Implements yarp::dev::ITorqueControl.

Definition at line 252 of file ControlBoardWrapperTorqueControl.cpp.

◆ getTorques()

bool ControlBoardWrapperTorqueControl::getTorques ( double *  t)
overridevirtual

Get the value of the torque for all joints (this is the feedback if you have torque sensors).

Parameters
tpointer to the array that will store the output
Returns
true/false on success/failure

Implements yarp::dev::ITorqueControl.

Definition at line 203 of file ControlBoardWrapperTorqueControl.cpp.

◆ setMotorTorqueParams()

bool ControlBoardWrapperTorqueControl::setMotorTorqueParams ( int  j,
const yarp::dev::MotorTorqueParameters  params 
)
overridevirtual

Set a subset of motor parameters (bemf, ktau etc) useful for torque control.

Parameters
jjoint number
paramsa struct containing the motor parameters to be set
Returns
true/false on success/failure

Reimplemented from yarp::dev::ITorqueControl.

Definition at line 158 of file ControlBoardWrapperTorqueControl.cpp.

◆ setRefTorque()

bool ControlBoardWrapperTorqueControl::setRefTorque ( int  j,
double  t 
)
overridevirtual

Set the reference value of the torque for a given joint.

Parameters
jjoint number
tnew value
Returns
true/false on success/failure

Implements yarp::dev::ITorqueControl.

Definition at line 85 of file ControlBoardWrapperTorqueControl.cpp.

◆ setRefTorques() [1/2]

bool ControlBoardWrapperTorqueControl::setRefTorques ( const double *  t)
overridevirtual

Set the reference value of the torque for all joints.

Parameters
tpointer to the array of torque values
Returns
true/false on success/failure

Implements yarp::dev::ITorqueControl.

Definition at line 63 of file ControlBoardWrapperTorqueControl.cpp.

◆ setRefTorques() [2/2]

bool ControlBoardWrapperTorqueControl::setRefTorques ( const int  n_joint,
const int *  joints,
const double *  t 
)
overridevirtual

Set new torque reference for a subset of joints.

Parameters
jointspointer to the array of joint numbers
refspointer to the array specifying the new torque reference
Returns
true/false on success/failure

Reimplemented from yarp::dev::ITorqueControl.

Definition at line 107 of file ControlBoardWrapperTorqueControl.cpp.


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