|
YARP
Yet Another Robot Platform
|
|
Go to the documentation of this file.
30 size_t subIndex =
device.
lut[j].deviceEntry;
51 for (
size_t subDev_idx = 0; subDev_idx <
device.
subdevices.size(); subDev_idx++) {
58 int wrapped_joints =
static_cast<int>((p->
top - p->
base) + 1);
59 int* joints =
new int[wrapped_joints];
63 for (
int j_dev = 0; j_dev < wrapped_joints; j_dev++) {
64 joints[j_dev] =
static_cast<int>(p->
base + j_dev);
68 j_wrap += wrapped_joints;
73 if (joints !=
nullptr) {
93 for (
int j = 0; j < n_joints; j++) {
94 subIndex =
device.
lut[joints[j]].deviceEntry;
122 size_t subIndex =
device.
lut[j].deviceEntry;
150 for (
size_t juser = p->
wbase, jdevice = p->
base; juser <= p->wtop; juser++, jdevice++) {
151 accs[juser] = references[jdevice];
175 for (
int j = 0; j < n_joints; j++) {
176 subIndex =
device.
lut[joints[j]].deviceEntry;
197 for (
int j = 0; j < n_joints; j++) {
198 subIndex =
device.
lut[joints[j]].deviceEntry;
203 for (
int j = 0; j < n_joints; j++) {
221 size_t subIndex =
device.
lut[j].deviceEntry;
230 return p->
pos->
stop(
static_cast<int>(off + p->
base));
242 size_t subIndex =
device.
lut[l].deviceEntry;
270 for (
int j = 0; j < n_joints; j++) {
271 subIndex =
device.
lut[joints[j]].deviceEntry;
314 for (
size_t juser = p->
wbase, jdevice = p->
base; juser <= p->wtop; juser++, jdevice++) {
315 vals[juser] = currs[jdevice];
336 size_t subIndex =
device.
lut[j].deviceEntry;
virtual bool setRefAccelerations(const double *accs)=0
Set reference acceleration on all joints.
virtual bool stop(int j)=0
Stop motion, single joint.
yarp::dev::IPositionControl * pos
bool getCurrent(int m, double *curr)
virtual bool getRefAcceleration(int j, double *acc)=0
Get reference acceleration for a joint.
virtual bool getCurrent(int j, double *val)=0
int * subdev_jointsVectorLen
yarp::dev::ICurrentControl * iCurr
virtual bool getCurrents(double *currs)=0
Get the instantaneous current measurement for all motors.
virtual bool setRefAcceleration(int j, double acc)=0
Set reference acceleration for a joint.
SubDevice ** subdevices_p
virtual bool getCurrent(int m, double *curr)=0
Get the instantaneous current measurement for a single motor.
bool getRefAcceleration(int j, double *acc)
const yarp::os::LogComponent & CONTROLBOARDWRAPPER()
SubDevice * getSubdevice(size_t i)
SubDeviceVector subdevices
#define yCError(component,...)
bool getCurrents(double *currs)
virtual bool getCurrents(double *vals)=0
std::vector< DevicesLutEntry > lut
bool getNumberOfMotors(int *num)
bool setRefAcceleration(int j, double acc)
bool setRefAccelerations(const double *accs)
bool getRefAccelerations(double *accs)
size_t maxNumOfJointsInDevices
virtual bool getRefAccelerations(double *accs)=0
Get reference acceleration of all joints.
yarp::dev::IAmplifierControl * amp
void printError(const std::string &func_name, const std::string &info, bool result)