Added indexer support, with stall detection.
Re-tuned some other loops while I was learning more about the indexer.
Change-Id: I893f1f273b31357ae9137601ca27322fc3b09d98
diff --git a/y2017/control_loops/superstructure/shooter/shooter.cc b/y2017/control_loops/superstructure/shooter/shooter.cc
index d30a45c..c4d1630 100644
--- a/y2017/control_loops/superstructure/shooter/shooter.cc
+++ b/y2017/control_loops/superstructure/shooter/shooter.cc
@@ -90,9 +90,11 @@
}
}
if (reset_) {
- loop_->mutable_X_hat(2, 0) = 0.0;
- loop_->mutable_X_hat(1, 0) = dt_velocity_;
loop_->mutable_X_hat(0, 0) = Y_(0, 0);
+ // TODO(austin): This should be 0 for the WPILib reset since dt_velocity_
+ // will be rubbish.
+ loop_->mutable_X_hat(1, 0) = dt_velocity_;
+ loop_->mutable_X_hat(2, 0) = 0.0;
reset_ = false;
}
last_ready_ = ready_;