X-Git-Url: http://challenge-bot.com/repos/?p=3501%2F2017steamworks;a=blobdiff_plain;f=src%2Forg%2Fusfirst%2Ffrc%2Fteam3501%2Frobot%2Fcommands%2Fdriving%2FShiftDriveLowGear.java;fp=src%2Forg%2Fusfirst%2Ffrc%2Fteam3501%2Frobot%2Fcommands%2Fdriving%2FShiftDriveLowGear.java;h=fbc3e566dfaa75fa4da5254832a8a6d7bf35445c;hp=0000000000000000000000000000000000000000;hb=8275a069e1891bd27156dcd947a897519c42a3a3;hpb=ba9f0b126afd5973b11a22dd6640d8d6f0822f5a diff --git a/src/org/usfirst/frc/team3501/robot/commands/driving/ShiftDriveLowGear.java b/src/org/usfirst/frc/team3501/robot/commands/driving/ShiftDriveLowGear.java new file mode 100644 index 0000000..fbc3e56 --- /dev/null +++ b/src/org/usfirst/frc/team3501/robot/commands/driving/ShiftDriveLowGear.java @@ -0,0 +1,43 @@ +package org.usfirst.frc.team3501.robot.commands.driving; + +import org.usfirst.frc.team3501.robot.Robot; +import org.usfirst.frc.team3501.robot.subsystems.DriveTrain; + +import edu.wpi.first.wpilibj.command.Command; + +/** + * This command shifts the gear to high + * + * Author: Rohan Rodrigues + */ +public class ShiftDriveLowGear extends Command { + DriveTrain driveTrain = Robot.getDriveTrain(); + + public ShiftDriveLowGear() { + requires(driveTrain); + } + + @Override + protected void initialize() { + + } + + @Override + protected void execute() { + driveTrain.setLowGear(); + System.out.println("Current Value is: " + driveTrain.getLeftMotorVal()); + } + + @Override + protected boolean isFinished() { + return true; + } + + @Override + protected void end() { + } + + @Override + protected void interrupted() { + } +}