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

Commit 5bf38b8

Browse files
Merge pull request #239 from Shenzhen-Robotics-Alliance/dev
A tiny bug fix in the aim-at-speaker command of the example swerve subsystem code
2 parents cbcb0d1 + a9f73a5 commit 5bf38b8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/frc/robot/subsystems/swervedrive/SwerveSubsystem.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,7 @@ public Command aimAtSpeaker(double tolerance)
228228
getSpeakerYaw().getRadians()),
229229
getHeading())
230230
);
231-
}).until(() -> getSpeakerYaw().minus(getHeading()).getDegrees() < tolerance);
231+
}).until(() -> Math.abs(getSpeakerYaw().minus(getHeading()).getDegrees()) < tolerance);
232232
}
233233

234234
/**

0 commit comments

Comments
 (0)