Drivetrain smoother acceleration

This commit is contained in:
Evan
2020-01-17 16:59:48 -07:00
parent 442a7d8796
commit cd74d23b17
4 changed files with 71 additions and 6 deletions
@@ -15,6 +15,7 @@ import edu.wpi.first.wpilibj2.command.InstantCommand;
import edu.wpi.first.wpilibj2.command.RunCommand;
import edu.wpi.first.wpilibj2.command.button.JoystickButton;
import frc4388.robot.Constants.*;
import frc4388.robot.commands.DriveWithJoystick;
import frc4388.robot.commands.RunIntakeWithTriggers;
import frc4388.robot.subsystems.Drive;
import frc4388.robot.subsystems.Intake;
@@ -48,9 +49,7 @@ public class RobotContainer {
/* Default Commands */
// drives the robot with a two-axis input from the driver controller
m_robotDrive.setDefaultCommand(new RunCommand(() -> m_robotDrive.driveWithInput(
getDriverController().getLeftYAxis(),
getDriverController().getRightXAxis()), m_robotDrive));
m_robotDrive.setDefaultCommand(new DriveWithJoystick(m_robotDrive, getDriverController()));
// drives motor with input from triggers on the opperator controller
m_robotIntake.setDefaultCommand(new RunIntakeWithTriggers(m_robotIntake, getOperatorController()));
// continually sends updates to the Blinkin LED controller to keep the lights on