@@ -27,10 +27,10 @@ public class Coral extends SubsystemBase {
2727
2828 // rotations for levels
2929 private Rotation2d [] coralScoringRotations = {
30- Rotation2d .fromDegrees ( 60 ),
31- Rotation2d .fromRadians (5.97 ),
32- Rotation2d .fromRadians (6.02 ),
33- Rotation2d .fromDegrees ( 64.0 )
30+ Rotation2d .fromRadians ( 1 ),
31+ Rotation2d .fromRadians (1.7 ),
32+ Rotation2d .fromRadians (1.7 ),
33+ Rotation2d .fromRadians ( 0.3 )
3434 };
3535 private Rotation2d [] reefClearRotationsPrimary = {
3636 Rotation2d .fromDegrees (-35 ), Rotation2d .fromDegrees (-35 )
@@ -44,7 +44,7 @@ public Coral() {
4444 movementController .setTolerance (CoralConfig .POSITION_TOLERANCE , CoralConfig .VELOCITY_TOLERANCE );
4545 movementController .enableContinuousInput (-Math .PI , Math .PI );
4646 elevator .setDefaultCommand (elevator .setElevatorHeight (() -> 0.0 ));
47- coralPivot .setDefaultCommand (coralPivot .setPivotAngle (() -> Rotation2d .fromDegrees ( 75 )));
47+ coralPivot .setDefaultCommand (coralPivot .setPivotAngle (() -> Rotation2d .fromRadians ( 0.35 )));
4848 grabber .setDefaultCommand (
4949 Commands .run (
5050 () -> {
@@ -62,6 +62,7 @@ private Command score(int idx, BooleanSupplier completeScore) {
6262 return Commands .waitSeconds (0.3 )
6363 .andThen (coralPivot .setPivotAngle (() -> coralScoringRotations [idx ]))
6464 .alongWith (elevator .setElevatorHeight (() -> elevatorScoringHeights [idx ]))
65+ .alongWith (Commands .run (grabber ::run , grabber ))
6566 .withDeadline (
6667 Commands .waitUntil (elevator ::isAtPosition )
6768 .andThen (Commands .waitUntil (coralPivot ::isPivotReady ), Commands .waitSeconds (0.8 ))
@@ -111,7 +112,7 @@ public Command l4Score(BooleanSupplier completeScore, boolean shouldHaveAutoTime
111112 if (elevator .getPosition () > 1.0 || shouldComplete ) {
112113 return coralScoringRotations [3 ];
113114 } else {
114- return coralScoringRotations [3 ].minus (Rotation2d .fromDegrees (15 ));
115+ return coralScoringRotations [3 ].plus (Rotation2d .fromDegrees (15 ));
115116 }
116117 })
117118 .alongWith (
0 commit comments