Fix trapezoidal profile PID controller setpoint bug (#2210)

Co-Authored-By: Austin Shalit <austinshalit@gmail.com>
This commit is contained in:
Matt
2020-01-01 15:23:25 -08:00
committed by Peter Johnson
parent abe25b795b
commit 222669dc2c
8 changed files with 90 additions and 14 deletions

View File

@@ -113,7 +113,7 @@ public class ProfiledPIDCommand extends CommandBase {
@Override
public void initialize() {
m_controller.reset();
m_controller.reset(m_measurement.getAsDouble());
}
@Override

View File

@@ -93,7 +93,7 @@ public abstract class ProfiledPIDSubsystem extends SubsystemBase {
*/
public void enable() {
m_enabled = true;
m_controller.reset();
m_controller.reset(getMeasurement());
}
/**