generated from StuyPulse/Phil
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #30 from StuyPulse/8-14
- Loading branch information
Showing
10 changed files
with
139 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
src/main/java/com/stuypulse/robot/commands/intake/IntakeShoot.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package com.stuypulse.robot.commands.intake; | ||
|
||
import com.stuypulse.robot.constants.Settings; | ||
import com.stuypulse.robot.subsystems.intake.Intake; | ||
|
||
import edu.wpi.first.wpilibj2.command.InstantCommand; | ||
import edu.wpi.first.wpilibj2.command.SequentialCommandGroup; | ||
import edu.wpi.first.wpilibj2.command.WaitCommand; | ||
|
||
public class IntakeShoot extends SequentialCommandGroup { | ||
|
||
public IntakeShoot() { | ||
addCommands( | ||
new InstantCommand(() -> Intake.getInstance().setState(Intake.State.SHOOTING), Intake.getInstance()), | ||
new WaitCommand(Settings.Intake.INTAKE_SHOOT_TIME), | ||
new IntakeStop() | ||
); | ||
} | ||
} |
25 changes: 25 additions & 0 deletions
25
src/main/java/com/stuypulse/robot/commands/shooter/ShooterManualIntake.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
package com.stuypulse.robot.commands.shooter; | ||
|
||
import com.stuypulse.robot.subsystems.shooter.Shooter; | ||
|
||
import edu.wpi.first.wpilibj2.command.Command; | ||
|
||
public class ShooterManualIntake extends Command{ | ||
|
||
private final Shooter shooter; | ||
|
||
public ShooterManualIntake() { | ||
shooter = Shooter.getInstance(); | ||
addRequirements(shooter); | ||
} | ||
|
||
@Override | ||
public void initialize() { | ||
shooter.feederIntake(); | ||
} | ||
|
||
@Override | ||
public void end(boolean interrupted) { | ||
shooter.feederStop(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.