-
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.
- Loading branch information
Showing
8 changed files
with
106 additions
and
11 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
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
27 changes: 27 additions & 0 deletions
27
src/main/java/frc/robot/commands/Positions/ShootClose.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 frc.robot.commands.Positions; | ||
|
||
import edu.wpi.first.wpilibj2.command.Command; | ||
import edu.wpi.first.wpilibj2.command.Commands; | ||
import frc.robot.subsystems.arm.Arm; | ||
import frc.robot.subsystems.armElevator.ArmElevator; | ||
import frc.robot.subsystems.wrist.Wrist; | ||
|
||
public class ShootClose { // bumper pressed against the wall | ||
|
||
public static Command run(Arm arm, ArmElevator armElevator, Wrist wrist) { | ||
return Commands.run( | ||
() -> { | ||
// Position preset settings | ||
double ARMANGLE = 0.4342; | ||
double ARMELEVATORPOSITION = 0; | ||
double WRISTANGLE = 0; | ||
|
||
arm.runTargetAngle(ARMANGLE); | ||
armElevator.runTargetPosition(ARMELEVATORPOSITION); | ||
wrist.runTargetAngle(WRISTANGLE); | ||
}, | ||
arm, | ||
armElevator, | ||
wrist); | ||
} | ||
} |
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 frc.robot.commands.Positions; | ||
|
||
import edu.wpi.first.wpilibj2.command.Command; | ||
import edu.wpi.first.wpilibj2.command.Commands; | ||
import frc.robot.subsystems.arm.Arm; | ||
import frc.robot.subsystems.armElevator.ArmElevator; | ||
import frc.robot.subsystems.wrist.Wrist; | ||
|
||
public class ShootFar { // two robots away from wall | ||
|
||
public static Command run(Arm arm, ArmElevator armElevator, Wrist wrist) { | ||
return Commands.run( | ||
() -> { | ||
// Position preset settings | ||
double ARMANGLE = 0.7917; | ||
double ARMELEVATORPOSITION = 0; | ||
double WRISTANGLE = 0; | ||
|
||
arm.runTargetAngle(ARMANGLE); | ||
armElevator.runTargetPosition(ARMELEVATORPOSITION); | ||
wrist.runTargetAngle(WRISTANGLE); | ||
}, | ||
arm, | ||
armElevator, | ||
wrist); | ||
} | ||
} |
27 changes: 27 additions & 0 deletions
27
src/main/java/frc/robot/commands/Positions/ShootMedium.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 frc.robot.commands.Positions; | ||
|
||
import edu.wpi.first.wpilibj2.command.Command; | ||
import edu.wpi.first.wpilibj2.command.Commands; | ||
import frc.robot.subsystems.arm.Arm; | ||
import frc.robot.subsystems.armElevator.ArmElevator; | ||
import frc.robot.subsystems.wrist.Wrist; | ||
|
||
public class ShootMedium { // one robot length away | ||
|
||
public static Command run(Arm arm, ArmElevator armElevator, Wrist wrist) { | ||
return Commands.run( | ||
() -> { | ||
// Position preset settings | ||
double ARMANGLE = 0.6429; | ||
double ARMELEVATORPOSITION = 0; | ||
double WRISTANGLE = 0; | ||
|
||
arm.runTargetAngle(ARMANGLE); | ||
armElevator.runTargetPosition(ARMELEVATORPOSITION); | ||
wrist.runTargetAngle(WRISTANGLE); | ||
}, | ||
arm, | ||
armElevator, | ||
wrist); | ||
} | ||
} |