Convert aos over to flatbuffers
Everything builds, and all the tests pass. I suspect that some entries
are missing from the config files, but those will be found pretty
quickly on startup.
There is no logging or live introspection of queue messages.
Change-Id: I496ee01ed68f202c7851bed7e8786cee30df29f5
diff --git a/y2016/control_loops/superstructure/superstructure_controls.cc b/y2016/control_loops/superstructure/superstructure_controls.cc
index b8f3a48..269089b 100644
--- a/y2016/control_loops/superstructure/superstructure_controls.cc
+++ b/y2016/control_loops/superstructure/superstructure_controls.cc
@@ -1,6 +1,5 @@
#include "y2016/control_loops/superstructure/superstructure_controls.h"
-#include "aos/controls/control_loops.q.h"
#include "aos/logging/logging.h"
#include "y2016/control_loops/superstructure/integral_intake_plant.h"
@@ -96,10 +95,10 @@
// TODO(austin): Handle zeroing errors.
-void Arm::Correct(PotAndIndexPosition position_shoulder,
- PotAndIndexPosition position_wrist) {
- estimators_[kShoulderIndex].UpdateEstimate(position_shoulder);
- estimators_[kWristIndex].UpdateEstimate(position_wrist);
+void Arm::Correct(const PotAndIndexPosition *position_shoulder,
+ const PotAndIndexPosition *position_wrist) {
+ estimators_[kShoulderIndex].UpdateEstimate(*position_shoulder);
+ estimators_[kWristIndex].UpdateEstimate(*position_wrist);
// Handle zeroing errors
if (estimators_[kShoulderIndex].error()) {
@@ -130,7 +129,7 @@
}
{
- Y_ << position_shoulder.encoder, position_wrist.encoder;
+ Y_ << position_shoulder->encoder(), position_wrist->encoder();
Y_ += offset_;
loop_->Correct(Y_);
}