update the information about enabled vs not

With the roboRIO, we get different information about whether motors are
enabled (and some about sensors too), so the system for propagating it
around to everything needs to change.

Change-Id: I7e5f9591eeac1fdfe57b271333c3827431fbef01
diff --git a/frc971/control_loops/drivetrain/drivetrain.cc b/frc971/control_loops/drivetrain/drivetrain.cc
index c88169a..395f8b9 100644
--- a/frc971/control_loops/drivetrain/drivetrain.cc
+++ b/frc971/control_loops/drivetrain/drivetrain.cc
@@ -630,7 +630,7 @@
       loop_->mutable_U(1, 0) = ::aos::Clip(
           (R_right / Kv)(0, 0) + (IsInGear(right_gear_) ? 0 : wiggle),
           -12.0, 12.0);
-      loop_->mutable_U() *= 12.0 / position_.battery_voltage;
+      loop_->mutable_U() *= 12.0 / ::aos::robot_state->voltage_battery;
 #endif
     }
   }
diff --git a/frc971/control_loops/drivetrain/drivetrain.q b/frc971/control_loops/drivetrain/drivetrain.q
index ea1324d..5f34e92 100644
--- a/frc971/control_loops/drivetrain/drivetrain.q
+++ b/frc971/control_loops/drivetrain/drivetrain.q
@@ -39,7 +39,6 @@
     double right_encoder;
     //double left_shifter_position;
     //double right_shifter_position;
-    double battery_voltage;
   };
 
   message Output {
diff --git a/frc971/control_loops/zeroed_joint.h b/frc971/control_loops/zeroed_joint.h
index e1a256b..f25434f 100644
--- a/frc971/control_loops/zeroed_joint.h
+++ b/frc971/control_loops/zeroed_joint.h
@@ -323,7 +323,7 @@
         // Set the goal to here to make it so it doesn't move when disabled.
         loop_->R = loop_->X_hat;
         // Only progress if we are enabled.
-        if (::aos::robot_state->enabled) {
+        if (::aos::joystick_state->enabled) {
           if (AnySensorsActive(position)) {
             state_ = MOVING_OFF;
           } else {
@@ -336,7 +336,7 @@
       LOG(DEBUG, "MOVING_OFF\n");
       {
         // Move off the hall effect sensor.
-        if (!::aos::robot_state->enabled) {
+        if (!::aos::joystick_state->enabled) {
           // Start over if disabled.
           state_ = UNINITIALIZED;
         } else if (position && !AnySensorsActive(position)) {
@@ -353,7 +353,7 @@
       LOG(DEBUG, "ZEROING\n");
       {
         int active_sensor_index = ActiveSensorIndex(position);
-        if (!::aos::robot_state->enabled) {
+        if (!::aos::joystick_state->enabled) {
           // Start over if disabled.
           state_ = UNINITIALIZED;
         } else if (position && active_sensor_index != -1) {