[wpimath] Report error on negative PID gains (#6055)

Defaults PID gains to zero if any are invalid.
This commit is contained in:
Tyler Veness
2023-12-23 12:15:29 -08:00
committed by GitHub
parent 1dba26c937
commit 22a322c9f3
9 changed files with 92 additions and 48 deletions

View File

@@ -31,9 +31,7 @@ class Robot : public frc::TimedRobot {
private:
// proportional speed constant
// negative because applying positive voltage will bring us closer to the
// target
static constexpr double kP = -0.001;
static constexpr double kP = 0.001;
// integral speed constant
static constexpr double kI = 0.0;
// derivative speed constant