Abstract class representing any joints within a Robot.
More...
#include <Joint.h>
|
| | Joint (int jointID, double jointMin, double jointMax) |
| | Construct a new Joint object. More...
|
| |
| | Joint (int jointID, double jointMin, double jointMax, double q0) |
| | Construct a new Joint object with initial value for the joint. More...
|
| |
| | ~Joint () |
| | Destroy the Joint object. More...
|
| |
| int | getId () |
| | Get the Id object. More...
|
| |
| double | getQ () |
| | Returns the internal value of the joint (e.g. Angle, length, depending on joint type) More...
|
| |
| double | getQd () |
| | Returns the internal value of the joint (e.g. del Angle, del length, depending on joint type) More...
|
| |
| void | getStatus () |
| | prints out the status of the joints current position in degrees More...
|
| |
| virtual bool | updateValue ()=0 |
| | Updates the value of the joint. This will read the value from hardware, and update the software's current representation of the value. More...
|
| |
| virtual bool | initNetwork ()=0 |
| | Pure virtual function for initialising the underlying CANopen Network to send and recieve PDO messages for this joint. More...
|
| |
|
| const int | id |
| |
| double | q |
| |
| double | qd |
| |
| const double | qMin |
| |
| const double | qMax |
| |
Abstract class representing any joints within a Robot.
Definition at line 23 of file Joint.h.
| Joint::Joint |
( |
int |
jointID, |
|
|
double |
jointMin, |
|
|
double |
jointMax |
|
) |
| |
Construct a new Joint object.
- Parameters
-
| jointID | The joint ID for this object |
| jointMin | The minimum allowable value for this joint (below this will cause an error) |
| jointMax | The maximum allowable value for this joint (above this will cause an error) |
The Joint class is a abstract class which represents a joint in a Robot objec. This class can be used to represent all types of joints, including actuated, non-actuated, revolute, prismatic, etc.
Version 0.1 Date: 07/04/2020
Definition at line 16 of file Joint.cpp.
| Joint::Joint |
( |
int |
jointID, |
|
|
double |
jointMin, |
|
|
double |
jointMax, |
|
|
double |
q0 |
|
) |
| |
Construct a new Joint object with initial value for the joint.
- Parameters
-
| jointID | The joint ID for this object |
| jointMin | The minimum allowable value for this joint (below this will cause an error) |
| jointMax | The maximum allowable value for this joint (above this will cause an error) |
| q0 | Initial value of this joint |
Definition at line 20 of file Joint.cpp.
Get the Id object.
- Returns
- int The ID used for the joint.
Definition at line 26 of file Joint.cpp.
Returns the internal value of the joint (e.g. Angle, length, depending on joint type)
NOTES:
- This returns only a single double value. Implementations of this joint may choose to include other methods to return other states of the joint.
- This does not necessarily reflect the actual value of the joint, it will only return the last value called by the updateValue() function. This allows for the update and use of the value to be updated independently (and potentially at different rates) such that the same value can be called multiple times in parallel.
- Returns
- double The current internal representation of the value of the joint
Definition at line 30 of file Joint.cpp.
Returns the internal value of the joint (e.g. del Angle, del length, depending on joint type)
NOTES:
- This returns only a single double value. Implementations of this joint may choose to include other methods to return other states of the joint.
- This does not necessarily reflect the actual value of the joint, it will only return the last value called by the updateValue() function. This allows for the update and use of the value to be updated independently (and potentially at different rates) such that the same value can be called multiple times in parallel.
- Returns
- double The current internal representation of the value of the joint
| void Joint::getStatus |
( |
| ) |
|
prints out the status of the joints current position in degrees
Definition at line 34 of file Joint.cpp.
| virtual bool Joint::initNetwork |
( |
| ) |
|
|
pure virtual |
Pure virtual function for initialising the underlying CANopen Network to send and recieve PDO messages for this joint.
- Returns
- true if successful
-
false if unsuccessful
Implemented in DummyActJoint.
| virtual bool Joint::updateValue |
( |
| ) |
|
|
pure virtual |
Updates the value of the joint. This will read the value from hardware, and update the software's current representation of the value.
- Returns
- true if successful
-
false if unsuccessful
Implemented in DummyActJoint.
An identifier for this joint. Note that this identifier is designed to be unique, but this is not managed by the joint class.
Definition at line 29 of file Joint.h.
The current state of the joint (i.e. the value), to be returned in SI units.
Definition at line 33 of file Joint.h.
The current state of the change in the joint position(i.e. the value), to be returned in SI units.
Definition at line 37 of file Joint.h.
The allowable limits of the joint. This should represent the theoretical limits of the joint. Should these be exceeded, an error should be thrown.
Definition at line 42 of file Joint.h.
The documentation for this class was generated from the following files: