Added Goal and Trench Position Commands

Untested
This commit is contained in:
ryan123rudder
2020-03-10 20:23:32 -06:00
parent 713ab60c42
commit b55974b01c
3 changed files with 38 additions and 8 deletions
@@ -8,13 +8,22 @@
package frc4388.robot.commands.shooter;
import edu.wpi.first.wpilibj2.command.CommandBase;
import frc4388.robot.subsystems.Shooter;
import frc4388.robot.subsystems.ShooterAim;
import frc4388.robot.subsystems.ShooterHood;
public class ShooterTrenchPosition extends CommandBase {
Shooter m_shooter;
ShooterHood m_hood;
ShooterAim m_aim;
/**
* Creates a new ShooterTrenchPosition.
*/
public ShooterTrenchPosition() {
// Use addRequirements() here to declare subsystem dependencies.
public ShooterTrenchPosition(Shooter shooterSub, ShooterHood hoodSub, ShooterAim aimSub) {
m_shooter = shooterSub;
m_hood = hoodSub;
m_aim = aimSub;
addRequirements(m_shooter,m_hood,m_aim);
}
// Called when the command is initially scheduled.
@@ -25,6 +34,9 @@ public class ShooterTrenchPosition extends CommandBase {
// Called every time the scheduler runs while the command is scheduled.
@Override
public void execute() {
m_shooter.runDrumShooterVelocityPID(5000);
m_hood.runAngleAdjustPID(3);
m_aim.runshooterRotatePID(-26.5);
}
// Called once the command ends or is interrupted.