Skip to content

Commit

Permalink
AbsoluteDriveAdv Command Rotation Fix
Browse files Browse the repository at this point in the history
Fixes a logic issue that causes the AbsoluteDriveAdv Command to output zero angular velocity every other periodic call when using the manual heading adjustment
  • Loading branch information
JershJopstin authored Mar 13, 2024
1 parent ba5069c commit 7d5d321
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ public void execute()
// Prevent Movement After Auto
if (resetHeading)
{
if (headingX == 0 && headingY == 0 && Math.abs(headingAdjust.getAsDouble()) > 0)
if (headingX == 0 && headingY == 0 && Math.abs(headingAdjust.getAsDouble()) == 0)
{
// Get the curret Heading
Rotation2d currentHeading = swerve.getHeading();
Expand Down

0 comments on commit 7d5d321

Please sign in to comment.