17 #define JOINTIDCHECK if (m >= castToMapper(helper)->axes()){yError("motor id out of bound"); return false;}
yarp::dev::ControlBoardHelper * castToMapper(void *p)
void accE2A(double enc, int j, double &ang, int &k)
void velE2A(double enc, int j, double &ang, int &k)
void posE2A(double enc, int j, double &ang, int &k)
void posA2E(double ang, int j, double &enc, int &k)
Control board, encoder interface.
virtual bool setMotorEncoderCountsPerRevolutionRaw(int m, const double cpr)=0
Sets number of counts per revolution for motor encoder m.
virtual bool getMotorEncoderRaw(int m, double *v)=0
Read the value of a motor encoder.
virtual bool getMotorEncoderAccelerationsRaw(double *accs)=0
Read the instantaneous acceleration of all motor encoders.
virtual bool resetMotorEncodersRaw()=0
Reset motor encoders.
virtual bool getMotorEncoderCountsPerRevolutionRaw(int m, double *cpr)=0
Gets number of counts per revolution for motor encoder m.
virtual bool getMotorEncoderSpeedRaw(int m, double *sp)=0
Read the istantaneous speed of a motor encoder.
virtual bool getMotorEncodersTimedRaw(double *encs, double *stamps)=0
Read the instantaneous position of all motor encoders.
virtual bool getMotorEncodersRaw(double *encs)=0
Read the position of all motor encoders.
virtual bool getMotorEncoderSpeedsRaw(double *spds)=0
Read the instantaneous speed of all motor encoders.
virtual bool setMotorEncodersRaw(const double *vals)=0
Set the value of all motor encoders.
virtual bool setMotorEncoderRaw(int m, const double val)=0
Set the value of the motor encoder for a given motor.
virtual bool resetMotorEncoderRaw(int m)=0
Reset motor encoder, single motor.
virtual bool getMotorEncoderTimedRaw(int m, double *encs, double *stamp)=0
Read the instantaneous position of a motor encoder.
virtual bool getMotorEncoderAccelerationRaw(int m, double *spds)=0
Read the instantaneous acceleration of a motor encoder.
bool getMotorEncoderAccelerations(double *accs) override
Read the instantaneous acceleration of all motor encoders.
bool setMotorEncoderCountsPerRevolution(int m, const double cpr) override
Sets number of counts per revolution for motor encoder m.
ImplementMotorEncoders(yarp::dev::IMotorEncodersRaw *y)
bool getMotorEncodersTimed(double *encs, double *time) override
Read the instantaneous position of all motor encoders.
bool uninitialize()
Clean up internal data and memory.
bool getMotorEncoderSpeeds(double *spds) override
Read the instantaneous speed of all motor encoders.
bool getMotorEncoderTimed(int m, double *v, double *t) override
Read the instantaneous position of a motor encoder.
bool getMotorEncoder(int m, double *v) override
Read the value of a motor encoder.
bool getMotorEncoderSpeed(int m, double *spds) override
Read the istantaneous speed of a motor encoder.
bool setMotorEncoder(int m, const double val) override
Set the value of the motor encoder for a given motor.
IMotorEncodersRaw * iMotorEncoders
yarp::dev::impl::FixedSizeBuffersManager< double > * buffManager
bool getMotorEncoderAcceleration(int m, double *spds) override
Read the instantaneous acceleration of a motor encoder.
bool setMotorEncoders(const double *vals) override
Set the value of all motor encoders.
virtual ~ImplementMotorEncoders()
bool getMotorEncoderCountsPerRevolution(int m, double *cpr) override
Gets number of counts per revolution for motor encoder m.
bool resetMotorEncoder(int m) override
Reset motor encoder, single motor.
bool resetMotorEncoders() override
Reset motor encoders.
bool getMotorEncoders(double *encs) override
Read the position of all motor encoders.
bool getNumberOfMotorEncoders(int *num) override
Get the number of available motor encoders.
bool initialize(int size, const int *amap, const double *enc, const double *zos)
Initialize the internal data and alloc memory.
Buffer contains info about a buffer of type T and it is used to exchange information with yarp::dev::...
T * getData()
Return the data pointer.
Buffer< T > getBuffer()
Get a buffer and fill its information in @buffer.
void releaseBuffer(Buffer< T > &buffer)
Release a buffer.
An interface for the device drivers.
An interface to the operating system, including Port based communication.