YARP
Yet Another Robot Platform
 
Loading...
Searching...
No Matches
ImplementCurrentControl.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2006-2021 Istituto Italiano di Tecnologia (IIT)
3 * SPDX-License-Identifier: BSD-3-Clause
4 */
5
6#ifndef YARP_DEV_IMPLEMENTCURRENTCONTROL_H
7#define YARP_DEV_IMPLEMENTCURRENTCONTROL_H
8
10#include <yarp/dev/api.h>
11
12namespace yarp::dev {
13class ImplementCurrentControl;
14}
15
16namespace yarp::dev::impl {
17
18template <typename T>
19class FixedSizeBuffersManager;
20
21} // namespace yarp::dev::impl
22
24{
25protected:
27 void *helper;
30
37 bool initialize(int size, const int *amap, const double* ampsToSens);
38
43 bool uninitialize();
44
45public:
46 /* Constructor.
47 * @param y is the pointer to the class instance inheriting from this
48 * implementation.
49 */
51
56
57 bool getNumberOfMotors(int *ax) override;
58 bool getRefCurrent(int j, double *) override;
59 bool getRefCurrents(double *t) override;
60 bool setRefCurrents(const double *t) override;
61 bool setRefCurrent(int j, double t) override;
62 bool setRefCurrents(const int n_joint, const int *joints, const double *t) override;
63 bool getCurrents(double *t) override;
64 bool getCurrent(int j, double *t) override;
65 bool getCurrentRange(int j, double *min, double *max) override;
66 bool getCurrentRanges(double *min, double *max) override;
67};
68
69#endif // YARP_DEV_IMPLEMENTCURRENTCONTROL_H
float t
Interface for control boards implementing current control.
Interface for control boards implementing current control.
bool getCurrentRanges(double *min, double *max) override
Get the full scale of the current measurements for all motors motor (e.g.
yarp::dev::impl::FixedSizeBuffersManager< int > * intBuffManager
bool getCurrents(double *t) override
Get the instantaneous current measurement for all motors.
bool getCurrent(int j, double *t) override
Get the instantaneous current measurement for a single motor.
bool uninitialize()
Clean up internal data and memory.
bool getRefCurrents(double *t) override
Get the reference value of the currents for all motors.
bool getRefCurrent(int j, double *) override
Get the reference value of the current for a single motor.
yarp::dev::impl::FixedSizeBuffersManager< double > * doubleBuffManager
bool setRefCurrents(const double *t) override
Set the reference value of the currents for all motors.
bool getCurrentRange(int j, double *min, double *max) override
Get the full scale of the current measurement for a given motor (e.g.
bool getNumberOfMotors(int *ax) override
Retrieves the number of controlled axes from the current physical interface.
yarp::dev::ICurrentControlRaw * iCurrentRaw
bool initialize(int size, const int *amap, const double *ampsToSens)
Initialize the internal data and alloc memory.
bool setRefCurrent(int j, double t) override
Set the reference value of the current for a single motor.
A manager of fixed size buffers in multi-thread environment.
For streams capable of holding different kinds of content, check what they actually have.
Definition jointData.cpp:13
The main, catch-all namespace for YARP.
Definition dirs.h:16
#define YARP_dev_API
Definition api.h:18