YARP  2.3.70.1
Yet Another Robot Platform
yarp::dev::ControlBoardWrapper Class Reference

#include <ControlBoardWrapper/ControlBoardWrapper.h>

+ Inheritance diagram for yarp::dev::ControlBoardWrapper:

Public Member Functions

 ControlBoardWrapper ()
 Constructor. More...
 
virtual ~ControlBoardWrapper ()
 
bool verbose () const
 Return the value of the verbose flag. More...
 
yarp::os::ConstString getId ()
 
virtual bool open ()
 Default open() method. More...
 
virtual bool close () override
 Close the device driver by deallocating all resources and closing ports. More...
 
virtual bool open (yarp::os::Searchable &prop) override
 Open the device driver. More...
 
virtual bool detachAll () override
 Detach the object (you must have first called attach). More...
 
virtual bool attachAll (const yarp::dev::PolyDriverList &l) override
 Attach to a list of objects. More...
 
virtual void run () override
 The thread main loop deals with writing on ports here. More...
 
virtual bool setPid (const PidControlTypeEnum &pidtype, int j, const Pid &p) override
 Set new pid value for a joint axis. More...
 
virtual bool setPids (const PidControlTypeEnum &pidtype, const Pid *ps) override
 Set new pid value on multiple axes. More...
 
virtual bool setPidReference (const PidControlTypeEnum &pidtype, int j, double ref) override
 Set the controller reference for a given axis. More...
 
virtual bool setPidReferences (const PidControlTypeEnum &pidtype, const double *refs) override
 Set the controller reference, multiple axes. More...
 
virtual bool setPidErrorLimit (const PidControlTypeEnum &pidtype, int j, double limit) override
 Set the error limit for the controller on a specifi joint. More...
 
virtual bool setPidErrorLimits (const PidControlTypeEnum &pidtype, const double *limits) override
 Get the error limit for the controller on all joints. More...
 
virtual bool getPidError (const PidControlTypeEnum &pidtype, int j, double *err) override
 Get the current error for a joint. More...
 
virtual bool getPidErrors (const PidControlTypeEnum &pidtype, double *errs) override
 Get the error of all joints. More...
 
virtual bool getPidOutput (const PidControlTypeEnum &pidtype, int j, double *out) override
 Get the output of the controller (e.g. More...
 
virtual bool getPidOutputs (const PidControlTypeEnum &pidtype, double *outs) override
 Get the output of the controllers (e.g. More...
 
virtual bool setPidOffset (const PidControlTypeEnum &pidtype, int j, double v) override
 Set offset value for a given controller. More...
 
virtual bool getPid (const PidControlTypeEnum &pidtype, int j, Pid *p) override
 Get current pid value for a specific joint. More...
 
virtual bool getPids (const PidControlTypeEnum &pidtype, Pid *pids) override
 Get current pid value for a specific joint. More...
 
virtual bool getPidReference (const PidControlTypeEnum &pidtype, int j, double *ref) override
 Get the current reference of the pid controller for a specific joint. More...
 
virtual bool getPidReferences (const PidControlTypeEnum &pidtype, double *refs) override
 Get the current reference of all pid controllers. More...
 
virtual bool getPidErrorLimit (const PidControlTypeEnum &pidtype, int j, double *limit) override
 Get the error limit for the controller on a specific joint. More...
 
virtual bool getPidErrorLimits (const PidControlTypeEnum &pidtype, double *limits) override
 Get the error limit for all controllers. More...
 
virtual bool resetPid (const PidControlTypeEnum &pidtype, int j) override
 Reset the controller of a given joint, usually sets the current status of the joint as the reference value for the PID, and resets the integrator. More...
 
virtual bool disablePid (const PidControlTypeEnum &pidtype, int j) override
 Disable the pid computation for a joint. More...
 
virtual bool enablePid (const PidControlTypeEnum &pidtype, int j) override
 Enable the pid computation for a joint. More...
 
virtual bool isPidEnabled (const PidControlTypeEnum &pidtype, int j, bool *enabled) override
 Get the current status (enabled/disabled) of the pid. More...
 
virtual bool getAxes (int *ax) override
 Get the number of controlled axes. More...
 
virtual bool positionMove (int j, double ref) override
 Set new reference point for a single axis. More...
 
virtual bool positionMove (const double *refs) override
 Set new reference point for all axes. More...
 
virtual bool positionMove (const int n_joints, const int *joints, const double *refs) override
 Set new reference point for a subset of axis. More...
 
virtual bool getTargetPosition (const int joint, double *ref) override
 Get the last position reference for the specified axis. More...
 
virtual bool getTargetPositions (double *refs) override
 Get the last position reference for all axes. More...
 
virtual bool getTargetPositions (const int n_joint, const int *joints, double *refs) override
 Get the last position reference for the specified group of axes. More...
 
virtual bool relativeMove (int j, double delta) override
 Set relative position. More...
 
virtual bool relativeMove (const double *deltas) override
 Set relative position, all joints. More...
 
virtual bool relativeMove (const int n_joints, const int *joints, const double *deltas) override
 Set relative position for a subset of joints. More...
 
virtual bool checkMotionDone (int j, bool *flag) override
 Check if the current trajectory is terminated. More...
 
virtual bool checkMotionDone (bool *flag) override
 Check if the current trajectory is terminated. More...
 
virtual bool checkMotionDone (const int n_joints, const int *joints, bool *flags) override
 Check if the current trajectory is terminated. More...
 
virtual bool setRefSpeed (int j, double sp) override
 Set reference speed for a joint, this is the speed used during the interpolation of the trajectory. More...
 
virtual bool setRefSpeeds (const double *spds) override
 Set reference speed on all joints. More...
 
virtual bool setRefSpeeds (const int n_joints, const int *joints, const double *spds) override
 Set reference speed on all joints. More...
 
virtual bool setRefAcceleration (int j, double acc) override
 Set reference acceleration for a joint. More...
 
virtual bool setRefAccelerations (const double *accs) override
 Set reference acceleration on all joints. More...
 
virtual bool setRefAccelerations (const int n_joints, const int *joints, const double *accs) override
 Set reference acceleration on all joints. More...
 
virtual bool getRefSpeed (int j, double *ref) override
 Get reference speed for a joint. More...
 
virtual bool getRefSpeeds (double *spds) override
 Get reference speed of all joints. More...
 
virtual bool getRefSpeeds (const int n_joints, const int *joints, double *spds) override
 Get reference speed of all joints. More...
 
virtual bool getRefAcceleration (int j, double *acc) override
 Get reference acceleration for a joint. More...
 
virtual bool getRefAccelerations (double *accs) override
 Get reference acceleration of all joints. More...
 
virtual bool getRefAccelerations (const int n_joints, const int *joints, double *accs) override
 Get reference acceleration for a joint. More...
 
virtual bool stop (int j) override
 Stop motion, single joint. More...
 
virtual bool stop () override
 Stop motion, multiple joints. More...
 
virtual bool stop (const int n_joints, const int *joints) override
 Stop motion for subset of joints. More...
 
virtual bool velocityMove (int j, double v) override
 Set new reference speed for a single axis. More...
 
virtual bool velocityMove (const double *v) override
 Set a new reference speed for all axes. More...
 
virtual bool resetEncoder (int j) override
 Reset encoder, single joint. More...
 
virtual bool resetEncoders () override
 Reset encoders. More...
 
virtual bool setEncoder (int j, double val) override
 Set the value of the encoder for a given joint. More...
 
virtual bool setEncoders (const double *vals) override
 Set the value of all encoders. More...
 
virtual bool getEncoder (int j, double *v) override
 Read the value of an encoder. More...
 
virtual bool getEncoders (double *encs) override
 Read the position of all axes. More...
 
virtual bool getEncodersTimed (double *encs, double *t) override
 Read the instantaneous acceleration of all axes. More...
 
virtual bool getEncoderTimed (int j, double *v, double *t) override
 Read the instantaneous acceleration of all axes. More...
 
virtual bool getEncoderSpeed (int j, double *sp) override
 Read the istantaneous speed of an axis. More...
 
virtual bool getEncoderSpeeds (double *spds) override
 Read the instantaneous speed of all axes. More...
 
virtual bool getEncoderAcceleration (int j, double *acc) override
 Read the instantaneous acceleration of an axis. More...
 
virtual bool getEncoderAccelerations (double *accs) override
 Read the istantaneous acceleration of all axes. More...
 
virtual bool getNumberOfMotorEncoders (int *num) override
 Get the number of available motor encoders. More...
 
virtual bool resetMotorEncoder (int m) override
 Reset encoder, single joint. More...
 
virtual bool resetMotorEncoders () override
 Reset encoders. More...
 
virtual bool setMotorEncoderCountsPerRevolution (int m, const double cpr) override
 Sets number of counts per revolution for motor encoder m. More...
 
virtual bool getMotorEncoderCountsPerRevolution (int m, double *cpr) override
 gets number of counts per revolution for motor encoder m. More...
 
virtual bool setMotorEncoder (int m, const double val) override
 Set the value of the encoder for a given joint. More...
 
virtual bool setMotorEncoders (const double *vals) override
 Set the value of all encoders. More...
 
virtual bool getMotorEncoder (int m, double *v) override
 Read the value of an encoder. More...
 
virtual bool getMotorEncoders (double *encs) override
 Read the position of all axes. More...
 
virtual bool getMotorEncodersTimed (double *encs, double *t) override
 Read the instantaneous position of all motor encoders. More...
 
virtual bool getMotorEncoderTimed (int m, double *v, double *t) override
 Read the instantaneous position of a motor encoder. More...
 
virtual bool getMotorEncoderSpeed (int m, double *sp) override
 Read the istantaneous speed of an axis. More...
 
virtual bool getMotorEncoderSpeeds (double *spds) override
 Read the instantaneous speed of all axes. More...
 
virtual bool getMotorEncoderAcceleration (int m, double *acc) override
 Read the instantaneous acceleration of an axis. More...
 
virtual bool getMotorEncoderAccelerations (double *accs) override
 Read the istantaneous acceleration of all axes. More...
 
virtual bool enableAmp (int j) override
 Enable the amplifier on a specific joint. More...
 
virtual bool disableAmp (int j) override
 Disable the amplifier on a specific joint. More...
 
virtual bool getAmpStatus (int *st) override
 Get the status of the amplifiers, coded in a 32 bits integer for each amplifier (at the moment contains only the fault, it will be expanded in the future). More...
 
virtual bool getAmpStatus (int j, int *v) override
 
virtual bool getCurrents (double *vals) override
 Read the electric current going to all motors. More...
 
virtual bool getCurrent (int j, double *val) override
 Read the electric current going to a given motor. More...
 
virtual bool setMaxCurrent (int j, double v) override
 Set the maximum electric current going to a given motor. More...
 
virtual bool getMaxCurrent (int j, double *v) override
 Returns the maximum electric current allowed for a given motor. More...
 
virtual bool getNominalCurrent (int m, double *val) override
 
virtual bool getPeakCurrent (int m, double *val) override
 
virtual bool setPeakCurrent (int m, const double val) override
 
virtual bool getPWM (int m, double *val) override
 
virtual bool getPWMLimit (int m, double *val) override
 
virtual bool setPWMLimit (int m, const double val) override
 
virtual bool getPowerSupplyVoltage (int m, double *val) override
 
virtual bool setLimits (int j, double min, double max) override
 Set the software limits for a particular axis, the behavior of the control card when these limits are exceeded, depends on the implementation. More...
 
virtual bool getLimits (int j, double *min, double *max) override
 Get the software limits for a particular axis. More...
 
virtual bool setVelLimits (int j, double min, double max) override
 Set the software velocity limits for a particular axis, the behavior of the control card when these limits are exceeded, depends on the implementation. More...
 
virtual bool getVelLimits (int j, double *min, double *max) override
 Get the software velocity limits for a particular axis. More...
 
virtual bool getRemoteVariable (yarp::os::ConstString key, yarp::os::Bottle &val) override
 
virtual bool setRemoteVariable (yarp::os::ConstString key, const yarp::os::Bottle &val) override
 
virtual bool getRemoteVariablesList (yarp::os::Bottle *listOfKeys) override
 
bool isCalibratorDevicePresent (bool *isCalib) override
 isCalibratorDevicePresent: check if a calibrator device has been set More...
 
virtual yarp::dev::IRemoteCalibratorgetCalibratorDevice () override
 getCalibratorDevice: return the pointer stored with the setCalibratorDevice More...
 
virtual bool calibrateSingleJoint (int j) override
 calibrateSingleJoint: call the calibration procedure for the single joint More...
 
virtual bool calibrateWholePart () override
 calibrateWholePart: call the procedure for calibrating the whole device More...
 
virtual bool homingSingleJoint (int j) override
 homingSingleJoint: call the homing procedure for a single joint More...
 
virtual bool homingWholePart () override
 homingWholePart: call the homing procedure for a the whole part/device More...
 
virtual bool parkSingleJoint (int j, bool _wait=true) override
 parkSingleJoint(): start the parking procedure for the single joint More...
 
virtual bool parkWholePart () override
 parkWholePart: start the parking procedure for the whole part More...
 
virtual bool quitCalibrate () override
 quitCalibrate: interrupt the calibration procedure More...
 
virtual bool quitPark () override
 quitPark: interrupt the park procedure More...
 
virtual bool calibrate (int j, double p) override
 Calibrate a single joint, the calibration method accepts a parameter that is used to accomplish various things internally and is implementation dependent. More...
 
virtual bool calibrate2 (int j, unsigned int ui, double v1, double v2, double v3) override
 
virtual bool setCalibrationParameters (int j, const CalibrationParameters &params) override
 
virtual bool done (int j) override
 Check whether the calibration has been completed. More...
 
virtual bool abortPark () override
 
virtual bool abortCalibration () override
 
virtual bool getNumberOfMotors (int *num) override
 Retrieves the number of controlled axes from the current physical interface. More...
 
virtual bool getTemperature (int m, double *val) override
 Get temperature of a motor. More...
 
virtual bool getTemperatures (double *vals) override
 Get temperature of all the motors. More...
 
virtual bool getTemperatureLimit (int m, double *val) override
 Retreives the current temperature limit for a specific motor. More...
 
virtual bool setTemperatureLimit (int m, const double val) override
 Set the temperature limit for a specific motor. More...
 
virtual bool getGearboxRatio (int m, double *val) override
 Get the gearbox ratio for a specific motor. More...
 
virtual bool setGearboxRatio (int m, const double val) override
 Set the gearbox ratio for a specific motor. More...
 
virtual bool getAxisName (int j, yarp::os::ConstString &name) override
 
virtual bool getJointType (int j, yarp::dev::JointTypeEnum &type) override
 
virtual bool getRefTorques (double *refs) override
 Get the reference value of the torque for all joints. More...
 
virtual bool getRefTorque (int j, double *t) override
 Get the reference value of the torque for a given joint. More...
 
virtual bool setRefTorques (const double *t) override
 Set the reference value of the torque for all joints. More...
 
virtual bool setRefTorque (int j, double t) override
 Set the reference value of the torque for a given joint. More...
 
virtual bool setRefTorques (const int n_joint, const int *joints, const double *t) override
 Set new torque reference for a subset of joints. More...
 
virtual bool getBemfParam (int j, double *t) override
 Get the back-emf compensation gain for a given joint. More...
 
virtual bool setBemfParam (int j, double t) override
 Set the back-emf compensation gain for a given joint. More...
 
virtual bool getMotorTorqueParams (int j, yarp::dev::MotorTorqueParameters *params) override
 Get a subset of motor parameters (bemf, ktau etc) useful for torque control. More...
 
virtual bool setMotorTorqueParams (int j, const yarp::dev::MotorTorqueParameters params) override
 Set a subset of motor parameters (bemf, ktau etc) useful for torque control. More...
 
virtual bool setImpedance (int j, double stiff, double damp) override
 Set current impedance gains (stiffness,damping) for a specific joint. More...
 
virtual bool setImpedanceOffset (int j, double offset) override
 Set current force Offset for a specific joint. More...
 
virtual 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...
 
virtual bool getTorques (double *t) override
 Get the value of the torque for all joints (this is the feedback if you have torque sensors). More...
 
virtual bool getTorqueRange (int j, double *min, double *max) override
 Get the full scale of the torque sensor of a given joint. More...
 
virtual bool getTorqueRanges (double *min, double *max) override
 Get the full scale of the torque sensors of all joints. More...
 
virtual bool getImpedance (int j, double *stiff, double *damp) override
 Get current impedance gains (stiffness,damping,offset) for a specific joint. More...
 
virtual bool getImpedanceOffset (int j, double *offset) override
 Get current force Offset for a specific joint. More...
 
virtual bool getCurrentImpedanceLimit (int j, double *min_stiff, double *max_stiff, double *min_damp, double *max_damp) override
 Get the current impedandance limits for a specific joint. More...
 
virtual bool getControlMode (int j, int *mode) override
 Get the current control mode. More...
 
virtual bool getControlModes (int *modes) override
 Get the current control mode (multiple joints). More...
 
virtual bool getControlModes (const int n_joint, const int *joints, int *modes) override
 Get the current control mode for a subset of axes. More...
 
virtual bool setControlMode (const int j, const int mode) override
 Set the current control mode. More...
 
virtual bool setControlModes (const int n_joints, const int *joints, int *modes) override
 Set the current control mode for a subset of axes. More...
 
virtual bool setControlModes (int *modes) override
 Set the current control mode (multiple joints). More...
 
virtual bool setPosition (int j, double ref) override
 Set new position for a single axis. More...
 
virtual bool setPositions (const int n_joints, const int *joints, double *dpos) override
 Set new reference point for all axes. More...
 
virtual bool setPositions (const double *refs) override
 Set new position for a set of axis. More...
 
virtual bool getRefPosition (const int joint, double *ref) override
 Get the last position reference for the specified axis. More...
 
virtual bool getRefPositions (double *refs) override
 Get the last position reference for all axes. More...
 
virtual bool getRefPositions (const int n_joint, const int *joints, double *refs) override
 Get the last position reference for the specified group of axes. More...
 
virtual yarp::os::Stamp getLastInputStamp () override
 Return the time stamp relative to the last acquisition. More...
 
virtual 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...
 
virtual bool getRefVelocity (const int joint, double *vel) override
 Get the last reference speed set by velocityMove for single joint. More...
 
virtual bool getRefVelocities (double *vels) override
 Get the last reference speed set by velocityMove for all joints. More...
 
virtual 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...
 
virtual bool getInteractionMode (int j, yarp::dev::InteractionModeEnum *mode) override
 Get the current interaction mode of the robot, values can be stiff or compliant. More...
 
virtual bool getInteractionModes (int n_joints, int *joints, yarp::dev::InteractionModeEnum *modes) override
 Get the current interaction mode of the robot for a set of joints, values can be stiff or compliant. More...
 
virtual bool getInteractionModes (yarp::dev::InteractionModeEnum *modes) override
 Get the current interaction mode of the robot for a all the joints, values can be stiff or compliant. More...
 
virtual bool setInteractionMode (int j, yarp::dev::InteractionModeEnum mode) override
 Set the interaction mode of the robot, values can be stiff or compliant. More...
 
virtual bool setInteractionModes (int n_joints, int *joints, yarp::dev::InteractionModeEnum *modes) override
 Set the interaction mode of the robot for a set of joints, values can be stiff or compliant. More...
 
virtual bool setInteractionModes (yarp::dev::InteractionModeEnum *modes) override
 Set the interaction mode of the robot for a all the joints, values can be stiff or compliant. More...
 
virtual bool setRefDutyCycle (int j, double v) override
 Sets the reference dutycycle to a single motor. More...
 
virtual bool setRefDutyCycles (const double *v) override
 Sets the reference dutycycle for all the motors. More...
 
virtual bool getRefDutyCycle (int j, double *v) override
 Gets the last reference sent using the setRefDutyCycle function. More...
 
virtual bool getRefDutyCycles (double *v) override
 Gets the last reference sent using the setRefDutyCycles function. More...
 
virtual bool getDutyCycle (int j, double *v) override
 Gets the current dutycycle of the output of the amplifier (i.e. More...
 
virtual bool getDutyCycles (double *v) override
 Gets the current dutycycle of the output of the amplifier (i.e. More...
 
virtual bool getCurrentRange (int j, double *min, double *max) override
 Get the full scale of the current measurement for a given motor (e.g. More...
 
virtual bool getCurrentRanges (double *min, double *max) override
 Get the full scale of the current measurements for all motors motor (e.g. More...
 
virtual bool setRefCurrents (const double *t) override
 Set the reference value of the currents for all motors. More...
 
virtual bool setRefCurrent (int j, double t) override
 Set the reference value of the current for a single motor. More...
 
virtual bool setRefCurrents (const int n_joint, const int *joints, const double *t) override
 Set the reference value of the current for a group of motors. More...
 
virtual bool getRefCurrents (double *t) override
 Get the reference value of the currents for all motors. More...
 
virtual bool getRefCurrent (int j, double *t) override
 Get the reference value of the current for a single motor. More...
 
- Public Member Functions inherited from yarp::dev::DeviceDriver
virtual ~DeviceDriver ()
 Destructor. More...
 
template<class T >
bool view (T *&x)
 Get an interface to the device driver. More...
 
virtual DeviceDrivergetImplementation ()
 Some drivers are bureaucrats, pointing at others. More...
 
- Public Member Functions inherited from yarp::os::IConfig
virtual ~IConfig ()
 Destructor. More...
 
virtual bool configure (Searchable &config)
 Change online parameters. More...
 
- Public Member Functions inherited from yarp::os::RateThread
 RateThread (int period)
 Constructor. More...
 
virtual ~RateThread ()
 
virtual bool threadInit ()
 Initialization method. More...
 
virtual void threadRelease ()
 Release method. More...
 
bool start ()
 Call this to start the thread. More...
 
bool step ()
 Call this to "step" the thread rather than starting it. More...
 
void stop ()
 Call this to stop the thread, this call blocks until the thread is terminated (and releaseThread() called). More...
 
void askToStop ()
 Stop the thread. More...
 
bool isRunning ()
 Returns true when the thread is started, false otherwise. More...
 
bool isSuspended ()
 Returns true when the thread is suspended, false otherwise. More...
 
bool setRate (int period)
 Set the (new) rate of the thread. More...
 
double getRate ()
 Return the current rate of the thread. More...
 
void suspend ()
 Suspend the thread, the thread keeps running by doLoop is never executed. More...
 
void resume ()
 Resume the thread if previously suspended. More...
 
void resetStat ()
 Reset thread statistics. More...
 
double getEstPeriod ()
 Return estimated period since last reset. More...
 
void getEstPeriod (double &av, double &std)
 Return estimated period since last reset. More...
 
unsigned int getIterations ()
 Return the number of iterations performed since last reset. More...
 
double getEstUsed ()
 Return the estimated duration of the run() function since last reset. More...
 
void getEstUsed (double &av, double &std)
 Return estimated duration of the run() function since last reset. More...
 
virtual void beforeStart ()
 Called just before a new thread starts. More...
 
virtual void afterStart (bool success)
 Called just after a new thread starts (or fails to start), this is executed by the same thread that calls start(). More...
 
int setPriority (int priority, int policy=-1)
 Set the priority and scheduling policy of the thread, if the OS supports that. More...
 
int getPriority ()
 Query the current priority of the thread, if the OS supports that. More...
 
int getPolicy ()
 Query the current scheduling policy of the thread, if the OS supports that. More...
 
- Public Member Functions inherited from yarp::dev::IPidControl
virtual ~IPidControl ()
 Destructor. More...
 
bool setPid (int j, const Pid &pid)
 Set new pid value for a joint axis. More...
 
bool setPids (const Pid *pids)
 Set new pid value on multiple axes. More...
 
bool setReference (int j, double ref)
 Set the controller reference point for a given axis. More...
 
bool setReferences (const double *refs)
 Set the controller reference points, multiple axes. More...
 
bool setErrorLimit (int j, double limit)
 Set the error limit for the controller on a specifi joint. More...
 
bool setErrorLimits (const double *limits)
 Get the error limit for the controller on all joints. More...
 
bool getError (int j, double *err)
 Get the current error for a joint. More...
 
bool getErrors (double *errs)
 Get the error of all joints. More...
 
bool getOutput (int j, double *out)
 Get the output of the controller (e.g. More...
 
bool getOutputs (double *outs)
 Get the output of the controllers (e.g. More...
 
bool getPid (int j, Pid *pid)
 Get current pid value for a specific joint. More...
 
bool getPids (Pid *pids)
 Get current pid value for a specific joint. More...
 
bool getReference (int j, double *ref)
 Get the current reference position of the controller for a specific joint. More...
 
bool getReferences (double *refs)
 Get the current reference position of all controllers. More...
 
bool getErrorLimit (int j, double *limit)
 Get the error limit for the controller on a specific joint. More...
 
bool getErrorLimits (double *limits)
 Get the error limit for all controllers. More...
 
bool resetPid (int j)
 Reset the controller of a given joint, usually sets the current position of the joint as the reference value for the PID, and resets the integrator. More...
 
bool disablePid (int j)
 Disable the pid computation for a joint. More...
 
bool enablePid (int j)
 Enable the pid computation for a joint. More...
 
bool setOffset (int j, double v)
 Set offset value for a given controller. More...
 
- Public Member Functions inherited from yarp::dev::IPositionControl2
virtual ~IPositionControl2 ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IPositionControl
virtual ~IPositionControl ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IPositionDirect
virtual ~IPositionDirect ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IVelocityControl2
virtual ~IVelocityControl2 ()
 Destructor. More...
 
virtual bool setVelPid (int j, const yarp::dev::Pid &pid)
 Set new velocity pid value for a joint. More...
 
virtual bool setVelPids (const yarp::dev::Pid *pids)
 Set new velocity pid value on multiple joints. More...
 
virtual bool getVelPid (int j, yarp::dev::Pid *pid)
 Get current velocity pid value for a specific joint. More...
 
virtual bool getVelPids (yarp::dev::Pid *pids)
 Get current velocity pid value for a specific subset of joints. More...
 
- Public Member Functions inherited from yarp::dev::IVelocityControl
virtual ~IVelocityControl ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IEncodersTimed
virtual ~IEncodersTimed ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IEncoders
virtual ~IEncoders ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IMotor
virtual ~IMotor ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IMotorEncoders
virtual ~IMotorEncoders ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IAmplifierControl
virtual ~IAmplifierControl ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IControlLimits2
virtual ~IControlLimits2 ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IControlLimits
virtual ~IControlLimits ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IRemoteCalibrator
 IRemoteCalibrator ()
 This interface is meant to remotize the access of the calibration device in order to allow users to remotely call the calibration procedure for a single joint or the whole device and let the calibrator do the job. More...
 
virtual ~IRemoteCalibrator ()
 
virtual bool setCalibratorDevice (yarp::dev::IRemoteCalibrator *dev)
 setCalibratorDevice: store the pointer to the calibrator device. More...
 
virtual void releaseCalibratorDevice (void)
 releaseCalibratorDevice: reset the internal pointer to NULL when stop using the calibrator More...
 
- Public Member Functions inherited from yarp::dev::IControlCalibration
 IControlCalibration ()
 
virtual ~IControlCalibration ()
 Destructor. More...
 
virtual bool setCalibrator (ICalibrator *c)
 
virtual bool calibrate ()
 
virtual bool park (bool wait=true)
 
- Public Member Functions inherited from yarp::dev::IControlCalibration2
 IControlCalibration2 ()
 IControlCalibration2. More...
 
virtual ~IControlCalibration2 ()
 Destructor. More...
 
virtual bool setCalibrator (ICalibrator *c)
 
virtual bool calibrate ()
 
virtual bool park (bool wait=true)
 
- Public Member Functions inherited from yarp::dev::ITorqueControl
virtual ~ITorqueControl ()
 Destructor. More...
 
virtual bool setTorquePid (int j, const Pid &pid)
 Set new pid value for a joint axis. More...
 
virtual bool setTorquePids (const Pid *pids)
 Set new pid value on multiple axes. More...
 
virtual bool setTorqueErrorLimit (int j, double limit)
 Set the torque error limit for the controller on a specific joint. More...
 
virtual bool setTorqueErrorLimits (const double *limits)
 Get the torque error limit for the controller on all joints. More...
 
virtual bool getTorqueError (int j, double *err)
 Get the current torque error for a joint. More...
 
virtual bool getTorqueErrors (double *errs)
 Get the torque error of all joints. More...
 
virtual bool getTorquePidOutput (int j, double *out)
 Get the output of the controller (e.g. More...
 
virtual bool getTorquePidOutputs (double *outs)
 Get the output of the controllers (e.g. More...
 
virtual bool getTorquePid (int j, Pid *pid)
 Get current pid value for a specific joint. More...
 
virtual bool getTorquePids (Pid *pids)
 Get current pid value for a specific joint. More...
 
virtual bool getTorqueErrorLimit (int j, double *limit)
 Get the torque error limit for the controller on a specific joint. More...
 
virtual bool getTorqueErrorLimits (double *limits)
 Get the torque error limit for all controllers. More...
 
virtual bool resetTorquePid (int j)
 Reset the controller of a given joint, usually sets the current position of the joint as the reference value for the PID, and resets the integrator. More...
 
virtual bool disableTorquePid (int j)
 Disable the pid computation for a joint. More...
 
virtual bool enableTorquePid (int j)
 Enable the pid computation for a joint. More...
 
virtual bool setTorqueOffset (int j, double v)
 Set offset value for a given pid. More...
 
- Public Member Functions inherited from yarp::dev::IImpedanceControl
virtual ~IImpedanceControl ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IControlMode2
virtual ~IControlMode2 ()
 
- Public Member Functions inherited from yarp::dev::IControlMode
virtual ~IControlMode ()
 
virtual bool setPositionMode (int j)
 Set position mode, single axis. More...
 
virtual bool setVelocityMode (int j)
 Set velocity mode, single axis. More...
 
virtual bool setTorqueMode (int j)
 Set torque mode, single axis. More...
 
virtual bool setImpedancePositionMode (int j)
 Set impedance position mode, single axis. More...
 
virtual bool setImpedanceVelocityMode (int j)
 Set impedance velocity mode, single axis. More...
 
- Public Member Functions inherited from yarp::dev::IMultipleWrapper
virtual ~IMultipleWrapper ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IAxisInfo
virtual ~IAxisInfo ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IPreciselyTimed
virtual ~IPreciselyTimed ()
 
- Public Member Functions inherited from yarp::dev::IInteractionMode
virtual ~IInteractionMode ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IRemoteVariables
virtual ~IRemoteVariables ()
 Destructor. More...
 
- Public Member Functions inherited from yarp::dev::IPWMControl
virtual ~IPWMControl ()
 
- Public Member Functions inherited from yarp::dev::ICurrentControl
virtual ~ICurrentControl ()
 Destructor. More...
 

Detailed Description

Description of input parameters

A updated version of the controlBoard network wrapper. It can merge toghether more than one control board device, or use only a portion of it by remapping functionality. Allows also deferred attach/detach of a subdevice.

Parameters required by this device are:

Parameter name SubParameter Type Units Default Value Required Description Notes
name - string - - Yes full name of the port opened by the device, like /robotName/part/ MUST start with a '/' character
period - int ms 20 No refresh period of the broadcasted values in ms optional, default 20ms
subdevice - string - - alternative to netwok group name of the subdevice to instantiate when used, parameters for the subdevice must be provided as well
networks - group - - alternative to subdevice this is expected to be a group parameter in xml format, a list in .ini file format. SubParameter are mandatory if this is used-
- networkName_1 4 * int joint number - if networks is used describe how to match subdevice_1 joints with the wrapper joints. First 2 numbers indicate first/last wrapper joint, last 2 numbers are subdevice first/last joint The joints are intended to be consequent
- ... 4 * int joint number - if networks is used same as above The joints are intended to be consequent
- networkName_n 4 * int joint number - if networks is used same as above The joints are intended to be consequent
- joints int - - if networks is used total number of joints handled by the wrapper MUST match the sum of joints from all the networks
ROS - group - - No Group containing parameter for ROS topic initialization if missing, it is assumed to not use ROS topics
- useROS string true/false/only- if ROS group is present set 'true' to have both yarp ports and ROS topic, set 'only' to have only ROS topic and no yarp port-
- ROS_topicName string - - if ROS group is present set the name for ROS topic must start with a leading '/'
- ROS_nodeName string - - if ROS group is present set the name for ROS node must start with a leading '/'
- jointNames string - - deprecated joints names are now got from attached motionControl device names order must match with the joint order, from 0 to N

ROS message type used is sensor_msgs/JointState.msg (http://docs.ros.org/api/sensor_msgs/html/msg/JointState.html) Some example of configuration files:

Configuration file using .ini format, using subdevice keyword.

device controlboardwrapper2
subdevice fakebot
name /icub/head
** parameter for 'fakebot' subdevice follows here **
...

XML format, using 'networks' keywork. This file is meant to be used in junction with yarprobotinterface executable, therefore has an addictional section at the end.

<paramlist name="networks">
<!-- elem name hereafter are custom names that live only in this file, they are used in the attach phase -->
<elem name="FirstSetOfJoints"> 0 3 0 3 </elem>
<elem name="SecondSetOfJoints"> 4 6 0 2 </elem>
</paramlist>
<param name="period"> 20 </param>
<param name="name"> /icub/left_arm </param>
<param name="joints"> 7 </param>
<!-- Following parameters are meaningful ONLY for yarprobotinterface -->
<action phase="startup" level="5" type="attach">
<paramlist name="networks">
<!-- The param value must match the device name in the corresponding emsX file -->
<elem name="FirstSetOfJoints"> left_upper_arm_mc </elem>
<elem name="SecondSetOfJoints"> left_lower_arm_mc </elem>
</paramlist>
</action>
<action phase="shutdown" level="5" type="detach" />

Configuration file using .ini format, using network keyword

device controlboardwrapper2
name /robotName/partName
period 10
networks (net_larm net_lhand)
joints 16
net_larm 0 3 0 3
net_lhand 4 6 0 2

Configuration for ROS topic using .ini format

[ROS]
useROS true
ROS_topicName /JointState
ROS_nodeName /robotPublisher
jointNames r_shoulder_pitch r_shoulder_roll r_shoulder_yaw r_elbow r_wrist_prosup r_wrist_pitch r_wrist_yaw

Configuration for ROS topic using .xml format

<group name="ROS">
<param name="useROS"> true </param> // use 'only' if you want only ROS topic and NOT yarp port
<param name="ROS_topicName"> /JointState </param>
<param name="ROS_nodeName"> /robotPublisher </param>
<param name="jointNames"> r_shoulder_pitch r_shoulder_roll r_shoulder_yaw r_elbow r_wrist_prosup r_wrist_pitch r_wrist_yaw </param>
</group>

Definition at line 262 of file ControlBoardWrapper.h.

Constructor & Destructor Documentation

◆ ControlBoardWrapper()

ControlBoardWrapper::ControlBoardWrapper ( )

Constructor.

Definition at line 30 of file ControlBoardWrapper.cpp.

◆ ~ControlBoardWrapper()

ControlBoardWrapper::~ControlBoardWrapper ( )
virtual

Definition at line 70 of file ControlBoardWrapper.cpp.

Member Function Documentation

◆ abortCalibration()

bool ControlBoardWrapper::abortCalibration ( )
overridevirtual

Reimplemented from yarp::dev::IControlCalibration2.

Definition at line 3661 of file ControlBoardWrapper.cpp.

◆ abortPark()

bool ControlBoardWrapper::abortPark ( )
overridevirtual

Reimplemented from yarp::dev::IControlCalibration2.

Definition at line 3655 of file ControlBoardWrapper.cpp.

◆ attachAll()

bool ControlBoardWrapper::attachAll ( const yarp::dev::PolyDriverList p)
overridevirtual

Attach to a list of objects.

Parameters
pthe polydriver list that you want to attach to.
Returns
true/false on success failure.

Implements yarp::dev::IMultipleWrapper.

Definition at line 754 of file ControlBoardWrapper.cpp.

◆ calibrate()

bool ControlBoardWrapper::calibrate ( int  j,
double  p 
)
overridevirtual

Calibrate a single joint, the calibration method accepts a parameter that is used to accomplish various things internally and is implementation dependent.

Parameters
jthe axis number.
pis a double value that is passed to the calibration procedure.
Returns
true/false on success/failure.

Implements yarp::dev::IControlCalibration.

Definition at line 3597 of file ControlBoardWrapper.cpp.

◆ calibrate2()

bool ControlBoardWrapper::calibrate2 ( int  j,
unsigned int  ui,
double  v1,
double  v2,
double  v3 
)
overridevirtual

Implements yarp::dev::IControlCalibration2.

Definition at line 3613 of file ControlBoardWrapper.cpp.

◆ calibrateSingleJoint()

bool ControlBoardWrapper::calibrateSingleJoint ( int  j)
overridevirtual

calibrateSingleJoint: call the calibration procedure for the single joint

Parameters
jjoint to be calibrated
Returns
true if calibration was successful

Implements yarp::dev::IRemoteCalibrator.

Definition at line 3523 of file ControlBoardWrapper.cpp.

◆ calibrateWholePart()

bool ControlBoardWrapper::calibrateWholePart ( )
overridevirtual

calibrateWholePart: call the procedure for calibrating the whole device

Returns
true if calibration was successful

Implements yarp::dev::IRemoteCalibrator.

Definition at line 3531 of file ControlBoardWrapper.cpp.

◆ checkMotionDone() [1/3]

bool ControlBoardWrapper::checkMotionDone ( int  j,
bool *  flag 
)
overridevirtual

Check if the current trajectory is terminated.

Non blocking.

Parameters
jthe axis
flagtrue if the trajectory is terminated, false otherwise
Returns
false on failure

Implements yarp::dev::IPositionControl.

Definition at line 1690 of file ControlBoardWrapper.cpp.

◆ checkMotionDone() [2/3]

bool ControlBoardWrapper::checkMotionDone ( bool *  flag)
overridevirtual

Check if the current trajectory is terminated.

Non blocking.

Parameters
flagtrue if the trajectory is terminated, false otherwise (a single value which is the 'and' of all joints')
Returns
false on failure

Non blocking.

Parameters
flagtrue if the trajectory is terminated, false otherwise
Returns
false on failure

Implements yarp::dev::IPositionControl.

Definition at line 1712 of file ControlBoardWrapper.cpp.

◆ checkMotionDone() [3/3]

bool ControlBoardWrapper::checkMotionDone ( const int  n_joints,
const int *  joints,
bool *  flags 
)
overridevirtual

Check if the current trajectory is terminated.

Non blocking.

Parameters
jointspointer to the array of joint numbers
flagtrue if the trajectory is terminated, false otherwise (a single value which is the 'and' of all joints')
Returns
true/false if network communication went well.

Implements yarp::dev::IPositionControl2.

Definition at line 1744 of file ControlBoardWrapper.cpp.

◆ close()

bool ControlBoardWrapper::close ( void  )
overridevirtual

Close the device driver by deallocating all resources and closing ports.

Returns
true if successful or false otherwise.

Reimplemented from yarp::dev::DeviceDriver.

Definition at line 72 of file ControlBoardWrapper.cpp.

◆ detachAll()

bool ControlBoardWrapper::detachAll ( )
overridevirtual

Detach the object (you must have first called attach).

Returns
true/false on success failure.

Implements yarp::dev::IMultipleWrapper.

Definition at line 815 of file ControlBoardWrapper.cpp.

◆ disableAmp()

bool ControlBoardWrapper::disableAmp ( int  j)
overridevirtual

Disable the amplifier on a specific joint.

All computations within the board will be carried out normally, but the output will be disabled.

Returns
true/false on success/failure

Implements yarp::dev::IAmplifierControl.

Definition at line 3160 of file ControlBoardWrapper.cpp.

◆ disablePid()

bool ControlBoardWrapper::disablePid ( const PidControlTypeEnum pidtype,
int  j 
)
overridevirtual

Disable the pid computation for a joint.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
Returns
true on success, false on failure.

Implements yarp::dev::IPidControl.

Definition at line 1291 of file ControlBoardWrapper.cpp.

◆ done()

bool ControlBoardWrapper::done ( int  j)
overridevirtual

Check whether the calibration has been completed.

Parameters
jis the joint that has started a calibration procedure.
Returns
true/false on success/failure.

Implements yarp::dev::IControlCalibration.

Definition at line 3639 of file ControlBoardWrapper.cpp.

◆ enableAmp()

bool ControlBoardWrapper::enableAmp ( int  j)
overridevirtual

Enable the amplifier on a specific joint.

Be careful, check that the output of the controller is appropriate (usually zero), to avoid generating abrupt movements.

Returns
true/false on success/failure

Implements yarp::dev::IAmplifierControl.

Definition at line 3144 of file ControlBoardWrapper.cpp.

◆ enablePid()

bool ControlBoardWrapper::enablePid ( const PidControlTypeEnum pidtype,
int  j 
)
overridevirtual

Enable the pid computation for a joint.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
Returns
true on success, false on failure.

Implements yarp::dev::IPidControl.

Definition at line 1306 of file ControlBoardWrapper.cpp.

◆ getAmpStatus() [1/2]

bool ControlBoardWrapper::getAmpStatus ( int *  st)
overridevirtual

Get the status of the amplifiers, coded in a 32 bits integer for each amplifier (at the moment contains only the fault, it will be expanded in the future).

Parameters
stpointer to storage
Returns
true in good luck, false otherwise.

Implements yarp::dev::IAmplifierControl.

Definition at line 3185 of file ControlBoardWrapper.cpp.

◆ getAmpStatus() [2/2]

bool ControlBoardWrapper::getAmpStatus ( int  j,
int *  v 
)
overridevirtual

Implements yarp::dev::IAmplifierControl.

Definition at line 3209 of file ControlBoardWrapper.cpp.

◆ getAxes()

bool ControlBoardWrapper::getAxes ( int *  ax)
overridevirtual

Get the number of controlled axes.

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

Parameters
axpointer to storage
Returns
true/false.

Implements yarp::dev::IImpedanceControl.

Definition at line 1347 of file ControlBoardWrapper.cpp.

◆ getAxisName()

bool ControlBoardWrapper::getAxisName ( int  j,
yarp::os::ConstString name 
)
overridevirtual

Implements yarp::dev::IAxisInfo.

Definition at line 3669 of file ControlBoardWrapper.cpp.

◆ getBemfParam()

bool ControlBoardWrapper::getBemfParam ( int  j,
double *  bemf 
)
overridevirtual

Get the back-emf compensation gain for a given joint.

Parameters
jjoint number
bemfthe returned bemf gain of joint j
Returns
true/false on success/failure

Implements yarp::dev::ITorqueControl.

Definition at line 3816 of file ControlBoardWrapper.cpp.

◆ getCalibratorDevice()

IRemoteCalibrator * ControlBoardWrapper::getCalibratorDevice ( )
overridevirtual

getCalibratorDevice: return the pointer stored with the setCalibratorDevice

Returns
yarp::dev::IRemotizableCalibrator pointer or NULL if not valid

Reimplemented from yarp::dev::IRemoteCalibrator.

Definition at line 3511 of file ControlBoardWrapper.cpp.

◆ getControlMode()

bool ControlBoardWrapper::getControlMode ( int  j,
int *  mode 
)
overridevirtual

Get the current control mode.

Parameters
jjoint number
modea vocab of the current control mode for joint j.
Returns
: true/false success failure.

Implements yarp::dev::IControlMode.

Definition at line 4045 of file ControlBoardWrapper.cpp.

◆ getControlModes() [1/2]

bool ControlBoardWrapper::getControlModes ( int *  modes)
overridevirtual

Get the current control mode (multiple joints).

Parameters
modesa vector containing vocabs for the current control modes of the joints.
Returns
: true/false success failure.

Implements yarp::dev::IControlMode.

Definition at line 4061 of file ControlBoardWrapper.cpp.

◆ getControlModes() [2/2]

bool ControlBoardWrapper::getControlModes ( const int  n_joint,
const int *  joints,
int *  modes 
)
overridevirtual

Get the current control mode for a subset of axes.

Parameters
n_jointshow many joints this command is referring to
jointslist of joint numbers, the size of this array is n_joints
modesarray containing the new controlmodes, one value for each joint, the size is n_joints. The first value will be the new reference fot the joint joints[0]. for example: n_joint 3 joints 0 2 4 modes VOCAB_CM_POSITION VOCAB_CM_VELOCITY VOCAB_CM_POSITION
Returns
true/false success failure.

Implements yarp::dev::IControlMode2.

Definition at line 4085 of file ControlBoardWrapper.cpp.

◆ getCurrent()

bool ControlBoardWrapper::getCurrent ( int  j,
double *  val 
)
overridevirtual

Read the electric current going to a given motor.

Parameters
jmotor number
valpointer to storage for the output value
Returns
probably true, might return false in bad times

Implements yarp::dev::IAmplifierControl.

Definition at line 3246 of file ControlBoardWrapper.cpp.

◆ getCurrentImpedanceLimit()

bool ControlBoardWrapper::getCurrentImpedanceLimit ( int  j,
double *  min_stiff,
double *  max_stiff,
double *  min_damp,
double *  max_damp 
)
overridevirtual

Get the current impedandance limits for a specific joint.

Returns
success/failure

Implements yarp::dev::IImpedanceControl.

Definition at line 4028 of file ControlBoardWrapper.cpp.

◆ getCurrentRange()

bool ControlBoardWrapper::getCurrentRange ( int  m,
double *  min,
double *  max 
)
overridevirtual

Get the full scale of the current measurement for a given motor (e.g.

-20A +20A) Reference values set by user with methods such as setRefCurrent() should be in this range. This method is not related to the current overload protection methods belonging to the iAmplifierControl interface.

Parameters
mmotor number
minminimum current of the motor m
maxmaximum current of the motor m
Returns
true/false on success/failure

Implements yarp::dev::ICurrentControl.

Definition at line 4830 of file ControlBoardWrapper.cpp.

◆ getCurrentRanges()

bool ControlBoardWrapper::getCurrentRanges ( double *  min,
double *  max 
)
overridevirtual

Get the full scale of the current measurements for all motors motor (e.g.

-20A +20A) Reference values set by user with methods such as setRefCurrent() should be in this range. This method is not related to the current overload protection methods belonging to the iAmplifierControl interface.

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

Implements yarp::dev::ICurrentControl.

Definition at line 4848 of file ControlBoardWrapper.cpp.

◆ getCurrents()

bool ControlBoardWrapper::getCurrents ( double *  vals)
overridevirtual

Read the electric current going to all motors.

Parameters
valspointer to storage for the output values
Returns
hopefully true, false in bad luck.

Implements yarp::dev::IAmplifierControl.

Definition at line 3223 of file ControlBoardWrapper.cpp.

◆ getDutyCycle()

bool ControlBoardWrapper::getDutyCycle ( int  m,
double *  val 
)
overridevirtual

Gets the current dutycycle of the output of the amplifier (i.e.

pwm value sent to the motor)

Parameters
mmotor number
valpointer to storage for return value, expressed as percentage (-100% +100%)
Returns
true/false on success/failure

Implements yarp::dev::IPWMControl.

Definition at line 4782 of file ControlBoardWrapper.cpp.

◆ getDutyCycles()

bool ControlBoardWrapper::getDutyCycles ( double *  vals)
overridevirtual

Gets the current dutycycle of the output of the amplifier (i.e.

pwm values sent to all motors)

Parameters
valspointer to the vector that will store the values, expressed as percentage (-100% +100%)
Returns
true/false on success/failure

Implements yarp::dev::IPWMControl.

Definition at line 4799 of file ControlBoardWrapper.cpp.

◆ getEncoder()

bool ControlBoardWrapper::getEncoder ( int  j,
double *  v 
)
overridevirtual

Read the value of an encoder.

Parameters
jencoder number
vpointer to storage for the return value
Returns
true/false, upon success/failure (you knew it, uh?)

Implements yarp::dev::IEncoders.

Definition at line 2552 of file ControlBoardWrapper.cpp.

◆ getEncoderAcceleration()

bool ControlBoardWrapper::getEncoderAcceleration ( int  j,
double *  acc 
)
overridevirtual

Read the instantaneous acceleration of an axis.

Parameters
jaxis number
accpointer to the array that will contain the output

Implements yarp::dev::IEncoders.

Definition at line 2666 of file ControlBoardWrapper.cpp.

◆ getEncoderAccelerations()

bool ControlBoardWrapper::getEncoderAccelerations ( double *  accs)
overridevirtual

Read the istantaneous acceleration of all axes.

Parameters
accspointer to the array that will contain the output
Returns
true if all goes well, false if anything bad happens.

Implements yarp::dev::IEncoders.

Definition at line 2682 of file ControlBoardWrapper.cpp.

◆ getEncoders()

bool ControlBoardWrapper::getEncoders ( double *  encs)
overridevirtual

Read the position of all axes.

Parameters
encspointer to the array that will contain the output
Returns
true/false on success/failure

Implements yarp::dev::IEncoders.

Definition at line 2568 of file ControlBoardWrapper.cpp.

◆ getEncoderSpeed()

bool ControlBoardWrapper::getEncoderSpeed ( int  j,
double *  sp 
)
overridevirtual

Read the istantaneous speed of an axis.

Parameters
jaxis number
sppointer to storage for the output
Returns
true if successful, false ... otherwise.

Implements yarp::dev::IEncoders.

Definition at line 2628 of file ControlBoardWrapper.cpp.

◆ getEncoderSpeeds()

bool ControlBoardWrapper::getEncoderSpeeds ( double *  spds)
overridevirtual

Read the instantaneous speed of all axes.

Parameters
spdspointer to storage for the output values
Returns
guess what? (true/false on success or failure).

Implements yarp::dev::IEncoders.

Definition at line 2644 of file ControlBoardWrapper.cpp.

◆ getEncodersTimed()

bool ControlBoardWrapper::getEncodersTimed ( double *  encs,
double *  time 
)
overridevirtual

Read the instantaneous acceleration of all axes.

Parameters
encspointer to the array that will contain the output
timepointer to the array that will contain individual timestamps
Returns
true if all goes well, false if anything bad happens.

Implements yarp::dev::IEncodersTimed.

Definition at line 2590 of file ControlBoardWrapper.cpp.

◆ getEncoderTimed()

bool ControlBoardWrapper::getEncoderTimed ( int  j,
double *  encs,
double *  time 
)
overridevirtual

Read the instantaneous acceleration of all axes.

Parameters
jaxis index
encsencoder value (pointer to)
timecorresponding timestamp (pointer to)
Returns
true if all goes well, false if anything bad happens.

Implements yarp::dev::IEncodersTimed.

Definition at line 2612 of file ControlBoardWrapper.cpp.

◆ getGearboxRatio()

bool ControlBoardWrapper::getGearboxRatio ( int  m,
double *  val 
)
overridevirtual

Get the gearbox ratio for a specific motor.

Parameters
mmotor number
valretrieved gearbox ratio
Returns
true/false

Reimplemented from yarp::dev::IMotor.

Definition at line 2780 of file ControlBoardWrapper.cpp.

◆ getId()

yarp::os::ConstString yarp::dev::ControlBoardWrapper::getId ( )
inline

Definition at line 368 of file ControlBoardWrapper.h.

◆ getImpedance()

bool ControlBoardWrapper::getImpedance ( int  j,
double *  stiffness,
double *  damping 
)
overridevirtual

Get current impedance gains (stiffness,damping,offset) for a specific joint.

Returns
success/failure

Implements yarp::dev::IImpedanceControl.

Definition at line 3994 of file ControlBoardWrapper.cpp.

◆ getImpedanceOffset()

bool ControlBoardWrapper::getImpedanceOffset ( int  j,
double *  offset 
)
overridevirtual

Get current force Offset for a specific joint.

Returns
success/failure

Implements yarp::dev::IImpedanceControl.

Definition at line 4011 of file ControlBoardWrapper.cpp.

◆ getInteractionMode()

bool ControlBoardWrapper::getInteractionMode ( int  axis,
yarp::dev::InteractionModeEnum mode 
)
overridevirtual

Get the current interaction mode of the robot, values can be stiff or compliant.

Parameters
axisjoint number
modecontains the requested information about interaction mode of the joint
Returns
true or false on success or failure.

Implements yarp::dev::IInteractionMode.

Definition at line 4533 of file ControlBoardWrapper.cpp.

◆ getInteractionModes() [1/2]

bool ControlBoardWrapper::getInteractionModes ( int  n_joints,
int *  joints,
yarp::dev::InteractionModeEnum modes 
)
overridevirtual

Get the current interaction mode of the robot for a set of joints, values can be stiff or compliant.

Parameters
n_jointshow many joints this command is referring to
jointslist of joints controlled. The size of this array is n_joints
modesarray containing the requested information about interaction mode, one value for each joint, the size is n_joints. for example: n_joint 3 joints 0 2 4 refs VOCAB_IM_STIFF VOCAB_IM_STIFF VOCAB_IM_COMPLIANT
Returns
true or false on success or failure.

Implements yarp::dev::IInteractionMode.

Definition at line 4549 of file ControlBoardWrapper.cpp.

◆ getInteractionModes() [2/2]

bool ControlBoardWrapper::getInteractionModes ( yarp::dev::InteractionModeEnum modes)
overridevirtual

Get the current interaction mode of the robot for a all the joints, values can be stiff or compliant.

Parameters
modearray containing the requested information about interaction mode, one value for each joint.
Returns
true or false on success or failure.

Implements yarp::dev::IInteractionMode.

Definition at line 4605 of file ControlBoardWrapper.cpp.

◆ getJointType()

bool ControlBoardWrapper::getJointType ( int  j,
yarp::dev::JointTypeEnum type 
)
overridevirtual

Reimplemented from yarp::dev::IAxisInfo.

Definition at line 3685 of file ControlBoardWrapper.cpp.

◆ getLastInputStamp()

yarp::os::Stamp ControlBoardWrapper::getLastInputStamp ( )
overridevirtual

Return the time stamp relative to the last acquisition.

Implements yarp::dev::IPreciselyTimed.

Definition at line 4276 of file ControlBoardWrapper.cpp.

◆ getLimits()

bool ControlBoardWrapper::getLimits ( int  j,
double *  min,
double *  max 
)
overridevirtual

Get the software limits for a particular axis.

Parameters
jjoint number
minpointer to store the value of the lower limit
maxpointer to store the value of the upper limit
Returns
true if everything goes fine, false if something bad happens (yes, sometimes life is tough)

Implements yarp::dev::IControlLimits.

Definition at line 3451 of file ControlBoardWrapper.cpp.

◆ getMaxCurrent()

bool ControlBoardWrapper::getMaxCurrent ( int  j,
double *  v 
)
overridevirtual

Returns the maximum electric current allowed for a given motor.

The behavior of the board/amplifier when this limit is reached depends on the implementation.

Parameters
jmotor number
vthe return value
Returns
probably true, might return false in bad times

Implements yarp::dev::IAmplifierControl.

Definition at line 3279 of file ControlBoardWrapper.cpp.

◆ getMotorEncoder()

bool ControlBoardWrapper::getMotorEncoder ( int  m,
double *  v 
)
overridevirtual

Read the value of an encoder.

Parameters
jencoder number
vpointer to storage for the return value
Returns
true/false, upon success/failure (you knew it, uh?)

Implements yarp::dev::IMotorEncoders.

Definition at line 2983 of file ControlBoardWrapper.cpp.

◆ getMotorEncoderAcceleration()

bool ControlBoardWrapper::getMotorEncoderAcceleration ( int  m,
double *  acc 
)
overridevirtual

Read the instantaneous acceleration of an axis.

Parameters
jaxis number
accpointer to the array that will contain the output

Implements yarp::dev::IMotorEncoders.

Definition at line 3097 of file ControlBoardWrapper.cpp.

◆ getMotorEncoderAccelerations()

bool ControlBoardWrapper::getMotorEncoderAccelerations ( double *  accs)
overridevirtual

Read the istantaneous acceleration of all axes.

Parameters
accspointer to the array that will contain the output
Returns
true if all goes well, false if anything bad happens.

Implements yarp::dev::IMotorEncoders.

Definition at line 3113 of file ControlBoardWrapper.cpp.

◆ getMotorEncoderCountsPerRevolution()

bool ControlBoardWrapper::getMotorEncoderCountsPerRevolution ( int  m,
double *  cpr 
)
overridevirtual

gets number of counts per revolution for motor encoder m.

Parameters
mmotor encoder number
cprpointer to storage for the return value
Returns
true/false

Implements yarp::dev::IMotorEncoders.

Definition at line 2967 of file ControlBoardWrapper.cpp.

◆ getMotorEncoders()

bool ControlBoardWrapper::getMotorEncoders ( double *  encs)
overridevirtual

Read the position of all axes.

Parameters
encspointer to the array that will contain the output
Returns
true/false on success/failure

Implements yarp::dev::IMotorEncoders.

Definition at line 2999 of file ControlBoardWrapper.cpp.

◆ getMotorEncoderSpeed()

bool ControlBoardWrapper::getMotorEncoderSpeed ( int  m,
double *  sp 
)
overridevirtual

Read the istantaneous speed of an axis.

Parameters
jaxis number
sppointer to storage for the output
Returns
true if successful, false ... otherwise.

Implements yarp::dev::IMotorEncoders.

Definition at line 3059 of file ControlBoardWrapper.cpp.

◆ getMotorEncoderSpeeds()

bool ControlBoardWrapper::getMotorEncoderSpeeds ( double *  spds)
overridevirtual

Read the instantaneous speed of all axes.

Parameters
spdspointer to storage for the output values
Returns
guess what? (true/false on success or failure).

Implements yarp::dev::IMotorEncoders.

Definition at line 3075 of file ControlBoardWrapper.cpp.

◆ getMotorEncodersTimed()

bool ControlBoardWrapper::getMotorEncodersTimed ( double *  encs,
double *  time 
)
overridevirtual

Read the instantaneous position of all motor encoders.

Parameters
encspointer to the array that will contain the output
timepointer to the array that will contain individual timestamps
Returns
true if successful, false otherwise.

Implements yarp::dev::IMotorEncoders.

Definition at line 3021 of file ControlBoardWrapper.cpp.

◆ getMotorEncoderTimed()

bool ControlBoardWrapper::getMotorEncoderTimed ( int  m,
double *  encs,
double *  time 
)
overridevirtual

Read the instantaneous position of a motor encoder.

Parameters
mmotor index
encsencoder value (pointer to)
timecorresponding timestamp (pointer to)
Returns
true if successful, false otherwise.

Implements yarp::dev::IMotorEncoders.

Definition at line 3043 of file ControlBoardWrapper.cpp.

◆ getMotorTorqueParams()

bool ControlBoardWrapper::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 3849 of file ControlBoardWrapper.cpp.

◆ getNominalCurrent()

bool ControlBoardWrapper::getNominalCurrent ( int  m,
double *  val 
)
overridevirtual

Reimplemented from yarp::dev::IAmplifierControl.

Definition at line 3299 of file ControlBoardWrapper.cpp.

◆ getNumberOfMotorEncoders()

bool ControlBoardWrapper::getNumberOfMotorEncoders ( int *  num)
overridevirtual

Get the number of available motor encoders.

Parameters
mpointer to a value representing the number of available motor encoders.
Returns
true/false

Implements yarp::dev::IMotorEncoders.

Definition at line 3137 of file ControlBoardWrapper.cpp.

◆ getNumberOfMotors()

bool ControlBoardWrapper::getNumberOfMotors ( int *  ax)
overridevirtual

Retrieves the number of controlled axes from the current physical interface.

Parameters
axreturns the number of controlled axes.
Returns
true/false on success/failure

Implements yarp::dev::ICurrentControl.

Definition at line 2706 of file ControlBoardWrapper.cpp.

◆ getPeakCurrent()

bool ControlBoardWrapper::getPeakCurrent ( int  m,
double *  val 
)
overridevirtual

Reimplemented from yarp::dev::IAmplifierControl.

Definition at line 3319 of file ControlBoardWrapper.cpp.

◆ getPid()

bool ControlBoardWrapper::getPid ( const PidControlTypeEnum pidtype,
int  j,
Pid pid 
)
overridevirtual

Get current pid value for a specific joint.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
pidpointer to storage for the return value.
Returns
success/failure

Implements yarp::dev::IPidControl.

Definition at line 1163 of file ControlBoardWrapper.cpp.

◆ getPidError()

bool ControlBoardWrapper::getPidError ( const PidControlTypeEnum pidtype,
int  j,
double *  err 
)
overridevirtual

Get the current error for a joint.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
errpointer to the storage for the return value
Returns
true/false on success failure

Implements yarp::dev::IPidControl.

Definition at line 1067 of file ControlBoardWrapper.cpp.

◆ getPidErrorLimit()

bool ControlBoardWrapper::getPidErrorLimit ( const PidControlTypeEnum pidtype,
int  j,
double *  limit 
)
overridevirtual

Get the error limit for the controller on a specific joint.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
limitpointer to storage
Returns
success/failure

Implements yarp::dev::IPidControl.

Definition at line 1239 of file ControlBoardWrapper.cpp.

◆ getPidErrorLimits()

bool ControlBoardWrapper::getPidErrorLimits ( const PidControlTypeEnum pidtype,
double *  limits 
)
overridevirtual

Get the error limit for all controllers.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
limitspointer to the array that will store the output
Returns
success or failure

Implements yarp::dev::IPidControl.

Definition at line 1254 of file ControlBoardWrapper.cpp.

◆ getPidErrors()

bool ControlBoardWrapper::getPidErrors ( const PidControlTypeEnum pidtype,
double *  errs 
)
overridevirtual

Get the error of all joints.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
errspointer to the vector that will store the errors

Implements yarp::dev::IPidControl.

Definition at line 1084 of file ControlBoardWrapper.cpp.

◆ getPidOutput()

bool ControlBoardWrapper::getPidOutput ( const PidControlTypeEnum pidtype,
int  j,
double *  out 
)
overridevirtual

Get the output of the controller (e.g.

pwm value)

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
outpointer to storage for return value
Returns
success/failure

Implements yarp::dev::IPidControl.

Definition at line 1107 of file ControlBoardWrapper.cpp.

◆ getPidOutputs()

bool ControlBoardWrapper::getPidOutputs ( const PidControlTypeEnum pidtype,
double *  outs 
)
overridevirtual

Get the output of the controllers (e.g.

pwm value)

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
outspinter to the vector that will store the output values

Implements yarp::dev::IPidControl.

Definition at line 1124 of file ControlBoardWrapper.cpp.

◆ getPidReference()

bool ControlBoardWrapper::getPidReference ( const PidControlTypeEnum pidtype,
int  j,
double *  ref 
)
overridevirtual

Get the current reference of the pid controller for a specific joint.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
refpointer to storage for return value
Returns
reference value

Implements yarp::dev::IPidControl.

Definition at line 1203 of file ControlBoardWrapper.cpp.

◆ getPidReferences()

bool ControlBoardWrapper::getPidReferences ( const PidControlTypeEnum pidtype,
double *  refs 
)
overridevirtual

Get the current reference of all pid controllers.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
refsvector that will store the output.

Implements yarp::dev::IPidControl.

Definition at line 1217 of file ControlBoardWrapper.cpp.

◆ getPids()

bool ControlBoardWrapper::getPids ( const PidControlTypeEnum pidtype,
Pid pids 
)
overridevirtual

Get current pid value for a specific joint.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
pidsvector that will store the values of the pids.
Returns
success/failure

Implements yarp::dev::IPidControl.

Definition at line 1180 of file ControlBoardWrapper.cpp.

◆ getPowerSupplyVoltage()

bool ControlBoardWrapper::getPowerSupplyVoltage ( int  m,
double *  val 
)
overridevirtual

Reimplemented from yarp::dev::IAmplifierControl.

Definition at line 3412 of file ControlBoardWrapper.cpp.

◆ getPWM()

bool ControlBoardWrapper::getPWM ( int  m,
double *  val 
)
overridevirtual

Reimplemented from yarp::dev::IAmplifierControl.

Definition at line 3355 of file ControlBoardWrapper.cpp.

◆ getPWMLimit()

bool ControlBoardWrapper::getPWMLimit ( int  m,
double *  val 
)
overridevirtual

Reimplemented from yarp::dev::IAmplifierControl.

Definition at line 3375 of file ControlBoardWrapper.cpp.

◆ getRefAcceleration()

bool ControlBoardWrapper::getRefAcceleration ( int  j,
double *  acc 
)
overridevirtual

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::IPositionControl.

Definition at line 2191 of file ControlBoardWrapper.cpp.

◆ getRefAccelerations() [1/2]

bool ControlBoardWrapper::getRefAccelerations ( double *  accs)
overridevirtual

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::IPositionControl.

Definition at line 2214 of file ControlBoardWrapper.cpp.

◆ getRefAccelerations() [2/2]

bool ControlBoardWrapper::getRefAccelerations ( const int  n_joints,
const int *  joints,
double *  accs 
)
overridevirtual

Get reference acceleration for a joint.

Returns the acceleration used to generate the trajectory profile.

Parameters
jointspointer to the array of joint numbers
accspointer to the array that will store the acceleration values
Returns
true/false on success/failure

Implements yarp::dev::IPositionControl2.

Definition at line 2244 of file ControlBoardWrapper.cpp.

◆ getRefCurrent()

bool ControlBoardWrapper::getRefCurrent ( int  m,
double *  curr 
)
overridevirtual

Get the reference value of the current for a single motor.

Parameters
mmotor number
currthe current reference value for motor m. Value is expressed in amperes.
Returns
true/false on success/failure

Implements yarp::dev::ICurrentControl.

Definition at line 4969 of file ControlBoardWrapper.cpp.

◆ getRefCurrents()

bool ControlBoardWrapper::getRefCurrents ( double *  currs)
overridevirtual

Get the reference value of the currents for all motors.

Parameters
currspointer to the array to be filled with reference current values. Values are expressed in amperes.
Returns
true/false on success/failure

Implements yarp::dev::ICurrentControl.

Definition at line 4946 of file ControlBoardWrapper.cpp.

◆ getRefDutyCycle()

bool ControlBoardWrapper::getRefDutyCycle ( int  m,
double *  ref 
)
overridevirtual

Gets the last reference sent using the setRefDutyCycle function.

Parameters
mmotor number
refpointer to storage for return value, expressed as percentage (-100% +100%)
Returns
true/false on success/failure

Implements yarp::dev::IPWMControl.

Definition at line 4742 of file ControlBoardWrapper.cpp.

◆ getRefDutyCycles()

bool ControlBoardWrapper::getRefDutyCycles ( double *  refs)
overridevirtual

Gets the last reference sent using the setRefDutyCycles function.

Parameters
refspointer to the vector that will store the values, expressed as percentage (-100% +100%)
Returns
true/false on success/failure

Implements yarp::dev::IPWMControl.

Definition at line 4759 of file ControlBoardWrapper.cpp.

◆ getRefPosition()

bool ControlBoardWrapper::getRefPosition ( const int  joint,
double *  ref 
)
overridevirtual

Get the last position reference for the specified axis.

This is the dual of setPositions and shall return only values sent using IPositionDirect interface. If other interfaces like IPositionControl are implemented by the device, this call must ignore their values, i.e. this call must never return a reference sent using IPositionControl::PositionMove.

Parameters
reflast reference sent using setPosition(s) functions
Returns
true/false on success/failure

Reimplemented from yarp::dev::IPositionDirect.

Definition at line 4283 of file ControlBoardWrapper.cpp.

◆ getRefPositions() [1/2]

bool ControlBoardWrapper::getRefPositions ( double *  refs)
overridevirtual

Get the last position reference for all axes.

This is the dual of setPositions and shall return only values sent using IPositionDirect interface. If other interfaces like IPositionControl are implemented by the device, this call must ignore their values, i.e. this call must never return a reference sent using IPositionControl::PositionMove.

Parameters
refarray containing last reference sent using setPosition(s) functions
Returns
true/false on success/failure

Reimplemented from yarp::dev::IPositionDirect.

Definition at line 4302 of file ControlBoardWrapper.cpp.

◆ getRefPositions() [2/2]

bool ControlBoardWrapper::getRefPositions ( const int  n_joint,
const int *  joints,
double *  refs 
)
overridevirtual

Get the last position reference for the specified group of axes.

This is the dual of setPositions and shall return only values sent using IPositionDirect interface. If other interfaces like IPositionControl are implemented by the device, this call must ignore their values, i.e. this call must never return a reference sent using IPositionControl::PositionMove.

Parameters
refarray containing last reference sent using setPosition(s) functions
Returns
true/false on success/failure

Reimplemented from yarp::dev::IPositionDirect.

Definition at line 4326 of file ControlBoardWrapper.cpp.

◆ getRefSpeed()

bool ControlBoardWrapper::getRefSpeed ( int  j,
double *  ref 
)
overridevirtual

Get reference speed for a joint.

Returns the speed used to generate the trajectory profile.

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

Implements yarp::dev::IPositionControl.

Definition at line 2065 of file ControlBoardWrapper.cpp.

◆ getRefSpeeds() [1/2]

bool ControlBoardWrapper::getRefSpeeds ( double *  spds)
overridevirtual

Get reference speed of all joints.

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

Parameters
spdspointer to the array that will store the speed values.
Returns
true/false on success/failure.

Implements yarp::dev::IPositionControl.

Definition at line 2088 of file ControlBoardWrapper.cpp.

◆ getRefSpeeds() [2/2]

bool ControlBoardWrapper::getRefSpeeds ( const int  n_joints,
const int *  joints,
double *  spds 
)
overridevirtual

Get reference speed of all joints.

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

Parameters
jointspointer to the array of joint numbers
spdspointer to the array that will store the speed values.
Returns
true/false upon success/failure

Implements yarp::dev::IPositionControl2.

Definition at line 2118 of file ControlBoardWrapper.cpp.

◆ getRefTorque()

bool ControlBoardWrapper::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 3724 of file ControlBoardWrapper.cpp.

◆ getRefTorques()

bool ControlBoardWrapper::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 3701 of file ControlBoardWrapper.cpp.

◆ getRefVelocities() [1/2]

bool ControlBoardWrapper::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::IVelocityControl2.

Definition at line 4451 of file ControlBoardWrapper.cpp.

◆ getRefVelocities() [2/2]

bool ControlBoardWrapper::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::IVelocityControl2.

Definition at line 4478 of file ControlBoardWrapper.cpp.

◆ getRefVelocity()

bool ControlBoardWrapper::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::IVelocityControl2.

Definition at line 4428 of file ControlBoardWrapper.cpp.

◆ getRemoteVariable()

bool ControlBoardWrapper::getRemoteVariable ( yarp::os::ConstString  key,
yarp::os::Bottle val 
)
overridevirtual

Implements yarp::dev::IRemoteVariables.

Definition at line 2812 of file ControlBoardWrapper.cpp.

◆ getRemoteVariablesList()

bool ControlBoardWrapper::getRemoteVariablesList ( yarp::os::Bottle listOfKeys)
overridevirtual

Implements yarp::dev::IRemoteVariables.

Definition at line 2860 of file ControlBoardWrapper.cpp.

◆ getTargetPosition()

bool ControlBoardWrapper::getTargetPosition ( const int  joint,
double *  ref 
)
overridevirtual

Get the last position reference for the specified axis.

This is the dual of PositionMove and shall return only values sent using IPositionControl interface. If other interfaces like IPositionDirect are implemented by the device, this call must ignore their values, i.e. this call must never return a reference sent using IPositionDirect::SetPosition

Parameters
reflast reference sent using PositionMove functions
Returns
true/false on success/failure

Reimplemented from yarp::dev::IPositionControl2.

Definition at line 1484 of file ControlBoardWrapper.cpp.

◆ getTargetPositions() [1/2]

bool ControlBoardWrapper::getTargetPositions ( double *  spds)
overridevirtual

Get the last position reference for all axes.

Get reference speed of all joints.

This is the dual of PositionMove and shall return only values sent using IPositionControl interface. If other interfaces like IPositionDirect are implemented by the device, this call must ignore their values, i.e. this call must never return a reference sent using IPositionDirect::SetPosition

Parameters
reflast reference sent using PositionMove functions
Returns
true/false on success/failure

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

Parameters
spdspointer to the array that will store the speed values.
Returns
true/false on success/failure.

Reimplemented from yarp::dev::IPositionControl2.

Definition at line 1509 of file ControlBoardWrapper.cpp.

◆ getTargetPositions() [2/2]

bool ControlBoardWrapper::getTargetPositions ( const int  n_joint,
const int *  joints,
double *  refs 
)
overridevirtual

Get the last position reference for the specified group of axes.

This is the dual of PositionMove and shall return only values sent using IPositionControl interface. If other interfaces like IPositionDirect are implemented by the device, this call must ignore their values, i.e. this call must never return a reference sent using IPositionDirect::SetPosition

Parameters
reflast reference sent using PositionMove functions
Returns
true/false on success/failure

Reimplemented from yarp::dev::IPositionControl2.

Definition at line 1533 of file ControlBoardWrapper.cpp.

◆ getTemperature()

bool ControlBoardWrapper::getTemperature ( int  m,
double *  val 
)
overridevirtual

Get temperature of a motor.

Parameters
mmotor number
valretrieved motor temperature
Returns
true/false

Implements yarp::dev::IMotor.

Definition at line 2711 of file ControlBoardWrapper.cpp.

◆ getTemperatureLimit()

bool ControlBoardWrapper::getTemperatureLimit ( int  m,
double *  temp 
)
overridevirtual

Retreives the current temperature limit for a specific motor.

The specific behavior of the motor when the temperature limit is exceeded depends on the implementation (power off recommeneded)

Parameters
mmotor number
tempthe current temperature limit.
Returns
true/false

Implements yarp::dev::IMotor.

Definition at line 2749 of file ControlBoardWrapper.cpp.

◆ getTemperatures()

bool ControlBoardWrapper::getTemperatures ( double *  vals)
overridevirtual

Get temperature of all the motors.

Parameters
valspointer to an array containing all motor temperatures
Returns
true/false

Implements yarp::dev::IMotor.

Definition at line 2727 of file ControlBoardWrapper.cpp.

◆ getTorque()

bool ControlBoardWrapper::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 3915 of file ControlBoardWrapper.cpp.

◆ getTorqueRange()

bool ControlBoardWrapper::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 3955 of file ControlBoardWrapper.cpp.

◆ getTorqueRanges()

bool ControlBoardWrapper::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 3972 of file ControlBoardWrapper.cpp.

◆ getTorques()

bool ControlBoardWrapper::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 3932 of file ControlBoardWrapper.cpp.

◆ getVelLimits()

bool ControlBoardWrapper::getVelLimits ( int  j,
double *  min,
double *  max 
)
overridevirtual

Get the software velocity limits for a particular axis.

Parameters
jjoint number
minpointer to store the value of the lower limit
maxpointer to store the value of the upper limit
Returns
true if everything goes fine, false if something bad happens

Implements yarp::dev::IControlLimits2.

Definition at line 3489 of file ControlBoardWrapper.cpp.

◆ homingSingleJoint()

bool ControlBoardWrapper::homingSingleJoint ( int  j)
overridevirtual

homingSingleJoint: call the homing procedure for a single joint

Parameters
jjoint to be calibrated
Returns
true if homing was succesful, false otherwise

Implements yarp::dev::IRemoteCalibrator.

Definition at line 3540 of file ControlBoardWrapper.cpp.

◆ homingWholePart()

bool ControlBoardWrapper::homingWholePart ( )
overridevirtual

homingWholePart: call the homing procedure for a the whole part/device

Returns
true if homing was succesful, false otherwise

Implements yarp::dev::IRemoteCalibrator.

Definition at line 3549 of file ControlBoardWrapper.cpp.

◆ isCalibratorDevicePresent()

bool ControlBoardWrapper::isCalibratorDevicePresent ( bool *  isCalib)
overridevirtual

isCalibratorDevicePresent: check if a calibrator device has been set

Returns
true if a valid calibrator device has been found

Reimplemented from yarp::dev::IRemoteCalibrator.

Definition at line 3517 of file ControlBoardWrapper.cpp.

◆ isPidEnabled()

bool ControlBoardWrapper::isPidEnabled ( const PidControlTypeEnum pidtype,
int  j,
bool *  enabled 
)
overridevirtual

Get the current status (enabled/disabled) of the pid.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
enabledthe current status of the pid controller.
Returns
true on success, false on failure.

Implements yarp::dev::IPidControl.

Definition at line 1321 of file ControlBoardWrapper.cpp.

◆ open() [1/2]

virtual bool yarp::dev::ControlBoardWrapper::open ( )
inlinevirtual

Default open() method.

Returns
always false since initialization requires parameters.

Definition at line 374 of file ControlBoardWrapper.h.

◆ open() [2/2]

bool ControlBoardWrapper::open ( yarp::os::Searchable prop)
overridevirtual

Open the device driver.

Parameters
propis a Searchable object which contains the parameters. Allowed parameters are:
  • verbose or v to print diagnostic information while running..
  • name to specify the prefix of the port names.
  • subdevice [optional] if specified, the openAndAttachSubDevice will be called, otherwise openDeferredAttach is called. and all parameters required by the wrapper.

Reimplemented from yarp::dev::DeviceDriver.

Definition at line 390 of file ControlBoardWrapper.cpp.

◆ parkSingleJoint()

bool ControlBoardWrapper::parkSingleJoint ( int  j,
bool  _wait = true 
)
overridevirtual

parkSingleJoint(): start the parking procedure for the single joint

Returns
true if succesful

Implements yarp::dev::IRemoteCalibrator.

Definition at line 3558 of file ControlBoardWrapper.cpp.

◆ parkWholePart()

bool ControlBoardWrapper::parkWholePart ( )
overridevirtual

parkWholePart: start the parking procedure for the whole part

Returns
true if succesful

Implements yarp::dev::IRemoteCalibrator.

Definition at line 3567 of file ControlBoardWrapper.cpp.

◆ positionMove() [1/3]

bool ControlBoardWrapper::positionMove ( int  j,
double  ref 
)
overridevirtual

Set new reference point for a single axis.

Parameters
jjoint number
refspecifies the new ref point
Returns
true/false on success/failure

Implements yarp::dev::IPositionControl.

Definition at line 1358 of file ControlBoardWrapper.cpp.

◆ positionMove() [2/3]

bool ControlBoardWrapper::positionMove ( const double *  refs)
overridevirtual

Set new reference point for all axes.

Parameters
refsarray, new reference points.
Returns
true/false on success/failure

Implements yarp::dev::IPositionControl.

Definition at line 1378 of file ControlBoardWrapper.cpp.

◆ positionMove() [3/3]

bool ControlBoardWrapper::positionMove ( const int  n_joints,
const int *  joints,
const double *  refs 
)
overridevirtual

Set new reference point for a subset of axis.

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

Implements yarp::dev::IPositionControl2.

Definition at line 1438 of file ControlBoardWrapper.cpp.

◆ quitCalibrate()

bool ControlBoardWrapper::quitCalibrate ( )
overridevirtual

quitCalibrate: interrupt the calibration procedure

Returns
true if succesful

Implements yarp::dev::IRemoteCalibrator.

Definition at line 3576 of file ControlBoardWrapper.cpp.

◆ quitPark()

bool ControlBoardWrapper::quitPark ( )
overridevirtual

quitPark: interrupt the park procedure

Returns
true if succesful

Implements yarp::dev::IRemoteCalibrator.

Definition at line 3585 of file ControlBoardWrapper.cpp.

◆ relativeMove() [1/3]

bool ControlBoardWrapper::relativeMove ( int  j,
double  delta 
)
overridevirtual

Set relative position.

The command is relative to the current position of the axis.

Parameters
jjoint axis number
deltarelative command
Returns
true/false on success/failure

Implements yarp::dev::IPositionControl.

Definition at line 1591 of file ControlBoardWrapper.cpp.

◆ relativeMove() [2/3]

bool ControlBoardWrapper::relativeMove ( const double *  deltas)
overridevirtual

Set relative position, all joints.

Parameters
deltaspointer to the relative commands
Returns
true/false on success/failure

Implements yarp::dev::IPositionControl.

Definition at line 1611 of file ControlBoardWrapper.cpp.

◆ relativeMove() [3/3]

bool ControlBoardWrapper::relativeMove ( const int  n_joints,
const int *  joints,
const double *  deltas 
)
overridevirtual

Set relative position for a subset of joints.

Parameters
jointspointer to the array of joint numbers
deltaspointer to the array of relative commands
Returns
true/false on success/failure

Implements yarp::dev::IPositionControl2.

Definition at line 1638 of file ControlBoardWrapper.cpp.

◆ resetEncoder()

bool ControlBoardWrapper::resetEncoder ( int  j)
overridevirtual

Reset encoder, single joint.

Set the encoder value to zero

Parameters
jis the axis number
Returns
true/false on success/failure

Implements yarp::dev::IEncoders.

Definition at line 2478 of file ControlBoardWrapper.cpp.

◆ resetEncoders()

bool ControlBoardWrapper::resetEncoders ( )
overridevirtual

Reset encoders.

Set the encoder values to zero for all axes

Returns
true/false

Implements yarp::dev::IEncoders.

Definition at line 2493 of file ControlBoardWrapper.cpp.

◆ resetMotorEncoder()

bool ControlBoardWrapper::resetMotorEncoder ( int  m)
overridevirtual

Reset encoder, single joint.

Set the encoder value to zero

Parameters
jis the axis number
Returns
true/false on success/failure

Implements yarp::dev::IMotorEncoders.

Definition at line 2878 of file ControlBoardWrapper.cpp.

◆ resetMotorEncoders()

bool ControlBoardWrapper::resetMotorEncoders ( )
overridevirtual

Reset encoders.

Set the encoder values to zero for all axes

Returns
true/false

Implements yarp::dev::IMotorEncoders.

Definition at line 2893 of file ControlBoardWrapper.cpp.

◆ resetPid()

bool ControlBoardWrapper::resetPid ( const PidControlTypeEnum pidtype,
int  j 
)
overridevirtual

Reset the controller of a given joint, usually sets the current status of the joint as the reference value for the PID, and resets the integrator.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
Returns
true on success, false on failure.

Implements yarp::dev::IPidControl.

Definition at line 1276 of file ControlBoardWrapper.cpp.

◆ run()

void ControlBoardWrapper::run ( void  )
overridevirtual

The thread main loop deals with writing on ports here.

Implements yarp::os::RateThread.

Definition at line 835 of file ControlBoardWrapper.cpp.

◆ setBemfParam()

bool ControlBoardWrapper::setBemfParam ( int  j,
double  bemf 
)
overridevirtual

Set the back-emf compensation gain for a given joint.

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

Implements yarp::dev::ITorqueControl.

Definition at line 3833 of file ControlBoardWrapper.cpp.

◆ setCalibrationParameters()

bool ControlBoardWrapper::setCalibrationParameters ( int  j,
const CalibrationParameters params 
)
overridevirtual

Reimplemented from yarp::dev::IControlCalibration2.

Definition at line 3626 of file ControlBoardWrapper.cpp.

◆ setControlMode()

bool ControlBoardWrapper::setControlMode ( const int  j,
const int  mode 
)
overridevirtual

Set the current control mode.

Parameters
jjoint number
modea vocab of the desired control mode for joint j.
Returns
true if the new controlMode was successfully set, false if the message was not received or the joint was unable to switch to the desired controlMode (e.g. the joint is on a fault condition or the desired mode is not implemented).

Implements yarp::dev::IControlMode2.

Definition at line 4108 of file ControlBoardWrapper.cpp.

◆ setControlModes() [1/2]

bool ControlBoardWrapper::setControlModes ( const int  n_joint,
const int *  joints,
int *  modes 
)
overridevirtual

Set the current control mode for a subset of axes.

Parameters
n_jointshow many joints this command is referring to
jointslist of joint numbers, the size of this array is n_joints
modesarray containing the new controlmodes, one value for each joint, the size is n_joints. The first value will be the new reference fot the joint joints[0]. for example: n_joint 3 joints 0 2 4 modes VOCAB_CM_POSITION VOCAB_CM_VELOCITY VOCAB_CM_POSITION
Returns
true if the new controlMode was successfully set, false if the message was not received or the joint was unable to switch to the desired controlMode (e.g. the joint is on a fault condition or the desired mode is not implemented).

Implements yarp::dev::IControlMode2.

Definition at line 4125 of file ControlBoardWrapper.cpp.

◆ setControlModes() [2/2]

bool ControlBoardWrapper::setControlModes ( int *  modes)
overridevirtual

Set the current control mode (multiple joints).

Parameters
modesa vector containing vocabs for the desired control modes of the joints.
Returns
true if the new controlMode was successfully set, false if the message was not received or the joint was unable to switch to the desired controlMode (e.g. the joint is on a fault condition or the desired mode is not implemented).

Implements yarp::dev::IControlMode2.

Definition at line 4160 of file ControlBoardWrapper.cpp.

◆ setEncoder()

bool ControlBoardWrapper::setEncoder ( int  j,
double  val 
)
overridevirtual

Set the value of the encoder for a given joint.

Parameters
jencoder number
valnew value
Returns
true/false

Implements yarp::dev::IEncoders.

Definition at line 2515 of file ControlBoardWrapper.cpp.

◆ setEncoders()

bool ControlBoardWrapper::setEncoders ( const double *  vals)
overridevirtual

Set the value of all encoders.

Parameters
valspointer to the new values
Returns
true/false

Implements yarp::dev::IEncoders.

Definition at line 2530 of file ControlBoardWrapper.cpp.

◆ setGearboxRatio()

bool ControlBoardWrapper::setGearboxRatio ( int  m,
const double  val 
)
overridevirtual

Set the gearbox ratio for a specific motor.

Parameters
mmotor number
gearboxratio to be set
Returns
true/false

Reimplemented from yarp::dev::IMotor.

Definition at line 2796 of file ControlBoardWrapper.cpp.

◆ setImpedance()

bool ControlBoardWrapper::setImpedance ( int  j,
double  stiffness,
double  damping 
)
overridevirtual

Set current impedance gains (stiffness,damping) for a specific joint.

Returns
success/failure

Implements yarp::dev::IImpedanceControl.

Definition at line 3881 of file ControlBoardWrapper.cpp.

◆ setImpedanceOffset()

bool ControlBoardWrapper::setImpedanceOffset ( int  j,
double  offset 
)
overridevirtual

Set current force Offset for a specific joint.

Returns
success/failure

Implements yarp::dev::IImpedanceControl.

Definition at line 3898 of file ControlBoardWrapper.cpp.

◆ setInteractionMode()

bool ControlBoardWrapper::setInteractionMode ( int  axis,
yarp::dev::InteractionModeEnum  mode 
)
overridevirtual

Set the interaction mode of the robot, values can be stiff or compliant.

Please note that some robot may not implement certain types of interaction, so always check the return value.

Parameters
axisjoint number
modethe desired interaction mode
Returns
true or false on success or failure.

Implements yarp::dev::IInteractionMode.

Definition at line 4628 of file ControlBoardWrapper.cpp.

◆ setInteractionModes() [1/2]

bool ControlBoardWrapper::setInteractionModes ( int  n_joints,
int *  joints,
yarp::dev::InteractionModeEnum modes 
)
overridevirtual

Set the interaction mode of the robot for a set of joints, values can be stiff or compliant.

Please note that some robot may not implement certain types of interaction, so always check the return value.

Parameters
n_jointshow many joints this command is referring to
jointslist of joints controlled. The size of this array is n_joints
modesarray containing the desired interaction mode, one value for each joint, the size is n_joints. for example: n_joint 3 joints 0 2 4 refs VOCAB_IM_STIFF VOCAB_IM_STIFF VOCAB_IM_COMPLIANT
Returns
true or false on success or failure. If one or more joint fails, the return value will be false.

Implements yarp::dev::IInteractionMode.

Definition at line 4644 of file ControlBoardWrapper.cpp.

◆ setInteractionModes() [2/2]

bool ControlBoardWrapper::setInteractionModes ( yarp::dev::InteractionModeEnum modes)
overridevirtual

Set the interaction mode of the robot for a all the joints, values can be stiff or compliant.

Some robot may not implement some types of interaction, so always check the return value

Parameters
modearray with the desired interaction mode for all joints, length is the total number of joints for the part
Returns
true or false on success or failure. If one or more joint fails, the return value will be false.

Implements yarp::dev::IInteractionMode.

Definition at line 4679 of file ControlBoardWrapper.cpp.

◆ setLimits()

bool ControlBoardWrapper::setLimits ( int  j,
double  min,
double  max 
)
overridevirtual

Set the software limits for a particular axis, the behavior of the control card when these limits are exceeded, depends on the implementation.

Parameters
jjoint number (why am I telling you this)
minthe value of the lower limit
maxthe value of the upper limit
Returns
true or false on success or failure

Implements yarp::dev::IControlLimits.

Definition at line 3435 of file ControlBoardWrapper.cpp.

◆ setMaxCurrent()

bool ControlBoardWrapper::setMaxCurrent ( int  j,
double  v 
)
overridevirtual

Set the maximum electric current going to a given motor.

The behavior of the board/amplifier when this limit is reached depends on the implementation.

Parameters
jmotor number
vthe new value
Returns
probably true, might return false in bad times

Implements yarp::dev::IAmplifierControl.

Definition at line 3263 of file ControlBoardWrapper.cpp.

◆ setMotorEncoder()

bool ControlBoardWrapper::setMotorEncoder ( int  m,
const double  val 
)
overridevirtual

Set the value of the encoder for a given joint.

Parameters
jencoder number
valnew value
Returns
true/false

Implements yarp::dev::IMotorEncoders.

Definition at line 2915 of file ControlBoardWrapper.cpp.

◆ setMotorEncoderCountsPerRevolution()

bool ControlBoardWrapper::setMotorEncoderCountsPerRevolution ( int  m,
const double  cpr 
)
overridevirtual

Sets number of counts per revolution for motor encoder m.

Parameters
mmotor encoder number
cprnew parameter
Returns
true/false

Implements yarp::dev::IMotorEncoders.

Definition at line 2952 of file ControlBoardWrapper.cpp.

◆ setMotorEncoders()

bool ControlBoardWrapper::setMotorEncoders ( const double *  vals)
overridevirtual

Set the value of all encoders.

Parameters
valspointer to the new values
Returns
true/false

Implements yarp::dev::IMotorEncoders.

Definition at line 2930 of file ControlBoardWrapper.cpp.

◆ setMotorTorqueParams()

bool ControlBoardWrapper::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 3865 of file ControlBoardWrapper.cpp.

◆ setPeakCurrent()

bool ControlBoardWrapper::setPeakCurrent ( int  m,
const double  val 
)
overridevirtual

Reimplemented from yarp::dev::IAmplifierControl.

Definition at line 3339 of file ControlBoardWrapper.cpp.

◆ setPid()

bool ControlBoardWrapper::setPid ( const PidControlTypeEnum pidtype,
int  j,
const Pid pid 
)
overridevirtual

Set new pid value for a joint axis.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
pidnew pid value
Returns
true/false on success/failure

Implements yarp::dev::IPidControl.

Definition at line 950 of file ControlBoardWrapper.cpp.

◆ setPidErrorLimit()

bool ControlBoardWrapper::setPidErrorLimit ( const PidControlTypeEnum pidtype,
int  j,
double  limit 
)
overridevirtual

Set the error limit for the controller on a specifi joint.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
limitlimit value
Returns
true/false on success/failure

Implements yarp::dev::IPidControl.

Definition at line 1028 of file ControlBoardWrapper.cpp.

◆ setPidErrorLimits()

bool ControlBoardWrapper::setPidErrorLimits ( const PidControlTypeEnum pidtype,
const double *  limits 
)
overridevirtual

Get the error limit for the controller on all joints.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
limitspointer to the vector with the new limits
Returns
true/false on success/failure

Implements yarp::dev::IPidControl.

Definition at line 1044 of file ControlBoardWrapper.cpp.

◆ setPidOffset()

bool ControlBoardWrapper::setPidOffset ( const PidControlTypeEnum pidtype,
int  j,
double  v 
)
overridevirtual

Set offset value for a given controller.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
vthe offset to be added to the output of the pid controller
Returns
true on success, false on failure.

Implements yarp::dev::IPidControl.

Definition at line 1147 of file ControlBoardWrapper.cpp.

◆ setPidReference()

bool ControlBoardWrapper::setPidReference ( const PidControlTypeEnum pidtype,
int  j,
double  ref 
)
overridevirtual

Set the controller reference for a given axis.

Warning this method can result in very large torques and should be used carefully. If you do not understand this warning you should avoid using this method. Have a look at other interfaces (e.g. position control).

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
jjoint number
refnew reference point
Returns
true/false upon success/failure

Implements yarp::dev::IPidControl.

Definition at line 989 of file ControlBoardWrapper.cpp.

◆ setPidReferences()

bool ControlBoardWrapper::setPidReferences ( const PidControlTypeEnum pidtype,
const double *  refs 
)
overridevirtual

Set the controller reference, multiple axes.

Warning this method can result in very large torques and should be used carefully. If you do not understand this warning you should avoid using this method. Have a look at other interfaces (e.g. position control).

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
refspointer to the vector that contains the new reference points.
Returns
true/false upon success/failure

Implements yarp::dev::IPidControl.

Definition at line 1005 of file ControlBoardWrapper.cpp.

◆ setPids()

bool ControlBoardWrapper::setPids ( const PidControlTypeEnum pidtype,
const Pid pids 
)
overridevirtual

Set new pid value on multiple axes.

Parameters
pidtypethe id of the pid that will be affected by the command (e.g. position, velocity etc)
pidspointer to a vector of pids
Returns
true/false upon success/failure

Implements yarp::dev::IPidControl.

Definition at line 966 of file ControlBoardWrapper.cpp.

◆ setPosition()

bool ControlBoardWrapper::setPosition ( int  j,
double  ref 
)
overridevirtual

Set new position for a single axis.

Parameters
jjoint number
refspecifies the new ref point
Returns
true/false on success/failure

Implements yarp::dev::IPositionDirect.

Definition at line 4199 of file ControlBoardWrapper.cpp.

◆ setPositions() [1/2]

bool ControlBoardWrapper::setPositions ( const int  n_joint,
const int *  joints,
double *  refs 
)
overridevirtual

Set new reference point for all axes.

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

Implements yarp::dev::IPositionDirect.

Definition at line 4216 of file ControlBoardWrapper.cpp.

◆ setPositions() [2/2]

bool ControlBoardWrapper::setPositions ( const double *  refs)
overridevirtual

Set new position for a set of axis.

Parameters
refsspecifies the new reference points
Returns
true/false on success/failure

Implements yarp::dev::IPositionDirect.

Definition at line 4253 of file ControlBoardWrapper.cpp.

◆ setPWMLimit()

bool ControlBoardWrapper::setPWMLimit ( int  m,
const double  val 
)
overridevirtual

Reimplemented from yarp::dev::IAmplifierControl.

Definition at line 3396 of file ControlBoardWrapper.cpp.

◆ setRefAcceleration()

bool ControlBoardWrapper::setRefAcceleration ( int  j,
double  acc 
)
overridevirtual

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::IPositionControl.

Definition at line 1933 of file ControlBoardWrapper.cpp.

◆ setRefAccelerations() [1/2]

bool ControlBoardWrapper::setRefAccelerations ( const double *  accs)
overridevirtual

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::IPositionControl.

Definition at line 1954 of file ControlBoardWrapper.cpp.

◆ setRefAccelerations() [2/2]

bool ControlBoardWrapper::setRefAccelerations ( const int  n_joints,
const int *  joints,
const double *  accs 
)
overridevirtual

Set reference acceleration on all joints.

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

Parameters
jointspointer to the array of joint numbers
accspointer to the array with acceleration values
Returns
true/false upon success/failure

Implements yarp::dev::IPositionControl2.

Definition at line 2011 of file ControlBoardWrapper.cpp.

◆ setRefCurrent()

bool ControlBoardWrapper::setRefCurrent ( int  m,
double  curr 
)
overridevirtual

Set the reference value of the current for a single motor.

Parameters
mmotor number
currthe current reference value for motor m. Value is expressed in amperes.
Returns
true/false on success/failure

Implements yarp::dev::ICurrentControl.

Definition at line 4894 of file ControlBoardWrapper.cpp.

◆ setRefCurrents() [1/2]

bool ControlBoardWrapper::setRefCurrents ( const double *  currs)
overridevirtual

Set the reference value of the currents for all motors.

Parameters
currsthe array containing the reference current values. Values are expressed in amperes.
Returns
true/false on success/failure

Implements yarp::dev::ICurrentControl.

Definition at line 4871 of file ControlBoardWrapper.cpp.

◆ setRefCurrents() [2/2]

bool ControlBoardWrapper::setRefCurrents ( const int  n_motor,
const int *  motors,
const double *  currs 
)
overridevirtual

Set the reference value of the current for a group of motors.

Parameters
n_motorsize of motors ans currs arrays
motorspointer to the array containing the list of motor numbers
currspointer to the array specifing the new current references
Returns
true/false on success/failure

Implements yarp::dev::ICurrentControl.

Definition at line 4911 of file ControlBoardWrapper.cpp.

◆ setRefDutyCycle()

bool ControlBoardWrapper::setRefDutyCycle ( int  m,
double  ref 
)
overridevirtual

Sets the reference dutycycle to a single motor.

Parameters
mmotor number
refthe dutycycle, expressed as percentage (-100% +100%)
Returns
true/false on success/failure

Implements yarp::dev::IPWMControl.

Definition at line 4702 of file ControlBoardWrapper.cpp.

◆ setRefDutyCycles()

bool ControlBoardWrapper::setRefDutyCycles ( const double *  refs)
overridevirtual

Sets the reference dutycycle for all the motors.

Parameters
refsthe dutycycle, expressed as percentage (-100% +100%)
Returns
true/false on success/failure

Implements yarp::dev::IPWMControl.

Definition at line 4719 of file ControlBoardWrapper.cpp.

◆ setRefSpeed()

bool ControlBoardWrapper::setRefSpeed ( int  j,
double  sp 
)
overridevirtual

Set reference speed for a joint, this is the speed used during the interpolation of the trajectory.

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

Implements yarp::dev::IPositionControl.

Definition at line 1803 of file ControlBoardWrapper.cpp.

◆ setRefSpeeds() [1/2]

bool ControlBoardWrapper::setRefSpeeds ( const double *  spds)
overridevirtual

Set reference speed on all joints.

These values are used during the interpolation of the trajectory.

Parameters
spdspointer to the array of speed values.
Returns
true/false upon success/failure

Implements yarp::dev::IPositionControl.

Definition at line 1823 of file ControlBoardWrapper.cpp.

◆ setRefSpeeds() [2/2]

bool ControlBoardWrapper::setRefSpeeds ( const int  n_joints,
const int *  joints,
const double *  spds 
)
overridevirtual

Set reference speed on all joints.

These values are used during the interpolation of the trajectory.

Parameters
jointspointer to the array of joint numbers
spdspointer to the array with speed values.
Returns
true/false upon success/failure

Implements yarp::dev::IPositionControl2.

Definition at line 1880 of file ControlBoardWrapper.cpp.

◆ setRefTorque()

bool ControlBoardWrapper::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 3764 of file ControlBoardWrapper.cpp.

◆ setRefTorques() [1/2]

bool ControlBoardWrapper::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 3741 of file ControlBoardWrapper.cpp.

◆ setRefTorques() [2/2]

bool ControlBoardWrapper::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 specifing the new torque reference
Returns
true/false on success/failure

Reimplemented from yarp::dev::ITorqueControl.

Definition at line 3780 of file ControlBoardWrapper.cpp.

◆ setRemoteVariable()

bool ControlBoardWrapper::setRemoteVariable ( yarp::os::ConstString  key,
const yarp::os::Bottle val 
)
overridevirtual

Implements yarp::dev::IRemoteVariables.

Definition at line 2829 of file ControlBoardWrapper.cpp.

◆ setTemperatureLimit()

bool ControlBoardWrapper::setTemperatureLimit ( int  m,
const double  temp 
)
overridevirtual

Set the temperature limit for a specific motor.

The specific behavior of the motor when the temperature limit is exceeded depends on the implementation (power off recommeneded)

Parameters
mmotor number
tempthe temperature limit to be set
Returns
true/false

Implements yarp::dev::IMotor.

Definition at line 2765 of file ControlBoardWrapper.cpp.

◆ setVelLimits()

bool ControlBoardWrapper::setVelLimits ( int  j,
double  min,
double  max 
)
overridevirtual

Set the software velocity limits for a particular axis, the behavior of the control card when these limits are exceeded, depends on the implementation.

Parameters
jjoint number
minthe value of the lower limit
maxthe value of the upper limit
Returns
true or false on success or failure

Implements yarp::dev::IControlLimits2.

Definition at line 3473 of file ControlBoardWrapper.cpp.

◆ stop() [1/3]

bool ControlBoardWrapper::stop ( int  j)
overridevirtual

Stop motion, single joint.

Parameters
jjoint number
Returns
true/false on success/failure

Implements yarp::dev::IPositionControl.

Definition at line 2315 of file ControlBoardWrapper.cpp.

◆ stop() [2/3]

bool ControlBoardWrapper::stop ( )
overridevirtual

Stop motion, multiple joints.

Returns
true/false on success/failure

Implements yarp::dev::IPositionControl.

Definition at line 2336 of file ControlBoardWrapper.cpp.

◆ stop() [3/3]

bool ControlBoardWrapper::stop ( const int  n_joints,
const int *  joints 
)
overridevirtual

Stop motion for subset of joints.

Parameters
jointspointer to the array of joint numbers
Returns
true/false on success/failure

Implements yarp::dev::IPositionControl2.

Definition at line 2364 of file ControlBoardWrapper.cpp.

◆ velocityMove() [1/3]

bool ControlBoardWrapper::velocityMove ( int  j,
double  v 
)
overridevirtual

Set new reference speed for a single axis.

Parameters
jjoint number
vspecifies the new ref speed
Returns
true/false on success/failure

Implements yarp::dev::IVelocityControl.

Definition at line 2410 of file ControlBoardWrapper.cpp.

◆ velocityMove() [2/3]

bool ControlBoardWrapper::velocityMove ( const double *  v)
overridevirtual

Set a new reference speed for all axes.

Parameters
vis a vector of double representing the requested speed.
Returns
true/false on success/failure.

Implements yarp::dev::IVelocityControl.

Definition at line 2426 of file ControlBoardWrapper.cpp.

◆ velocityMove() [3/3]

bool ControlBoardWrapper::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 fot 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::IVelocityControl2.

Definition at line 4382 of file ControlBoardWrapper.cpp.

◆ verbose()

bool yarp::dev::ControlBoardWrapper::verbose ( ) const
inline

Return the value of the verbose flag.

Returns
the verbose flag.

Definition at line 365 of file ControlBoardWrapper.h.


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