Skip to content

Commit

Permalink
fixed stupid steer gear ratio bug
Browse files Browse the repository at this point in the history
  • Loading branch information
qntmcube committed Nov 16, 2024
1 parent dffa89f commit a9ab5de
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,17 @@ private SwerveConstants() {}
// FIXME: have these be passed in from Drive (via SwerveConfig). Many of these are
// passed into Odometry. (Swerve and Odometry code need to be renconciled.)

public static final double DRIVE_GEAR_RATIO = 6.75; // L2 gear ratio configuration

public static final double STEER_GEAR_RATIO = 150.0 / 7.0; // L2 gear ratio configuration

/*
* Factor that converts between motor rotations and wheel degrees
* Multiply to convert from wheel degrees to motor rotations
* Divide to convert from motor rotations to wheel degrees
*/
public static final double ENCODER_CONVERSION_FACTOR =
(150.0 / 7.0) /*steering gear ratio*/ * (1. / 360.0) /*degrees to motor rotations*/;

public static final double DRIVE_GEAR_RATIO = 6.75; // L2 gear ratio configuration

public static final double STEER_GEAR_RATIO = 150/7; // L2 gear ratio configuration
STEER_GEAR_RATIO /*steering gear ratio*/ * (1. / 360.0) /*degrees to motor rotations*/;

// Radius of the wheels. The circumference was measured to be 30.5cm, then experimentally this
// value had
Expand Down

0 comments on commit a9ab5de

Please sign in to comment.