Fixed Austin's comments.
Squashed 'Changed fender shot to long without IMU' and
fixed Austin's comments.
Change-Id: Id81f4f8d35bb399d33bb74bd3d4e895603817711
diff --git a/y2016/joystick_reader.cc b/y2016/joystick_reader.cc
index 45733ff..6a0edf0 100644
--- a/y2016/joystick_reader.cc
+++ b/y2016/joystick_reader.cc
@@ -120,8 +120,6 @@
void HandleDrivetrain(const ::aos::input::driver_station::Data &data) {
bool is_control_loop_driving = false;
- static double left_goal = 0.0;
- static double right_goal = 0.0;
const double wheel = -data.GetAxis(kSteeringWheel);
const double throttle = -data.GetAxis(kDriveThrottle);
@@ -238,18 +236,15 @@
shooter_velocity_ = 640.0;
intake_goal_ = intake_when_shooting;
} else if (data.IsPressed(kBackFender)) {
- // Fender shot back
- shoulder_goal_ = M_PI / 2.0 - 0.2;
- wrist_goal_ = -0.55;
- shooter_velocity_ = 600.0;
+ // Backwards shot no IMU
+ shoulder_goal_ = M_PI / 2.0 - 0.4;
+ wrist_goal_ = -0.62 - 0.02;
+ shooter_velocity_ = 640.0;
intake_goal_ = intake_when_shooting;
} else if (data.IsPressed(kFrontFender)) {
- // Forwards shot, higher
+ // Forwards shot no IMU
shoulder_goal_ = M_PI / 2.0 + 0.1;
- wrist_goal_ = M_PI + 0.41 + 0.02 + 0.020;
- if (drivetrain_queue.status.get()) {
- wrist_goal_ += drivetrain_queue.status->ground_angle;
- }
+ wrist_goal_ = M_PI + 0.41 + 0.02 - 0.005;
shooter_velocity_ = 640.0;
intake_goal_ = intake_when_shooting;
} else if (data.IsPressed(kExpand) || data.IsPressed(kWinch)) {
@@ -458,6 +453,10 @@
double wrist_goal_;
double shooter_velocity_ = 0.0;
+ // Turning goals
+ double left_goal;
+ double right_goal;
+
bool was_running_ = false;
bool auto_running_ = false;