From 1755df3186e0c7c25a73f887eff936d32b47608a Mon Sep 17 00:00:00 2001 From: Arunima DIvya Date: Wed, 25 Jan 2017 20:39:24 -0800 Subject: [PATCH] Delete copies of methods, and change initialize code in runIntakeContinuous and runReverseIntakeContinuous --- src/org/usfirst/frc/team3501/robot/Constants.java | 7 ------- src/org/usfirst/frc/team3501/robot/Robot.java | 11 ----------- .../team3501/robot/commands/climber/StopWinch.java | 1 - .../commands/intake/ReverseIntakeContinuous.java | 4 +--- .../robot/commands/intake/RunIntakeContinuous.java | 4 ++-- 5 files changed, 3 insertions(+), 24 deletions(-) diff --git a/src/org/usfirst/frc/team3501/robot/Constants.java b/src/org/usfirst/frc/team3501/robot/Constants.java index 0c4880e..ee9e726 100644 --- a/src/org/usfirst/frc/team3501/robot/Constants.java +++ b/src/org/usfirst/frc/team3501/robot/Constants.java @@ -23,13 +23,6 @@ public class Constants { public final static int TOGGLE_FLYWHEEL_PORT = 0; public final static int TOGGLE_INDEXWHEEL_PORT = 0; - - } - - public static class Shooter { - // MOTOR CONTROLLERS - public static final int FLY_WHEEL = 0; - public static final int INDEX_WHEEL = 0; } public static class DriveTrain { diff --git a/src/org/usfirst/frc/team3501/robot/Robot.java b/src/org/usfirst/frc/team3501/robot/Robot.java index 63a11d0..c2e4f99 100644 --- a/src/org/usfirst/frc/team3501/robot/Robot.java +++ b/src/org/usfirst/frc/team3501/robot/Robot.java @@ -12,8 +12,6 @@ public class Robot extends IterativeRobot { private static DriveTrain driveTrain; private static Shooter shooter; private static OI oi; - private static Shooter shooter; - private static OI oi; private static Intake intake; @Override @@ -36,19 +34,10 @@ public class Robot extends IterativeRobot { return OI.getOI(); } - public static OI getOI() { - return OI.getOI(); - } - public static Intake getIntake() { return Intake.getIntake(); } - public static Intake getIntake() { - return Intake.getIntake(); - - } - @Override public void autonomousInit() { Scheduler.getInstance().add(new TimeDrive(1.5, 0.4)); 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 0924614..597bd65 100644 --- a/src/org/usfirst/frc/team3501/robot/commands/climber/StopWinch.java +++ b/src/org/usfirst/frc/team3501/robot/commands/climber/StopWinch.java @@ -14,7 +14,6 @@ public class StopWinch extends Command { public StopWinch() { requires(Robot.getDriveTrain()); - requires(Robot.getClimber()); } @Override diff --git a/src/org/usfirst/frc/team3501/robot/commands/intake/ReverseIntakeContinuous.java b/src/org/usfirst/frc/team3501/robot/commands/intake/ReverseIntakeContinuous.java index f387112..a75a4bb 100644 --- a/src/org/usfirst/frc/team3501/robot/commands/intake/ReverseIntakeContinuous.java +++ b/src/org/usfirst/frc/team3501/robot/commands/intake/ReverseIntakeContinuous.java @@ -18,14 +18,12 @@ public class ReverseIntakeContinuous extends Command { // Called just before this Command runs the first time @Override protected void initialize() { - Robot.getIntake().runReverseIntake(); - } // Called repeatedly when this Command is scheduled to run @Override protected void execute() { - + Robot.getIntake().runReverseIntake(); } // Make this return true when this Command no longer needs to run execute() diff --git a/src/org/usfirst/frc/team3501/robot/commands/intake/RunIntakeContinuous.java b/src/org/usfirst/frc/team3501/robot/commands/intake/RunIntakeContinuous.java index efcd4d7..3188fe6 100644 --- a/src/org/usfirst/frc/team3501/robot/commands/intake/RunIntakeContinuous.java +++ b/src/org/usfirst/frc/team3501/robot/commands/intake/RunIntakeContinuous.java @@ -30,13 +30,13 @@ public class RunIntakeContinuous extends Command { // Called just before this Command runs the first time @Override protected void initialize() { - Robot.getIntake().runIntake(); + } // Called repeatedly when this Command is scheduled to run @Override protected void execute() { - + Robot.getIntake().runIntake(); } // Called once after isFinished returns true -- 2.30.2