3 #include "hebi_feedback.h" 37 #ifndef DOXYGEN_OMIT_INTERNAL 38 FloatField(HebiFeedbackPtr
internal, HebiFeedbackFloatField field);
39 #endif // DOXYGEN_OMIT_INTERNAL 40 explicit operator bool()
const;
60 HebiFeedbackPtr
const internal_;
61 HebiFeedbackFloatField
const field_;
73 #ifndef DOXYGEN_OMIT_INTERNAL 75 #endif // DOXYGEN_OMIT_INTERNAL 76 explicit operator bool()
const;
108 void get(int64_t* revolutions,
float* radian_offset)
const;
111 HebiFeedbackPtr
const internal_;
112 HebiFeedbackHighResAngleField
const field_;
122 #ifndef DOXYGEN_OMIT_INTERNAL 124 #endif // DOXYGEN_OMIT_INTERNAL 125 bool has(
int fieldNumber)
const;
136 float get(
int fieldNumber)
const;
139 HebiFeedbackPtr
const internal_;
140 HebiFeedbackNumberedFloatField
const field_;
149 #ifndef DOXYGEN_OMIT_INTERNAL 150 UInt64Field(HebiFeedbackPtr
internal, HebiFeedbackUInt64Field field);
151 #endif // DOXYGEN_OMIT_INTERNAL 152 explicit operator bool()
const;
169 uint64_t
get()
const;
172 HebiFeedbackPtr
const internal_;
173 HebiFeedbackUInt64Field
const field_;
182 #ifndef DOXYGEN_OMIT_INTERNAL 183 Vector3fField(HebiFeedbackPtr
internal, HebiFeedbackVector3fField field);
184 #endif // DOXYGEN_OMIT_INTERNAL 185 explicit operator bool()
const;
205 HebiFeedbackPtr
const internal_;
206 HebiFeedbackVector3fField
const field_;
215 #ifndef DOXYGEN_OMIT_INTERNAL 216 IoBank(HebiFeedbackPtr
internal, HebiFeedbackIoPinBank bank);
217 #endif // DOXYGEN_OMIT_INTERNAL 218 bool hasInt(
int pinNumber)
const;
229 bool hasFloat(
int pinNumber)
const;
235 int64_t getInt(
int pinNumber)
const;
242 float getFloat(
int pinNumber)
const;
245 HebiFeedbackPtr
const internal_;
246 HebiFeedbackIoPinBank
const bank_;
254 #ifndef DOXYGEN_OMIT_INTERNAL 255 LedField(HebiFeedbackPtr
internal, HebiFeedbackLedField field);
256 #endif // DOXYGEN_OMIT_INTERNAL 257 explicit operator bool()
const {
return hasColor(); }
271 bool hasColor()
const;
273 Color getColor()
const;
276 HebiFeedbackPtr
const internal_;
277 HebiFeedbackLedField
const field_;
286 #ifndef DOXYGEN_OMIT_INTERNAL 287 Io(HebiFeedbackPtr
internal)
288 : internal_(
internal),
289 a_(
internal, HebiFeedbackIoBankA),
290 b_(
internal, HebiFeedbackIoBankB),
291 c_(
internal, HebiFeedbackIoBankC),
292 d_(
internal, HebiFeedbackIoBankD),
293 e_(
internal, HebiFeedbackIoBankE),
294 f_(
internal, HebiFeedbackIoBankF)
297 #endif // DOXYGEN_OMIT_INTERNAL 318 HebiFeedbackPtr
const internal_;
334 #ifndef DOXYGEN_OMIT_INTERNAL 336 : internal_(
internal),
337 velocity_(
internal, HebiFeedbackFloatVelocity),
338 effort_(
internal, HebiFeedbackFloatEffort),
339 velocity_command_(
internal, HebiFeedbackFloatVelocityCommand),
340 effort_command_(
internal, HebiFeedbackFloatEffortCommand),
341 deflection_(
internal, HebiFeedbackFloatDeflection),
342 deflection_velocity_(
internal, HebiFeedbackFloatDeflectionVelocity),
343 motor_velocity_(
internal, HebiFeedbackFloatMotorVelocity),
344 motor_current_(
internal, HebiFeedbackFloatMotorCurrent),
345 motor_sensor_temperature_(
internal, HebiFeedbackFloatMotorSensorTemperature),
346 motor_winding_current_(
internal, HebiFeedbackFloatMotorWindingCurrent),
347 motor_winding_temperature_(
internal, HebiFeedbackFloatMotorWindingTemperature),
348 motor_housing_temperature_(
internal, HebiFeedbackFloatMotorHousingTemperature),
349 position_(
internal, HebiFeedbackHighResAnglePosition),
350 position_command_(
internal, HebiFeedbackHighResAnglePositionCommand),
351 sequence_number_(
internal, HebiFeedbackUInt64SequenceNumber),
352 receive_time_(
internal, HebiFeedbackUInt64ReceiveTime),
353 transmit_time_(
internal, HebiFeedbackUInt64TransmitTime),
354 hardware_receive_time_(
internal, HebiFeedbackUInt64HardwareReceiveTime),
355 hardware_transmit_time_(
internal, HebiFeedbackUInt64HardwareTransmitTime)
358 #endif // DOXYGEN_OMIT_INTERNAL 405 HebiFeedbackPtr
const internal_;
434 #ifndef DOXYGEN_OMIT_INTERNAL 435 Imu(HebiFeedbackPtr
internal)
436 : internal_(
internal),
437 accelerometer_(
internal, HebiFeedbackVector3fAccelerometer),
438 gyro_(
internal, HebiFeedbackVector3fGyro)
441 #endif // DOXYGEN_OMIT_INTERNAL 454 HebiFeedbackPtr
const internal_;
467 HebiFeedbackPtr internal_;
470 #ifndef DOXYGEN_OMIT_INTERNAL 476 #endif // DOXYGEN_OMIT_INTERNAL 492 const Io&
io()
const {
return io_; }
506 #ifndef DOXYGEN_OMIT_INTERNAL 509 #endif // DOXYGEN_OMIT_INTERNAL
const Imu & imu() const
Inertial measurement unit feedback (accelerometers and gyros).
Definition: feedback.hpp:496
const UInt64Field & transmitTime() const
Timestamp of when message was transmitted to module (local)
Definition: feedback.hpp:398
Structure to hold a 3-D floating point vector (i.e., x/y/z components)
Definition: vector_3_f.hpp:8
#define HEBI_DISABLE_COPY(Class)
Definition: util.hpp:17
const FloatField & boardTemperature() const
Ambient temperature inside the module (measured at the IMU chip), in degrees Celsius.
Definition: feedback.cpp:222
const FloatField & effortCommand() const
Commanded effort at the module output; units vary (e.g., N * m for rotational joints and N for linear...
Definition: feedback.hpp:372
virtual ~Feedback() noexcept
Cleans up feedback object as necessary.
Definition: feedback.cpp:203
const IoBank & c() const
I/O pin bank c (pins 1-8 available)
Definition: feedback.hpp:309
const FloatField & deflectionVelocity() const
Velocity (in radians/second) of the difference between the pre-spring and post-spring output position...
Definition: feedback.hpp:376
const UInt64Field & hardwareTransmitTime() const
Timestamp of when message was transmitted from module (remote)
Definition: feedback.hpp:402
const FloatField & motorSensorTemperature() const
The temperature from a sensor near the motor housing.
Definition: feedback.hpp:382
const FloatField & motorWindingTemperature() const
The estimated temperature of the motor windings.
Definition: feedback.hpp:386
const UInt64Field & sequenceNumber() const
Sequence number going to module (local)
Definition: feedback.hpp:394
const IoBank & d() const
I/O pin bank d (pins 1-8 available)
Definition: feedback.hpp:311
const FloatField & motorWindingCurrent() const
The estimated current in the motor windings.
Definition: feedback.hpp:384
const UInt64Field & hardwareReceiveTime() const
Timestamp of when message was received by module (remote)
Definition: feedback.hpp:400
#define HEBI_DISABLE_COPY_MOVE(Class)
Definition: util.hpp:7
A message field representable by a single-precision floating point value.
Definition: feedback.hpp:34
const FloatField & motorHousingTemperature() const
The estimated temperature of the motor housing.
Definition: feedback.hpp:388
Inertial measurement unit feedback (accelerometers and gyros).
Definition: feedback.hpp:431
Feedback objects have various fields representing feedback from modules; which fields are populated d...
Definition: feedback.hpp:29
A message field for interfacing with a bank of I/O pins.
Definition: feedback.hpp:212
const UInt64Field & receiveTime() const
Timestamp of when message was received from module (local)
Definition: feedback.hpp:396
const FloatField & motorVelocity() const
The velocity (in radians/second) of the motor shaft.
Definition: feedback.hpp:378
const HighResAngleField & position() const
Position of the module output (post-spring), in radians.
Definition: feedback.hpp:390
const LedField & led() const
The module's LED.
Definition: feedback.cpp:238
A message field for an angle measurement which does not lose precision at very high angles...
Definition: feedback.hpp:70
bool has() const
True if (and only if) the field has a value.
Definition: feedback.cpp:20
const FloatField & deflection() const
Difference (in radians) between the pre-spring and post-spring output position.
Definition: feedback.hpp:374
const Actuator & actuator() const
Actuator-specific feedback.
Definition: feedback.hpp:494
const IoBank & e() const
I/O pin bank e (pins 1-8 available)
Definition: feedback.hpp:313
const FloatField & velocityCommand() const
Commanded velocity of the module output (post-spring), in radians/second.
Definition: feedback.hpp:370
A message field for interfacing with an LED.
Definition: feedback.hpp:251
const FloatField & voltage() const
Bus voltage that the module is running at (in Volts).
Definition: feedback.cpp:230
const FloatField & motorCurrent() const
Current supplied to the motor.
Definition: feedback.hpp:380
const IoBank & f() const
I/O pin bank f (pins 1-8 available)
Definition: feedback.hpp:315
Feedback from any available I/O pins on the device.
Definition: feedback.hpp:283
A message field representable by an unsigned 64 bit integer value.
Definition: feedback.hpp:146
const IoBank & a() const
I/O pin bank a (pins 1-8 available)
Definition: feedback.hpp:305
const FloatField & processorTemperature() const
Temperature of the processor chip, in degrees Celsius.
Definition: feedback.cpp:226
Actuator-specific feedback.
Definition: feedback.hpp:331
const Io & io() const
Feedback from any available I/O pins on the device.
Definition: feedback.hpp:492
const Vector3fField & accelerometer() const
Accelerometer data, in m/s^2.
Definition: feedback.hpp:449
Feedback(Feedback &&other)
Move constructor (necessary for containment in STL template classes)
Definition: feedback.cpp:191
const IoBank & b() const
I/O pin bank b (pins 1-8 available)
Definition: feedback.hpp:307
const HighResAngleField & positionCommand() const
Commanded position of the module output (post-spring), in radians.
Definition: feedback.hpp:392
Structure to describe an RGB color.
Definition: color.hpp:8
const FloatField & velocity() const
Velocity of the module output (post-spring), in radians/second.
Definition: feedback.hpp:366
A message field containing a numbered set of single-precision floating point values.
Definition: feedback.hpp:119
A message field representable by a 3-D vector of single-precision floating point values.
Definition: feedback.hpp:179
const FloatField & effort() const
Effort at the module output; units vary (e.g., N * m for rotational joints and N for linear stages)...
Definition: feedback.hpp:368
const Vector3fField & gyro() const
Gyro data, in radians/second.
Definition: feedback.hpp:451