change variables 'left' and 'right' that store joystick values to 'thrust' and 'twist'
[3501/2017steamworks] / src / org / usfirst / frc / team3501 / robot / subsystems / DriveTrain.java
index acb1a85ab257681c5b13e74db681ff857da3ce25..4bbda0fb1168a8ef9e490d356c771e5f08626779 100644 (file)
@@ -1,8 +1,10 @@
 package org.usfirst.frc.team3501.robot.subsystems;
 
 import org.usfirst.frc.team3501.robot.Constants;
+import org.usfirst.frc.team3501.robot.commands.driving.JoystickDrive;
+
+import com.ctre.CANTalon;
 
-import edu.wpi.first.wpilibj.CANTalon;
 import edu.wpi.first.wpilibj.Encoder;
 import edu.wpi.first.wpilibj.RobotDrive;
 import edu.wpi.first.wpilibj.command.Subsystem;
@@ -45,8 +47,8 @@ public class DriveTrain extends Subsystem {
     robotDrive.tankDrive(left, right);
   }
 
-  public void joystickDrive(final double left, final double right) {
-    robotDrive.tankDrive(left, right);
+  public void joystickDrive(final double thrust, final double twist) {
+    robotDrive.arcadeDrive(thrust, twist);
   }
 
   public void stop() {
@@ -118,6 +120,7 @@ public class DriveTrain extends Subsystem {
 
   @Override
   protected void initDefaultCommand() {
+    setDefaultCommand(new JoystickDrive());
   }
 
 }