Skip to content

Commit

Permalink
add unit to rest + max pivot angle constants
Browse files Browse the repository at this point in the history
  • Loading branch information
GalexY727 committed Jan 25, 2024
1 parent 838f8ea commit f2339e5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
6 changes: 3 additions & 3 deletions src/main/java/frc/robot/subsystems/shooter/Pivot.java
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public void setAngle(double angle) {
/**
* TODO: Make gear ratio constant and put it here
*/
(angle / ShooterConstants.PIVOT_MAX_ANGLE)
(angle / ShooterConstants.PIVOT_MAX_ANGLE_DEGREES)
);
}

Expand All @@ -70,7 +70,7 @@ public Command setAngleCommand(double angle) {
* The function sets the pivot angle to the rest angle constant
*/
public void setRestAngle() {
this.setAngle(ShooterConstants.PIVOT_REST_ANGLE);
this.setAngle(ShooterConstants.PIVOT_REST_ANGLE_DEGREES);
}

/**
Expand All @@ -80,7 +80,7 @@ public void setRestAngle() {
* @return The method is returning a Command object.
*/
public Command setRestAngleCommand() {
return setAngleCommand(ShooterConstants.PIVOT_REST_ANGLE);
return setAngleCommand(ShooterConstants.PIVOT_REST_ANGLE_DEGREES);
}

/**
Expand Down
3 changes: 2 additions & 1 deletion src/main/java/frc/robot/util/Constants.java
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,8 @@ public static final class ShooterConstants {
public static final double PIVOT_MIN_OUTPUT = -1;
public static final double PIVOT_MAX_OUTPUT = 1;

public static final double PIVOT_MAX_ANGLE = 360.0;
public static final double PIVOT_MAX_ANGLE_DEGREES = 360.0;
public static final double PIVOT_REST_ANGLE_DEGREES = 10.0;

public static final double MEASUREMENT_INTERVAL_FEET = 1.0;
/**
Expand Down

0 comments on commit f2339e5

Please sign in to comment.