Reduce size of IMU zeroing buffer
The 10000 sample buffer was causing some issues. Lower the size of the
buffer until I can determine how I really want to manage it.
Change-Id: I9e4a84a8448ed4aeb7e7cc39622970a9aeede674
diff --git a/frc971/control_loops/drivetrain/drivetrain.cc b/frc971/control_loops/drivetrain/drivetrain.cc
index a8014d5..094a947 100644
--- a/frc971/control_loops/drivetrain/drivetrain.cc
+++ b/frc971/control_loops/drivetrain/drivetrain.cc
@@ -53,6 +53,11 @@
right_high_requested_(dt_config_.default_high_gear) {
::aos::controls::HPolytope<0>::Init();
event_loop->SetRuntimeRealtimePriority(30);
+ event_loop->OnRun([this]() {
+ // On the first fetch, make sure that we are caught all the way up to the
+ // present.
+ imu_values_fetcher_.Fetch();
+ });
}
int DrivetrainLoop::ControllerIndexFromGears() {