diff options
author | kartofen <mladenovnasko0@gmail.com> | 2024-03-08 10:55:54 +0200 |
---|---|---|
committer | kartofen <mladenovnasko0@gmail.com> | 2024-03-08 10:55:54 +0200 |
commit | 01d6a7ef435dd9f6835fc3916a7f623395288490 (patch) | |
tree | d47bf6478e4b76009948b932cd86e4d49b56c267 /src/main/java/frc/robot/commands | |
parent | 4452529be059c5fbe4aaf9190f25cfc734715f01 (diff) |
changes
Diffstat (limited to 'src/main/java/frc/robot/commands')
-rw-r--r-- | src/main/java/frc/robot/commands/IntakeIntermediate.java | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/src/main/java/frc/robot/commands/IntakeIntermediate.java b/src/main/java/frc/robot/commands/IntakeIntermediate.java new file mode 100644 index 0000000..e8ea7ee --- /dev/null +++ b/src/main/java/frc/robot/commands/IntakeIntermediate.java @@ -0,0 +1,32 @@ +package frc.robot.commands; + +import edu.wpi.first.wpilibj2.command.Command; +import frc.robot.subsystems.Arm; +import frc.robot.subsystems.Chain; + +public class IntakeIntermediate extends Command +{ + public Arm m_arm; + public Chain m_chain; + + public IntakeIntermediate(Arm arm, Chain chain) + { + m_arm = arm; + m_chain = chain; + + addRequirements(arm, chain); + } + + @Override + public void execute() + { + m_arm.atAngleDegrees(-10); + m_chain.atPercentage(1); + } + + @Override + public boolean isFinished() + { + return m_arm.isAtAngleDegree(-10) && m_chain.isAtPosition(1); + } +} |