X-Git-Url: http://challenge-bot.com/repos/?a=blobdiff_plain;f=src%2Forg%2Fusfirst%2Ffrc%2Fteam3501%2Frobot%2Fcommands%2Fclimber%2FStopWinch.java;h=2bb575280e2a07100523795efd242104bc140a4c;hb=refs%2Fheads%2Fmaster;hp=a119c91a8d9967f47c63bc21dfe099d7d5da8243;hpb=ad877a7e56c5f471d2518c984a5e965c60b58a79;p=3501%2F2017steamworks diff --git a/src/org/usfirst/frc/team3501/robot/commands/climber/StopWinch.java b/src/org/usfirst/frc/team3501/robot/commands/climber/StopWinch.java index a119c91..2bb5752 100644 --- a/src/org/usfirst/frc/team3501/robot/commands/climber/StopWinch.java +++ b/src/org/usfirst/frc/team3501/robot/commands/climber/StopWinch.java @@ -1,24 +1,21 @@ package org.usfirst.frc.team3501.robot.commands.climber; import org.usfirst.frc.team3501.robot.Robot; +import org.usfirst.frc.team3501.robot.subsystems.Climber; import edu.wpi.first.wpilibj.command.Command; /** - * This command stops the winch - * - * post-condition: the motor values are set to 0. + * Stops the winch * * @author shivanighanta * */ public class StopWinch extends Command { - /** - * - */ - public StopWinch() { - requires(Robot.getClimber()); + Climber climber = Robot.getClimber(); + public StopWinch() { + requires(climber); } @Override @@ -36,8 +33,8 @@ public class StopWinch extends Command { @Override protected void end() { - Robot.getClimber().stop(); - + climber.stop(); + climber.setCANTalonsBrakeMode(climber.BRAKE_MODE); } @Override