Motion Profiles
Motion profiles are depictions of how a robot should move from point A to point B.
Trapezoidal Motion Profile

TrapezoidMotionProfile::Constraints constraints{
.maxVelocity = 36.0f, // in/s
.maxAcceleration = 48.0f, // in/s^2
.maxDeceleration = 100.0f // in/s^2
};
TrapezoidMotionProfile profile = TrapezoidMotionProfile(
constraints,
100.0f, // distance to travel (in)
0.0f, // initial velocity (in/s)
0.0f // ending velocity (in/s)
);
void opcontrol() override {
while (true) {
auto expectedState = profile.getStateAtTime(pros::millis() / 1000.0);
// Use expectedState.position and expectedState.velocity to control the robot
// ...
}
}