]> git.taranathan.com Git - FRC2026.git/commitdiff
fad
authormaxwtan <100314265+MaxwellTTan20@users.noreply.github.com>
Thu, 22 Jan 2026 23:44:51 +0000 (15:44 -0800)
committermaxwtan <100314265+MaxwellTTan20@users.noreply.github.com>
Thu, 22 Jan 2026 23:44:51 +0000 (15:44 -0800)
src/main/java/frc/robot/constants/swerve/DriveConstants.java
src/main/java/frc/robot/subsystems/drivetrain/Module.java

index 316893669cc26b8d02edb4edfe14c2fd414bb394..c569d517417a55f09a8cf4011ab1ab303e39f717 100644 (file)
@@ -211,10 +211,9 @@ public class DriveConstants {
             WHEEL_MOI = 0.000326 * ROBOT_MASS;
 
         } else if (robotId == RobotId.Vertigo) {
-            STEER_OFFSET_FRONT_LEFT = 4.185;
-            STEER_OFFSET_FRONT_RIGHT = 101.519+90;
-            STEER_OFFSET_BACK_LEFT = 38.997+180;
-            STEER_OFFSET_BACK_RIGHT = 242.847-90;
+            STEER_OFFSET_FRONT_LEFT = 194.326 + 180.0;
+            STEER_OFFSET_BACK_LEFT = 129.111 + 180.0;
+            STEER_OFFSET_BACK_RIGHT = 107.578;
             
             DRIVE_GEAR_RATIO = (50.0 / 14.0) * (17.0 / 27.0) * (45.0 / 15.0);
 
index 6fa9d461ae17ddb4813b3179143b5782e68ab3e0..f55b8f9fb8458d28cf22bca842e5a918092c03cc 100644 (file)
@@ -33,6 +33,7 @@ import edu.wpi.first.units.measure.Current;
 import edu.wpi.first.units.measure.Voltage;
 import edu.wpi.first.wpilibj.Alert;
 import edu.wpi.first.wpilibj.Alert.AlertType;
+import edu.wpi.first.wpilibj.smartdashboard.SmartDashboard;
 import frc.robot.constants.swerve.DriveConstants;
 import frc.robot.constants.swerve.ModuleConstants;
 import frc.robot.constants.swerve.ModuleType;
@@ -205,6 +206,8 @@ public class Module implements ModuleIO{
     }
     
     public void periodic() {
+        SmartDashboard.putNumber("encoder offset for " + getModuleType(), Units.rotationsToDegrees(CANcoder.getAbsolutePosition().getValueAsDouble()));
+
         updateInputs();
         Logger.processInputs("Drive/Module" + Integer.toString(moduleConstants.ordinal()), inputs);