A generic interface to sensors (gyro, a/d converters).
More...
#include <yarp/dev/IAnalogSensor.h>
A generic interface to sensors (gyro, a/d converters).
Similar to IGenerisSensor, but includes error handling.
Definition at line 26 of file IAnalogSensor.h.
◆ anonymous enum
Enumerator |
---|
AS_OK | |
AS_ERROR | |
AS_OVF | |
AS_TIMEOUT | |
Definition at line 29 of file IAnalogSensor.h.
◆ ~IAnalogSensor()
yarp::dev::IAnalogSensor::~IAnalogSensor |
( |
| ) |
|
|
virtualdefault |
◆ calibrateChannel() [1/2]
virtual int yarp::dev::IAnalogSensor::calibrateChannel |
( |
int |
ch | ) |
|
|
pure virtual |
Calibrates one single channel.
- Parameters
-
- Returns
- status.
Implemented in FakeAnalogSensor.
◆ calibrateChannel() [2/2]
virtual int yarp::dev::IAnalogSensor::calibrateChannel |
( |
int |
ch, |
|
|
double |
value |
|
) |
| |
|
pure virtual |
Calibrates one single channel, using a calibration value.
- Parameters
-
ch | channel number. |
value | calibration value. |
- Returns
- status.
Implemented in FakeAnalogSensor.
◆ calibrateSensor() [1/2]
virtual int yarp::dev::IAnalogSensor::calibrateSensor |
( |
| ) |
|
|
pure virtual |
◆ calibrateSensor() [2/2]
virtual int yarp::dev::IAnalogSensor::calibrateSensor |
( |
const yarp::sig::Vector & |
value | ) |
|
|
pure virtual |
Calibrates the whole sensor, using an vector of calibration values.
- Parameters
-
value | a vector of calibration values. |
- Returns
- status.
Implemented in FakeAnalogSensor.
◆ getChannels()
virtual int yarp::dev::IAnalogSensor::getChannels |
( |
| ) |
|
|
pure virtual |
Get the number of channels of the sensor.
- Returns
- number of channels (0 in case of errors).
Implemented in FakeAnalogSensor.
◆ getState()
virtual int yarp::dev::IAnalogSensor::getState |
( |
int |
ch | ) |
|
|
pure virtual |
Check the state value of a given channel.
- Parameters
-
- Returns
- status.
Implemented in FakeAnalogSensor.
◆ read()
Read a vector from the sensor.
- Parameters
-
out | a vector containing the sensor's last readings. |
- Returns
- AS_OK or return code. AS_TIMEOUT if the sensor timed-out.
Implemented in FakeAnalogSensor.
The documentation for this class was generated from the following files: