Clean up the basic codelab

The config was incomplete because it didn't include timing reports, and
wasn't even using the standard config process anyways. The comments were
also out of date due to the flatbuffers transition, and I added in a bit
more boilerplate in the RunIteration function, since handling the
flatbuffer builders is a bit less trivial than the queues were.

Change-Id: I6a9b12ca6c925b561211937fcf36d932299946d2
diff --git a/frc971/codelab/basic_test.cc b/frc971/codelab/basic_test.cc
index fcb0f15..65ac625 100644
--- a/frc971/codelab/basic_test.cc
+++ b/frc971/codelab/basic_test.cc
@@ -7,7 +7,10 @@
 
 #include "aos/controls/control_loop_test.h"
 #include "aos/events/shm_event_loop.h"
-#include "frc971/codelab/basic_generated.h"
+#include "frc971/codelab/basic_goal_generated.h"
+#include "frc971/codelab/basic_output_generated.h"
+#include "frc971/codelab/basic_position_generated.h"
+#include "frc971/codelab/basic_status_generated.h"
 #include "frc971/control_loops/team_number_test_environment.h"
 #include "gtest/gtest.h"
 
@@ -82,38 +85,7 @@
  public:
   BasicControlLoopTest()
       : ::aos::testing::ControlLoopTest(
-            "{\n"
-            "  \"channels\": [ \n"
-            "    {\n"
-            "      \"name\": \"/aos\",\n"
-            "      \"type\": \"aos.JoystickState\"\n"
-            "    },\n"
-            "    {\n"
-            "      \"name\": \"/aos\",\n"
-            "      \"type\": \"aos.LogMessageFbs\"\n"
-            "    },\n"
-            "    {\n"
-            "      \"name\": \"/aos\",\n"
-            "      \"type\": \"aos.RobotState\"\n"
-            "    },\n"
-            "    {\n"
-            "      \"name\": \"/codelab\",\n"
-            "      \"type\": \"frc971.codelab.Goal\"\n"
-            "    },\n"
-            "    {\n"
-            "      \"name\": \"/codelab\",\n"
-            "      \"type\": \"frc971.codelab.Output\"\n"
-            "    },\n"
-            "    {\n"
-            "      \"name\": \"/codelab\",\n"
-            "      \"type\": \"frc971.codelab.Status\"\n"
-            "    },\n"
-            "    {\n"
-            "      \"name\": \"/codelab\",\n"
-            "      \"type\": \"frc971.codelab.Position\"\n"
-            "    }\n"
-            "  ]\n"
-            "}\n",
+            aos::configuration::ReadConfig("frc971/codelab/config.json"),
             chrono::microseconds(5050)),
         test_event_loop_(MakeEventLoop("test")),
         goal_sender_(test_event_loop_->MakeSender<Goal>("/codelab")),
@@ -124,6 +96,7 @@
         basic_simulation_event_loop_(MakeEventLoop("simulation")),
         basic_simulation_(basic_simulation_event_loop_.get(), dt()) {
     set_team_id(control_loops::testing::kTeamNumber);
+    SetEnabled(true);
   }
 
   ::std::unique_ptr<::aos::EventLoop> test_event_loop_;