okapi::Odometry class

Derived classes

class TwoEncoderOdometry

Constructors, destructors, conversion operators

Odometry() defaulted explicit
Odometry.
~Odometry() defaulted virtual

Public functions

void setScales(const ChassisScales& ichassisScales) pure virtual
Sets the drive and turn scales.
void step() pure virtual
Do one odometry step.
auto getState(const StateMode& imode = StateMode::FRAME_TRANSFORMATION) const -> OdomState pure virtual
Returns the current state.
void setState(const OdomState& istate, const StateMode& imode = StateMode::FRAME_TRANSFORMATION) pure virtual
Sets a new state to be the current state.
auto getModel() -> std::shared_ptr<ReadOnlyChassisModel> pure virtual
auto getScales() -> ChassisScales pure virtual

Function documentation

okapi::Odometry::Odometry() explicit defaulted

Odometry.

Tracks the movement of the robot and estimates its position in coordinates relative to the start (assumed to be (0, 0, 0)).

OdomState okapi::Odometry::getState(const StateMode& imode = StateMode::FRAME_TRANSFORMATION) const pure virtual

Returns the current state.

Parameters
imode The mode to return the state in.
Returns The current state in the given format.

void okapi::Odometry::setState(const OdomState& istate, const StateMode& imode = StateMode::FRAME_TRANSFORMATION) pure virtual

Sets a new state to be the current state.

Parameters
istate The new state in the given format.
imode The mode to treat the input state as.

std::shared_ptr<ReadOnlyChassisModel> okapi::Odometry::getModel() pure virtual

Returns The internal ChassisModel.

ChassisScales okapi::Odometry::getScales() pure virtual

Returns The internal ChassisScales.