YARP
Yet Another Robot Platform
 
Loading...
Searching...
No Matches
yarp::dev::StubImplEncodersRaw Class Reference

Stub implementation of IEncodersRaw interface. More...

#include <yarp/dev/ImplementControlBoardInterfaces.h>

+ Inheritance diagram for yarp::dev::StubImplEncodersRaw:

Public Member Functions

virtual ~StubImplEncodersRaw ()
 
bool getAxes (int *ax) override
 Get the number of controlled axes.
 
bool resetEncoderRaw (int j) override
 Reset encoder, single joint.
 
bool resetEncodersRaw () override
 Reset encoders.
 
bool setEncoderRaw (int j, double val) override
 Set the value of the encoder for a given joint.
 
bool setEncodersRaw (const double *vals) override
 Set the value of all encoders.
 
bool getEncoderRaw (int j, double *v) override
 Read the value of an encoder.
 
bool getEncodersRaw (double *encs) override
 Read the position of all axes.
 
bool getEncoderSpeedRaw (int j, double *sp) override
 Read the instantaneous speed of an axis.
 
bool getEncoderSpeedsRaw (double *spds) override
 Read the instantaneous acceleration of an axis.
 
bool getEncoderAccelerationRaw (int j, double *spds) override
 Read the instantaneous acceleration of an axis.
 
bool getEncoderAccelerationsRaw (double *accs) override
 Read the instantaneous acceleration of all axes.
 
- Public Member Functions inherited from yarp::dev::IEncodersRaw
virtual ~IEncodersRaw ()
 Destructor.
 

Detailed Description

Stub implementation of IEncodersRaw interface.

Inherit from this class if you want a stub implementation of methods in IPositionControlRaw. This class allows to gradually implement an interface; you just have to implement functions that are useful for the underlying device. Another way to see this class is as a means to convert compile time errors in runtime errors.

If you use this class please be aware that the device you are wrapping might not function properly because you missed to implement useful functionalities.

Definition at line 32 of file ImplementControlBoardInterfaces.h.

Constructor & Destructor Documentation

◆ ~StubImplEncodersRaw()

virtual yarp::dev::StubImplEncodersRaw::~StubImplEncodersRaw ( )
inlinevirtual

Definition at line 42 of file ImplementControlBoardInterfaces.h.

Member Function Documentation

◆ getAxes()

bool yarp::dev::StubImplEncodersRaw::getAxes ( int *  ax)
inlineoverridevirtual

Get the number of controlled axes.

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

Returns
the number of controlled axes.

Implements yarp::dev::IEncodersRaw.

Definition at line 44 of file ImplementControlBoardInterfaces.h.

◆ getEncoderAccelerationRaw()

bool yarp::dev::StubImplEncodersRaw::getEncoderAccelerationRaw ( int  j,
double *  spds 
)
inlineoverridevirtual

Read the instantaneous acceleration of an axis.

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

Implements yarp::dev::IEncodersRaw.

Definition at line 71 of file ImplementControlBoardInterfaces.h.

◆ getEncoderAccelerationsRaw()

bool yarp::dev::StubImplEncodersRaw::getEncoderAccelerationsRaw ( double *  accs)
inlineoverridevirtual

Read the instantaneous 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::IEncodersRaw.

Definition at line 74 of file ImplementControlBoardInterfaces.h.

◆ getEncoderRaw()

bool yarp::dev::StubImplEncodersRaw::getEncoderRaw ( int  j,
double *  v 
)
inlineoverridevirtual

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

Definition at line 59 of file ImplementControlBoardInterfaces.h.

◆ getEncoderSpeedRaw()

bool yarp::dev::StubImplEncodersRaw::getEncoderSpeedRaw ( int  j,
double *  sp 
)
inlineoverridevirtual

Read the instantaneous speed of an axis.

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

Implements yarp::dev::IEncodersRaw.

Definition at line 65 of file ImplementControlBoardInterfaces.h.

◆ getEncoderSpeedsRaw()

bool yarp::dev::StubImplEncodersRaw::getEncoderSpeedsRaw ( double *  spds)
inlineoverridevirtual

Read the instantaneous acceleration of an axis.

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

Implements yarp::dev::IEncodersRaw.

Definition at line 68 of file ImplementControlBoardInterfaces.h.

◆ getEncodersRaw()

bool yarp::dev::StubImplEncodersRaw::getEncodersRaw ( double *  encs)
inlineoverridevirtual

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

Definition at line 62 of file ImplementControlBoardInterfaces.h.

◆ resetEncoderRaw()

bool yarp::dev::StubImplEncodersRaw::resetEncoderRaw ( int  j)
inlineoverridevirtual

Reset encoder, single joint.

Set the encoder value to zero

Parameters
jencoder number
Returns
true/false

Implements yarp::dev::IEncodersRaw.

Definition at line 47 of file ImplementControlBoardInterfaces.h.

◆ resetEncodersRaw()

bool yarp::dev::StubImplEncodersRaw::resetEncodersRaw ( )
inlineoverridevirtual

Reset encoders.

Set the encoders value to zero

Returns
true/false

Implements yarp::dev::IEncodersRaw.

Definition at line 50 of file ImplementControlBoardInterfaces.h.

◆ setEncoderRaw()

bool yarp::dev::StubImplEncodersRaw::setEncoderRaw ( int  j,
double  val 
)
inlineoverridevirtual

Set the value of the encoder for a given joint.

Parameters
jencoder number
valnew value
Returns
true/false

Implements yarp::dev::IEncodersRaw.

Definition at line 53 of file ImplementControlBoardInterfaces.h.

◆ setEncodersRaw()

bool yarp::dev::StubImplEncodersRaw::setEncodersRaw ( const double *  vals)
inlineoverridevirtual

Set the value of all encoders.

Parameters
valspointer to the new values
Returns
true/false

Implements yarp::dev::IEncodersRaw.

Definition at line 56 of file ImplementControlBoardInterfaces.h.


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