mid final changes

This commit is contained in:
Luke Staudacher
2018-03-11 19:36:43 -05:00
parent b59a6672b3
commit 308d7f3436
10 changed files with 56 additions and 21 deletions
+4 -4
View File
@@ -127,7 +127,7 @@ public class Robot extends IterativeRobot
RRautonTaskChooser.addObject("Left to Right Switch", new LeftStartRightScore());
RRautonTaskChooser.addObject("Center to Right Switch", new CenterRight());
RRautonTaskChooser.addObject("Center to Right 2 cube", new CenterRight2Cube());
//RRautonTaskChooser.addObject("Center to Right 2 cube", new CenterRight2Cube());
RRautonTaskChooser.addObject("Right to Right Switch", new RightSwitchAuton());
RRautonTaskChooser.addObject("Right to Right Scale", new ScaleFrom3());
@@ -148,7 +148,7 @@ public class Robot extends IterativeRobot
RLautonTaskChooser.addObject("Left to Left Scale", new ScaleFrom1());
RLautonTaskChooser.addObject("Center to Right Switch", new CenterRight());
RLautonTaskChooser.addObject("Center to Right 2 cube", new CenterRight2Cube());
//RLautonTaskChooser.addObject("Center to Right 2 cube", new CenterRight2Cube());
RLautonTaskChooser.addObject("Right to Right Switch", new RightSwitchAuton());
@@ -169,7 +169,7 @@ public class Robot extends IterativeRobot
LLautonTaskChooser.addObject("Center to Left Switch", new CenterLeft());
LLautonTaskChooser.addObject("Center to Left Switch 2 cube", new CenterLeft2Cube());
//LLautonTaskChooser.addObject("Center to Left Switch 2 cube", new CenterLeft2Cube());
LLautonTaskChooser.addObject("Right to Left Switch", new RightStartLeftScore());
@@ -185,7 +185,7 @@ public class Robot extends IterativeRobot
LRautonTaskChooser.addObject("Left to Left Switch", new LeftSwitchAuton());
LRautonTaskChooser.addObject("Center to Left Switch", new CenterLeft());
LRautonTaskChooser.addObject("Center to Left Switch 2 cube", new CenterLeft2Cube());
//LRautonTaskChooser.addObject("Center to Left Switch 2 cube", new CenterLeft2Cube());
LRautonTaskChooser.addObject("Right to Left Switch", new RightStartLeftScore());
LRautonTaskChooser.addObject("Right To Right Scale", new ScaleFrom3());
@@ -25,6 +25,7 @@ public class CenterLeft extends CommandGroup {
public CenterLeft()
{
addSequential(new DriveGyroReset());
addSequential(new WaitCommand(.2));
addSequential(new IntakePosition(true));
addSequential(new DriveSpeedShift(true));
@@ -33,19 +34,20 @@ public class CenterLeft extends CommandGroup {
addSequential(new WaitCommand(.2));
addSequential(new DriveStraightBasic(80, 45, true, true, 0));
addSequential(new ElevatorBasic(30));
addSequential(new DriveTurnBasic(true, 12, 150, MPSoftwareTurnType.TANK));
addSequential(new DriveTurnBasic(true, 28, 150, MPSoftwareTurnType.TANK));
addParallel(new TimeoutBecaseYea());
addSequential(new DriveStraightBasic(12, 45, true, true, 0));
//addParallel(new TimeoutBecaseYea());
//addSequential(new WaitCommand(3));
addSequential(new WaitCommand(3));
/*
addSequential(new IntakeSetSpeed(Carriage.CUBE_EJECT_SPEED));
//addSequential(new WaitCommand(.1));
addSequential(new IntakePosition(false));
addSequential(new WaitCommand(.2));
addSequential(new IntakeSetSpeed(Carriage.CUBE_STOP_SPEED));
*/
@@ -36,6 +36,7 @@ public class CenterRight extends CommandGroup {
addSequential(new DriveTurnBasic(true, -35, 150, MPSoftwareTurnType.TANK));
addParallel(new TimeoutBecaseYea());
addSequential(new DriveStraightBasic(25, 45, true, true, 0));
//addParallel(new TimeoutBecaseYea());
addSequential(new WaitCommand(3));
@@ -40,13 +40,20 @@ public class LeftStartRightScore extends CommandGroup {
addSequential(new WaitCommand(.2));
addSequential(new DriveTurnBasic(true, 73, 150, MPSoftwareTurnType.TANK));
addSequential(new WaitCommand(.2));
addParallel(new TimeoutBecaseYea());
addSequential(new DriveStraightBasic(10, 60, true, true, 0));
addSequential(new IntakeSetSpeed(Carriage.CUBE_EJECT_SPEED));
addSequential(new WaitCommand(3));
/*addSequential(new IntakeSetSpeed(Carriage.CUBE_EJECT_SPEED));
//addSequential(new WaitCommand(.1));
addSequential(new IntakePosition(false));
addSequential(new DriveStraightBasic(5, 60, true, true, 0));
addSequential(new WaitCommand(.2));
addSequential(new IntakeSetSpeed(Carriage.CUBE_STOP_SPEED));
addSequential(new IntakeSetSpeed(Carriage.CUBE_STOP_SPEED));*/
addSequential(new DriveStraightBasic(-15, 60, true, true, 0));
addSequential(new DriveSpeedShift(false));
@@ -24,6 +24,7 @@ public class LeftSwitchAuton extends CommandGroup {
public LeftSwitchAuton() {
addSequential(new DriveGyroReset());
addSequential(new WaitCommand(.2));
addSequential(new DriveSpeedShift(true));
addSequential(new IntakePosition(true));
@@ -32,7 +33,12 @@ public class LeftSwitchAuton extends CommandGroup {
addSequential(new ElevatorBasic(30));
addSequential(new DriveTurnBasic(true, -87, 150, MPSoftwareTurnType.TANK));
addSequential(new ElevatorBasic(30));
addParallel(new TimeoutBecaseYea());
addSequential(new DriveStraightBasic(20, 50, true, true, 0));
addSequential(new WaitCommand(3));
/*
addSequential(new IntakeSetSpeed(Carriage.CUBE_EJECT_SPEED));
//addSequential(new WaitCommand(.1));
addSequential(new IntakePosition(false));
@@ -40,7 +46,7 @@ public class LeftSwitchAuton extends CommandGroup {
addSequential(new IntakeSetSpeed(Carriage.CUBE_STOP_SPEED));
addSequential(new DriveStraightBasic(-20, 50, true, true, 0));
addSequential(new DriveSpeedShift(false));
*/
//addSequential(new DriveStraightMP(50, 10, true, true, 0)); // 95 for 112" greenville
}
@@ -39,14 +39,22 @@ public class RightStartLeftScore extends CommandGroup {
addSequential(new ElevatorBasic(30));
addSequential(new WaitCommand(.2));
addSequential(new DriveTurnBasic(true, -73, 150, MPSoftwareTurnType.TANK));
addSequential(new WaitCommand(.2));
addParallel(new TimeoutBecaseYea());
addSequential(new DriveStraightBasic(10, 60, true, true, 0));
addSequential(new WaitCommand(3));
/*
addSequential(new IntakeSetSpeed(Carriage.CUBE_EJECT_SPEED));
//addSequential(new WaitCommand(.1));
addSequential(new IntakePosition(false));
addSequential(new DriveStraightBasic(5, 60, true, true, 0));
addSequential(new WaitCommand(.2));
addSequential(new IntakeSetSpeed(Carriage.CUBE_STOP_SPEED));
*/
addSequential(new DriveStraightBasic(-15, 60, true, true, 0));
addSequential(new DriveSpeedShift(false));
@@ -33,12 +33,15 @@ public class RightSwitchAuton extends CommandGroup {
addSequential(new WaitCommand(.2));
addSequential(new DriveTurnBasic(true, 87, 150, MPSoftwareTurnType.TANK));
addSequential(new ElevatorBasic(30));
addSequential(new DriveStraightBasic(8, 50, true, true, 0));
addSequential(new IntakeSetSpeed(Carriage.CUBE_EJECT_SPEED));
addParallel(new TimeoutBecaseYea());
addSequential(new DriveStraightBasic(10, 50, true, true, 0));
/*addSequential(new IntakeSetSpeed(Carriage.CUBE_EJECT_SPEED));
//addSequential(new WaitCommand(.1));
addSequential(new IntakePosition(false));
addSequential(new WaitCommand(.5));
addSequential(new IntakeSetSpeed(Carriage.CUBE_STOP_SPEED));
addSequential(new IntakeSetSpeed(Carriage.CUBE_STOP_SPEED));*/
addSequential(new WaitCommand(3));
addSequential(new DriveStraightBasic(-20, 50, true, true, 0));
addSequential(new DriveSpeedShift(false));
@@ -24,25 +24,32 @@ public class ScaleFrom1 extends CommandGroup {
public ScaleFrom1() {
addSequential(new DriveGyroReset());
addSequential(new WaitCommand(.2));
addSequential(new DriveSpeedShift(true));
addSequential(new IntakePosition(true));
addSequential(new DriveStraightBasic(-10, 45, true, true, 0));
//addSequential(new DriveStraightBasic(-10, 50, true, true, 0));
addSequential(new DriveStraightBasic(-270, 45, true, true, 0));
addSequential(new ElevatorBasic(70));
addSequential(new DriveStraightBasic(-280, 65, true, true, 0));
addSequential(new ElevatorBasic(75));
addSequential(new DriveStraightBasic(-30, 20, true, true, 0));
addSequential(new DriveTurnBasic(true, -90, 100, MPSoftwareTurnType.TANK));
addSequential(new DriveTurnBasic(true, -80, 100, MPSoftwareTurnType.TANK));
//addSequential(new DriveStraightBasic(5, 20, true, true, 0));
addSequential(new WaitCommand(.5));
addSequential(new DriveStraightBasic(15, 25, true, true, 0));
addSequential(new IntakeSetSpeed(Carriage.CUBE_EJECT_SPEED));
//addSequential(new WaitCommand(.1));
addSequential(new IntakePosition(false));
addSequential(new WaitCommand(.5));
addSequential(new IntakeSetSpeed(Carriage.CUBE_STOP_SPEED));
addSequential(new DriveStraightBasic(-25, 20, true, true, 0));
addSequential(new DriveStraightBasic(-20, 20, true, true, 0));
addSequential(new ElevatorBasic(10));
addSequential(new DriveTurnBasic(true, 85, 100, MPSoftwareTurnType.TANK));
addSequential(new DriveStraightBasic(70, 20, true, true, 0));
addSequential(new DriveSpeedShift(false));
@@ -24,6 +24,7 @@ public class ScaleFrom3 extends CommandGroup {
public ScaleFrom3() {
addSequential(new DriveGyroReset());
addSequential(new WaitCommand(.2));
addSequential(new DriveSpeedShift(true));
addSequential(new IntakePosition(true));
@@ -51,7 +51,7 @@ public class Climber extends Subsystem{
public void setClimbSpeed(boolean Climb) {
if (Climb==true) {
Climber.set(0.95);
Climber.set(1.0);
}
if (Climb==false) {
Climber.set(0);