add code for switching b/w cameras
[3501/stronghold-2016] / src / org / usfirst / frc / team3501 / robot / subsystems / DriveTrain.java
index 1079d501a82fc4f52d281b0c8e96478a2a0653a9..807bb151ec2d3b239329c3f9aafeabd41ff438f8 100644 (file)
@@ -164,10 +164,10 @@ public class DriveTrain extends PIDSubsystem {
   /*
    * Method is a required method that the PID Subsystem uses to return the
    * calculated PID value to the driver
-   * 
+   *
    * @param Gives the user the output from the PID algorithm that is calculated
    * internally
-   * 
+   *
    * Body: Uses the output, does some filtering and drives the robot
    */
   @Override
@@ -190,7 +190,7 @@ public class DriveTrain extends PIDSubsystem {
 
   /*
    * Checks the drive mode
-   * 
+   *
    * @return the current state of the robot in each state Average distance from
    * both sides of tank drive for Encoder Mode Angle from the gyro in GYRO_MODE
    */
@@ -207,8 +207,15 @@ public class DriveTrain extends PIDSubsystem {
 
   public void setMotorSpeeds(double left, double right) {
     double k = (isFlipped() ? -1 : 1);
-    cheese.cheesyDrive(-left * k, -right,
-        getGearPistonValue() == Constants.DriveTrain.HIGH_GEAR);
+    /*
+     * cheese.cheesyDrive(-left * k, -right, getGearPistonValue() ==
+     * Constants.DriveTrain.HIGH_GEAR);
+     */
+
+    frontLeft.set(left);
+    rearLeft.set(left);
+    frontRight.set(right);
+    rearRight.set(right);
   }
 
   /**
@@ -246,8 +253,8 @@ public class DriveTrain extends PIDSubsystem {
    */
   public void switchGear() {
     Value currentValue = getGearPistonValue();
-    Value setValue = (currentValue == Constants.DriveTrain.HIGH_GEAR) ? Constants.DriveTrain.LOW_GEAR
-        : Constants.DriveTrain.HIGH_GEAR;
+    Value setValue = (currentValue == Constants.DriveTrain.HIGH_GEAR)
+        ? Constants.DriveTrain.LOW_GEAR : Constants.DriveTrain.HIGH_GEAR;
     changeGear(setValue);
   }