Added a bunch of new actions.
Change-Id: I890b4cef168baa12e02e181de683243ffa02e7c0
diff --git a/frc971/control_loops/claw/claw.cc b/frc971/control_loops/claw/claw.cc
index 64ba98e..ff378c8 100644
--- a/frc971/control_loops/claw/claw.cc
+++ b/frc971/control_loops/claw/claw.cc
@@ -258,12 +258,17 @@
if (output) {
output->voltage = claw_loop_->U(0, 0);
- if (unsafe_goal) {
- output->intake_voltage = unsafe_goal->intake;
- output->rollers_closed = unsafe_goal->rollers_closed;
- } else {
+ if (state_ != RUNNING) {
output->intake_voltage = 0.0;
output->rollers_closed = false;
+ } else {
+ if (unsafe_goal) {
+ output->intake_voltage = unsafe_goal->intake;
+ output->rollers_closed = unsafe_goal->rollers_closed;
+ } else {
+ output->intake_voltage = 0.0;
+ output->rollers_closed = false;
+ }
}
if (output->rollers_closed != last_rollers_closed_) {
last_piston_edge_ = Time::Now();
diff --git a/frc971/control_loops/fridge/fridge.q b/frc971/control_loops/fridge/fridge.q
index d1f5158..2337921 100644
--- a/frc971/control_loops/fridge/fridge.q
+++ b/frc971/control_loops/fridge/fridge.q
@@ -70,10 +70,10 @@
// state of the grabber pistons
GrabberPistons grabbers;
- // Goal angle of the arm.
+ // Goal angle and velocity of the arm.
double goal_angle;
double goal_angular_velocity;
- // Goal height of the elevator.
+ // Goal height and velocity of the elevator.
double goal_height;
double goal_velocity;