Skip to content
This repository was archived by the owner on Nov 4, 2025. It is now read-only.

feat!: Auto alignment#92

Draft
HENRYMARTIN5 wants to merge 68 commits into
mainfrom
auto-alignment
Draft

feat!: Auto alignment#92
HENRYMARTIN5 wants to merge 68 commits into
mainfrom
auto-alignment

Conversation

@HENRYMARTIN5
Copy link
Copy Markdown
Member

No description provided.

ChrisAReed and others added 30 commits February 1, 2025 11:30
…o being stupid

Blame someone other than me pretty please
@HENRYMARTIN5 HENRYMARTIN5 requested a review from a team as a code owner March 17, 2025 23:46
DriverStation.silenceJoystickConnectionWarning(true);
SimulatedArena.getInstance().resetFieldForAuto();
}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I kinda like having it in the periodic since that's a much more obvious reminder. I will grant that it gets annoying, however. Let's leave it here, and then throw a warning if we have the joysticks connected and we're in test mode.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

That might be worth doing in #88

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Maybe make it only fire in console every 30s or smth? Should make it visible but still allow other debug output to be seen and scrolled through. I'll also have all of this send alerts to the dashboard too.

Comment thread src/main/java/frc/robot/RobotContainer.java
private Supplier<Translation2d> linearFF = () -> Translation2d.kZero;
private DoubleSupplier omegaFF = () -> 0.0;

private final ProfiledPIDController driveController =
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I would like to get these PID values moved into constants.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

ahem

Comment thread src/main/java/frc/robot/commands/drive/MoveToPose.java
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Maybe consider writing this as a function in the SwerveSubsystem, as I expect that we'll want to use this for lots of different stuff. We also might want to use this for autos as well, in which case we certainly want it in SwerveSubsystem.

Comment thread src/main/java/frc/robot/subsystems/swervedrive/Vision.java
This was referenced Mar 18, 2025
private Supplier<Translation2d> linearFF = () -> Translation2d.kZero;
private DoubleSupplier omegaFF = () -> 0.0;

private final ProfiledPIDController driveController =
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

ahem


private AprilTags() {}

public static List<Integer> reefTags() {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

what happens when this is null?

: RED_STATION_TAGS;
}

public static final Transform2d REEF_ALIGN_OFFSET = new Transform2d(0.6, 0, Rotation2d.kPi);
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

we need an offset to either side, cause the branches aren't perfectly centered.

@samfreund
Copy link
Copy Markdown
Member

@HENRYMARTIN5 control should remain field-centric for the input fusion

@samfreund
Copy link
Copy Markdown
Member

also the rotation of the desired pose is off

@samfreund
Copy link
Copy Markdown
Member

samfreund commented Mar 19, 2025

also something is funky with field orientation. I'm trying to sus it out

it seems to be present in main as well

I think we maybe need to invert drive input values?

private final SwerveSubsystem drive;
private final Supplier<Pose2d> pose;

private Supplier<Translation2d> linearFF = () -> Translation2d.kZero;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

idk if FeedForward is quite the right name here

@samfreund samfreund marked this pull request as draft March 25, 2025 03:35
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants