DifferentialDriveWheelSpeeds

class wpimath.kinematics.DifferentialDriveWheelSpeeds(left: meters_per_second = 0, right: meters_per_second = 0)

Bases: pybind11_object

Represents the wheel speeds for a differential drive drivetrain.

desaturate(attainableMaxSpeed: meters_per_second) None

Renormalizes the wheel speeds if either side is above the specified maximum.

Sometimes, after inverse kinematics, the requested speed from one or more wheels may be above the max attainable speed for the driving motor on that wheel. To fix this issue, one can reduce all the wheel speeds to make sure that all requested module speeds are at-or-below the absolute threshold, while maintaining the ratio of speeds between wheels.

Parameters:

attainableMaxSpeed – The absolute max speed that a wheel can reach.

static fromFeet(left: feet_per_second, right: feet_per_second) wpimath.kinematics._kinematics.DifferentialDriveWheelSpeeds
property left

Speed of the left side of the robot.

property left_fps
property right

Speed of the right side of the robot.

property right_fps