NTRT Simulator
Version: Master
|
#include <tgControllable.h>
Public Member Functions | |
tgControllable () | |
virtual | ~tgControllable () |
virtual void | setControlInput (double input)=0 |
virtual void | setControlInput (double input, double dt) |
An abstract mixin base class for classes that can be affected by controllers. Defines the common control API. Controllers will likely be observers, so they will know the details of their subjects/ controllables. That said, it is not worth making something this low level a subject, as there are higher level details not defined in this API (sensor data, etc)
Definition at line 39 of file tgControllable.h.
|
inline |
The consructor has nothing to do.
Definition at line 44 of file tgControllable.h.
|
inlinevirtual |
The virtual destructor has nothing to do.
Definition at line 47 of file tgControllable.h.
|
pure virtual |
Set the relevant control variable for this class, such as commanded position or torque
[in] | input,the | control input, units are application dependent |
Implemented in tgCompressionSpringActuator, tgKinematicActuator, and tgBasicActuator.
|
inlinevirtual |
Secondary function for those classes which need to know how much time has elapsed since they last recieved input (such as tgBasicActuator's moveMotors(dt) function) This will silently fail if it is called erroneously
[in] | input,the | desired control input |
[in] | dt,the | time elapsed since the last call. Must be positive (typically enforced in child class) |
Reimplemented in tgCompressionSpringActuator, and tgBasicActuator.
Definition at line 65 of file tgControllable.h.