mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-23 01:21:42 +00:00
[wpimath] Fix PID atSetpoint to not return true prematurely (#4906)
Wait until setpoint and measurement have been set.
This commit is contained in:
@@ -252,6 +252,9 @@ class WPILIB_DLLEXPORT PIDController
|
||||
|
||||
double m_setpoint = 0;
|
||||
double m_measurement = 0;
|
||||
|
||||
bool m_haveSetpoint = false;
|
||||
bool m_haveMeasurement = false;
|
||||
};
|
||||
|
||||
} // namespace frc2
|
||||
|
||||
Reference in New Issue
Block a user