-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'auto-testing' of https://github.com/FRC-Team-620/Warbot…
…s2024 into auto-testing
- Loading branch information
Showing
2 changed files
with
30 additions
and
0 deletions.
There are no files selected for viewing
27 changes: 27 additions & 0 deletions
27
src/main/java/org/jmhsrobotics/frc2024/ComboCommands/AmpHelper.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,27 @@ | ||
package org.jmhsrobotics.frc2024.ComboCommands; | ||
|
||
import org.jmhsrobotics.frc2024.subsystems.arm.ArmPIDSubsystem; | ||
import org.jmhsrobotics.frc2024.subsystems.arm.commands.ArmSetAmpCommand; | ||
import org.jmhsrobotics.frc2024.subsystems.intake.IntakeSubsystem; | ||
import org.jmhsrobotics.frc2024.subsystems.intake.commands.IntakeCommand; | ||
import org.jmhsrobotics.frc2024.subsystems.shooter.ShooterSubsystem; | ||
import org.jmhsrobotics.frc2024.subsystems.shooter.commands.ShootOpenLoopCommand; | ||
|
||
import edu.wpi.first.wpilibj2.command.ParallelCommandGroup; | ||
import edu.wpi.first.wpilibj2.command.SequentialCommandGroup; | ||
|
||
public class AmpHelper extends SequentialCommandGroup { | ||
private ArmPIDSubsystem armPIDSubsystem; | ||
private ShooterSubsystem shooterSubsystem; | ||
private IntakeSubsystem intakeSubsystem; | ||
|
||
public AmpHelper(ArmPIDSubsystem armPIDSubsystemm, ShooterSubsystem shooterSubsystem, | ||
IntakeSubsystem intakeSubsystem) { | ||
this.intakeSubsystem = intakeSubsystem; | ||
this.shooterSubsystem = shooterSubsystem; | ||
this.armPIDSubsystem = armPIDSubsystem; | ||
|
||
addCommands(new ArmSetAmpCommand(this.armPIDSubsystem), new ShootOpenLoopCommand(1, this.shooterSubsystem).withTimeout(0.5), | ||
new IntakeCommand(0.8, this.intakeSubsystem, this.shooterSubsystem)); | ||
} | ||
} |
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