Class ChassisSubsystemInterface

Inheritance Relationships

Base Type

Class Documentation

class ChassisSubsystemInterface : public tap::control::Subsystem

Abstract interface for a robot chassis.

Public Functions

inline ChassisSubsystemInterface(Drivers *drivers)
inline virtual int getNumChassisMotors() const = 0
Returns:

the number of chassis motors

inline virtual bool allMotorsOnline() const = 0
Returns:

true iff all motors are online

virtual modm::Matrix<float, 3, 1> getActualVelocityChassisRelative() const = 0
Returns:

The actual chassis velocity in chassis relative frame, as a vector <vx, vy, vz>, where vz is rotational velocity. This is the velocity calculated from the chassis’s encoders. Units: m/s

Public Static Functions

static inline void getVelocityWorldRelative(modm::Matrix<float, 3, 1> &chassisRelativeVelocity, float chassisHeading)

Transforms the chassis relative velocity of the form <vx, vy, vz> (where z is an orientation) into world relative frame, given some particular chassis heading (z direction, assumed to be in radians). Transforms the input matrix chassisRelativeVelocity. Units: m/s