From dba0b9ad54f39b57668a6b62c64169fc9924e75a Mon Sep 17 00:00:00 2001 From: Cindy Zhang Date: Tue, 16 Feb 2016 10:50:57 -0800 Subject: [PATCH] undo previous commit --- .../commands/auton/DefaultAutonStrategy.java | 10 ++--- .../{PassLowBarTime.java => PassLowBar.java} | 6 +-- .../commands/auton/PassLowBarDistance.java | 37 ----------------- .../{PassMoatTime.java => PassMoat.java} | 4 +- .../commands/auton/PassMoatDistance.java | 41 ------------------- ...{PassRampartTime.java => PassRampart.java} | 4 +- .../commands/auton/PassRampartDistance.java | 40 ------------------ ...assRockWallTime.java => PassRockWall.java} | 15 ++----- .../commands/auton/PassRockWallDistance.java | 39 ------------------ ...TerrainTime.java => PassRoughTerrain.java} | 4 +- .../auton/PassRoughTerrainDistance.java | 41 ------------------- 11 files changed, 18 insertions(+), 223 deletions(-) rename src/org/usfirst/frc/team3501/robot/commands/auton/{PassLowBarTime.java => PassLowBar.java} (88%) mode change 100755 => 100644 delete mode 100644 src/org/usfirst/frc/team3501/robot/commands/auton/PassLowBarDistance.java rename src/org/usfirst/frc/team3501/robot/commands/auton/{PassMoatTime.java => PassMoat.java} (93%) mode change 100644 => 100755 delete mode 100755 src/org/usfirst/frc/team3501/robot/commands/auton/PassMoatDistance.java rename src/org/usfirst/frc/team3501/robot/commands/auton/{PassRampartTime.java => PassRampart.java} (91%) mode change 100644 => 100755 delete mode 100755 src/org/usfirst/frc/team3501/robot/commands/auton/PassRampartDistance.java rename src/org/usfirst/frc/team3501/robot/commands/auton/{PassRockWallTime.java => PassRockWall.java} (53%) mode change 100644 => 100755 delete mode 100755 src/org/usfirst/frc/team3501/robot/commands/auton/PassRockWallDistance.java rename src/org/usfirst/frc/team3501/robot/commands/auton/{PassRoughTerrainTime.java => PassRoughTerrain.java} (91%) mode change 100755 => 100644 delete mode 100644 src/org/usfirst/frc/team3501/robot/commands/auton/PassRoughTerrainDistance.java diff --git a/src/org/usfirst/frc/team3501/robot/commands/auton/DefaultAutonStrategy.java b/src/org/usfirst/frc/team3501/robot/commands/auton/DefaultAutonStrategy.java index 318de7c1..5b6453dd 100755 --- a/src/org/usfirst/frc/team3501/robot/commands/auton/DefaultAutonStrategy.java +++ b/src/org/usfirst/frc/team3501/robot/commands/auton/DefaultAutonStrategy.java @@ -22,10 +22,10 @@ public class DefaultAutonStrategy extends CommandGroup { addSequential(new PassSallyPort()); else if (defense == Constants.Defense.ROUGH_TERRAIN) - addSequential(new PassRoughTerrainTime()); + addSequential(new PassRoughTerrain()); else if (defense == Constants.Defense.LOW_BAR) - addSequential(new PassLowBarTime()); + addSequential(new PassLowBar()); else if (defense == Constants.Defense.CHEVAL_DE_FRISE) addSequential(new PassChevalDeFrise()); @@ -34,13 +34,13 @@ public class DefaultAutonStrategy extends CommandGroup { addSequential(new PassDrawBridge()); else if (defense == Constants.Defense.MOAT) - addSequential(new PassMoatDistance()); + addSequential(new PassMoat()); else if (defense == Constants.Defense.ROCK_WALL) - addSequential(new PassRockWallDistance()); + addSequential(new PassRockWall()); else if (defense == Constants.Defense.RAMPART) - addSequential(new PassRampartDistance()); + addSequential(new PassRampart()); addSequential(new AimAndAlign()); addSequential(new Shoot()); diff --git a/src/org/usfirst/frc/team3501/robot/commands/auton/PassLowBarTime.java b/src/org/usfirst/frc/team3501/robot/commands/auton/PassLowBar.java old mode 100755 new mode 100644 similarity index 88% rename from src/org/usfirst/frc/team3501/robot/commands/auton/PassLowBarTime.java rename to src/org/usfirst/frc/team3501/robot/commands/auton/PassLowBar.java index fde2ee40..cbdaeef6 --- a/src/org/usfirst/frc/team3501/robot/commands/auton/PassLowBarTime.java +++ b/src/org/usfirst/frc/team3501/robot/commands/auton/PassLowBar.java @@ -20,18 +20,18 @@ import edu.wpi.first.wpilibj.command.CommandGroup; * */ -public class PassLowBarTime extends CommandGroup { +public class PassLowBar extends CommandGroup { private final double DISTANCE = 4.0; private final double DEFAULT_SPEED = 0.5; - public PassLowBarTime() { + public PassLowBar() { // TODO: need to add sequential for retracting the arms and shooting hood // once those commands are made addSequential(new DriveDistance(DISTANCE, DEFAULT_SPEED)); } - public PassLowBarTime(double speed) { + public PassLowBar(double speed) { addSequential(new DriveDistance(DISTANCE, speed)); } } diff --git a/src/org/usfirst/frc/team3501/robot/commands/auton/PassLowBarDistance.java b/src/org/usfirst/frc/team3501/robot/commands/auton/PassLowBarDistance.java deleted file mode 100644 index ee69e2a9..00000000 --- a/src/org/usfirst/frc/team3501/robot/commands/auton/PassLowBarDistance.java +++ /dev/null @@ -1,37 +0,0 @@ -package org.usfirst.frc.team3501.robot.commands.auton; - -import org.usfirst.frc.team3501.robot.commands.driving.DriveDistance; - -import edu.wpi.first.wpilibj.command.CommandGroup; - -/*** - * This command will drive the robot through the low bar. - * - * dependency on sensors: encoders - * dependency on subsystems: drivetrain - * dependency on other commands: DriveForDist - * - * pre-condition: robot is flush against the ramp of the outerworks in front of - * the low bar - * - * post-condition: the robot has passed the low bar and is in the next zone - * - * @author Meryem and Avi - * - */ - -public class PassLowBarDistance extends CommandGroup { - - private final double DISTANCE = 4.0; - private final double DEFAULT_SPEED = 0.5; - - public PassLowBarDistance() { - // TODO: need to add sequential for retracting the arms and shooting hood - // once those commands are made - addSequential(new DriveDistance(DISTANCE, DEFAULT_SPEED)); - } - - public PassLowBarDistance(double speed) { - addSequential(new DriveDistance(DISTANCE, speed)); - } -} diff --git a/src/org/usfirst/frc/team3501/robot/commands/auton/PassMoatTime.java b/src/org/usfirst/frc/team3501/robot/commands/auton/PassMoat.java old mode 100644 new mode 100755 similarity index 93% rename from src/org/usfirst/frc/team3501/robot/commands/auton/PassMoatTime.java rename to src/org/usfirst/frc/team3501/robot/commands/auton/PassMoat.java index d46f015c..1f465d95 --- a/src/org/usfirst/frc/team3501/robot/commands/auton/PassMoatTime.java +++ b/src/org/usfirst/frc/team3501/robot/commands/auton/PassMoat.java @@ -23,7 +23,7 @@ import edu.wpi.first.wpilibj.command.CommandGroup; * */ -public class PassMoatTime extends CommandGroup { +public class PassMoat extends CommandGroup { private final double BEG_TIME = 0; private final double MID_TIME = 0; @@ -32,7 +32,7 @@ public class PassMoatTime extends CommandGroup { private final double MID_SPEED = 0; private final double END_SPEED = 0; - public PassMoatTime() { + public PassMoat() { addSequential(new DriveForTime(BEG_TIME, BEG_SPEED)); addSequential(new DriveForTime(MID_TIME, MID_SPEED)); addSequential(new DriveForTime(END_TIME, END_SPEED)); diff --git a/src/org/usfirst/frc/team3501/robot/commands/auton/PassMoatDistance.java b/src/org/usfirst/frc/team3501/robot/commands/auton/PassMoatDistance.java deleted file mode 100755 index 735e9710..00000000 --- a/src/org/usfirst/frc/team3501/robot/commands/auton/PassMoatDistance.java +++ /dev/null @@ -1,41 +0,0 @@ -package org.usfirst.frc.team3501.robot.commands.auton; - -import org.usfirst.frc.team3501.robot.commands.driving.DriveForTime; - -import edu.wpi.first.wpilibj.command.CommandGroup; - -/*** - * This command will drive the robot through the moat. - * - * The code drives the robot for a specific time at a specific speed up the ramp - * to the defense then drive over the defense at a different speed and time. - * - * dependency on subsystem: drivetrain - * - * dependency on other commands: DriveForTime - * - * pre-condition: robot is flush against the ramp of the outerworks in front of - * the moat - * - * post-condition: the robot has passed the moat and is in the next zone - * - * @author Meryem and Avi - * - */ - -public class PassMoatDistance extends CommandGroup { - - private final double BEG_TIME = 0; - private final double MID_TIME = 0; - private final double END_TIME = 0; - private final double BEG_SPEED = 0; - private final double MID_SPEED = 0; - private final double END_SPEED = 0; - - public PassMoatDistance() { - addSequential(new DriveForTime(BEG_TIME, BEG_SPEED)); - addSequential(new DriveForTime(MID_TIME, MID_SPEED)); - addSequential(new DriveForTime(END_TIME, END_SPEED)); - - } -} diff --git a/src/org/usfirst/frc/team3501/robot/commands/auton/PassRampartTime.java b/src/org/usfirst/frc/team3501/robot/commands/auton/PassRampart.java old mode 100644 new mode 100755 similarity index 91% rename from src/org/usfirst/frc/team3501/robot/commands/auton/PassRampartTime.java rename to src/org/usfirst/frc/team3501/robot/commands/auton/PassRampart.java index 582292e0..426063dc --- a/src/org/usfirst/frc/team3501/robot/commands/auton/PassRampartTime.java +++ b/src/org/usfirst/frc/team3501/robot/commands/auton/PassRampart.java @@ -20,9 +20,9 @@ import edu.wpi.first.wpilibj.command.CommandGroup; * */ -public class PassRampartTime extends CommandGroup { +public class PassRampart extends CommandGroup { - public PassRampartTime() { + public PassRampart() { final double BEG_TIME = 0; final double BEG_SPEED = 0; diff --git a/src/org/usfirst/frc/team3501/robot/commands/auton/PassRampartDistance.java b/src/org/usfirst/frc/team3501/robot/commands/auton/PassRampartDistance.java deleted file mode 100755 index 4ff3a85d..00000000 --- a/src/org/usfirst/frc/team3501/robot/commands/auton/PassRampartDistance.java +++ /dev/null @@ -1,40 +0,0 @@ -package org.usfirst.frc.team3501.robot.commands.auton; - -import org.usfirst.frc.team3501.robot.commands.driving.DriveForTime; - -import edu.wpi.first.wpilibj.command.CommandGroup; - -/*** - * This command will drive the robot through the rampart. - * - * dependency on subsystems: drivetrain - * - * dependency on other commands: DriveForTime - * - * pre-condition: robot is flush against the ramp of the outerworks in front of - * the rampart - * - * post-condition: the robot has passed the rampart and is in the next zone - * - * @author Meryem and Avi - * - */ - -public class PassRampartDistance extends CommandGroup { - - public PassRampartDistance() { - - final double BEG_TIME = 0; - final double BEG_SPEED = 0; - final double MID_TIME = 0; - final double MID_SPEED = 0; - final double END_TIME = 0; - final double END_SPEED = 0; - - addSequential(new DriveForTime(BEG_TIME, BEG_SPEED)); - addSequential(new DriveForTime(MID_TIME, MID_SPEED)); - addSequential(new DriveForTime(END_TIME, END_SPEED)); - - } - -} diff --git a/src/org/usfirst/frc/team3501/robot/commands/auton/PassRockWallTime.java b/src/org/usfirst/frc/team3501/robot/commands/auton/PassRockWall.java old mode 100644 new mode 100755 similarity index 53% rename from src/org/usfirst/frc/team3501/robot/commands/auton/PassRockWallTime.java rename to src/org/usfirst/frc/team3501/robot/commands/auton/PassRockWall.java index 05cfcc64..2839df3c --- a/src/org/usfirst/frc/team3501/robot/commands/auton/PassRockWallTime.java +++ b/src/org/usfirst/frc/team3501/robot/commands/auton/PassRockWall.java @@ -20,20 +20,13 @@ import edu.wpi.first.wpilibj.command.CommandGroup; * */ -public class PassRockWallTime extends CommandGroup { +public class PassRockWall extends CommandGroup { - private final double BEG_TIME = 0; - private final double MID_TIME = 0; - private final double END_TIME = 0; - private final double BEG_SPEED = 0; - private final double MID_SPEED = 0; - private final double END_SPEED = 0; + private final double time = 0, speed =0; - public PassRockWallTime() { + public PassRockWall() { - addSequential(new DriveForTime(BEG_TIME, BEG_SPEED)); - addSequential(new DriveForTime(MID_TIME, MID_SPEED)); - addSequential(new DriveForTime(END_TIME, END_SPEED)); + addSequential(new DriveForTime(time, speed)); } } diff --git a/src/org/usfirst/frc/team3501/robot/commands/auton/PassRockWallDistance.java b/src/org/usfirst/frc/team3501/robot/commands/auton/PassRockWallDistance.java deleted file mode 100755 index 08ca2c36..00000000 --- a/src/org/usfirst/frc/team3501/robot/commands/auton/PassRockWallDistance.java +++ /dev/null @@ -1,39 +0,0 @@ -package org.usfirst.frc.team3501.robot.commands.auton; - -import org.usfirst.frc.team3501.robot.commands.driving.DriveForTime; - -import edu.wpi.first.wpilibj.command.CommandGroup; - -/*** - * This command will drive the robot through the rock wall. - * - * dependency on subsystems: drivetrain - * - * dependency on other commands: DriveForTime - * - * pre-condition: robot is flush against the ramp of the outerworks in front of - * the rock wall - * - * post-condition: the robot has passed the rock wall and is in the next zone - * - * @author Meryem and Avi - * - */ - -public class PassRockWallDistance extends CommandGroup { - - private final double BEG_TIME = 0; - private final double MID_TIME = 0; - private final double END_TIME = 0; - private final double BEG_SPEED = 0; - private final double MID_SPEED = 0; - private final double END_SPEED = 0; - - public PassRockWallDistance() { - - addSequential(new DriveForTime(BEG_TIME, BEG_SPEED)); - addSequential(new DriveForTime(MID_TIME, MID_SPEED)); - addSequential(new DriveForTime(END_TIME, END_SPEED)); - - } -} diff --git a/src/org/usfirst/frc/team3501/robot/commands/auton/PassRoughTerrainTime.java b/src/org/usfirst/frc/team3501/robot/commands/auton/PassRoughTerrain.java old mode 100755 new mode 100644 similarity index 91% rename from src/org/usfirst/frc/team3501/robot/commands/auton/PassRoughTerrainTime.java rename to src/org/usfirst/frc/team3501/robot/commands/auton/PassRoughTerrain.java index 6bc6b223..8851edf6 --- a/src/org/usfirst/frc/team3501/robot/commands/auton/PassRoughTerrainTime.java +++ b/src/org/usfirst/frc/team3501/robot/commands/auton/PassRoughTerrain.java @@ -20,7 +20,7 @@ import edu.wpi.first.wpilibj.command.CommandGroup; * @author Meryem and Avi * */ -public class PassRoughTerrainTime extends CommandGroup { +public class PassRoughTerrain extends CommandGroup { // TODO: test for the time private final double BEG_TIME = 0; @@ -31,7 +31,7 @@ public class PassRoughTerrainTime extends CommandGroup { private final double MID_SPEED = 0; private final double END_SPEED = 0; - public PassRoughTerrainTime() { + public PassRoughTerrain() { addSequential(new DriveForTime(BEG_TIME, BEG_SPEED)); addSequential(new DriveForTime(MID_TIME, MID_SPEED)); diff --git a/src/org/usfirst/frc/team3501/robot/commands/auton/PassRoughTerrainDistance.java b/src/org/usfirst/frc/team3501/robot/commands/auton/PassRoughTerrainDistance.java deleted file mode 100644 index 97289947..00000000 --- a/src/org/usfirst/frc/team3501/robot/commands/auton/PassRoughTerrainDistance.java +++ /dev/null @@ -1,41 +0,0 @@ -package org.usfirst.frc.team3501.robot.commands.auton; - -import org.usfirst.frc.team3501.robot.commands.driving.DriveForTime; - -import edu.wpi.first.wpilibj.command.CommandGroup; - -/*** - * This command will drive the robot through the rough terrain. - * - * dependency on subsytems: drivetrain - * - * dependency on other commands: DriveForTime - * - * pre-condition: robot is flush against the ramp of the outerworks in front of - * the rough terrain - * - * post-condition: the robot has passed the rough terrain and is in the next - * zone - * - * @author Meryem and Avi - * - */ -public class PassRoughTerrainDistance extends CommandGroup { - - // TODO: test for the time - private final double BEG_TIME = 0; - private final double MID_TIME = 0; - private final double END_TIME = 0; - - private final double BEG_SPEED = 0; - private final double MID_SPEED = 0; - private final double END_SPEED = 0; - - public PassRoughTerrainDistance() { - - addSequential(new DriveForTime(BEG_TIME, BEG_SPEED)); - addSequential(new DriveForTime(MID_TIME, MID_SPEED)); - addSequential(new DriveForTime(END_TIME, BEG_SPEED)); - - } -} -- 2.30.2