Skip to content

[Feature] Linear Interpolation (super simple)#13

Open
Tortuga-AM wants to merge 4 commits intomainfrom
Linear-Interpolation
Open

[Feature] Linear Interpolation (super simple)#13
Tortuga-AM wants to merge 4 commits intomainfrom
Linear-Interpolation

Conversation

@Tortuga-AM
Copy link
Contributor

No description provided.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces basic linear interpolation for the shooter and hood setpoints. Key changes include:

  • Updating the shooter control call from calculate() to calculateWithVelocities().
  • Adding a new constant (MEDIUM_SPEED) and interpolation arrays (ANGLES and DISTANCES) to the HoodedShooterSupersystemConstants.
  • Incorporating a simple linear interpolation logic in HoodedShooterSupersystem using InterpolatingDoubleTreeMap.

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
src/main/java/frc/robot/Subsystems/Shooter/ShooterIOSim.java Updated shooter setpoint calculation with a new API method.
src/main/java/frc/robot/Subsystems/HoodedShooterSupersystem/HoodedShooterSupersystemConstants.java Added new mathematical constants and interpolation data arrays.
src/main/java/frc/robot/Subsystems/HoodedShooterSupersystem/HoodedShooterSupersystem.java Introduced interpolation logic for hood setpoint and updated shooter setpoint to return a constant.
Comments suppressed due to low confidence (2)

src/main/java/frc/robot/Subsystems/Shooter/ShooterIOSim.java:61

  • Verify that the new calculateWithVelocities method provides equivalent behavior to the old calculate method, so that the shooter control loop continues to perform as expected.
			)

src/main/java/frc/robot/Subsystems/HoodedShooterSupersystem/HoodedShooterSupersystemConstants.java:13

  • [nitpick] Consider updating placeholder constant names (e.g., FAKE_VALUE and FAKE_VALUE_2) and comments ('Random values and stuff') with clearer descriptions once the production values are determined.
	public static final AngularVelocity MEDIUM_SPEED = RotationsPerSecond.of(1500);

@Tortuga-AM Tortuga-AM linked an issue Jun 23, 2025 that may be closed by this pull request
@Tortuga-AM Tortuga-AM requested a review from GreenTomato5 June 23, 2025 21:26
Copy link
Contributor

@GreenTomato5 GreenTomato5 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine to me, a couple comments but those might not be important. Merge if it looks good to you

@GreenTomato5
Copy link
Contributor

@Tortuga-AM lock in, get out of canada

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature] Add linear interpolation

4 participants