Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/main/java/frc/robot/RobotContainer.java
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,6 @@ public Command addVisionMeasurement() {
}

public static boolean isPracticeBot() {
return RobotController.getSerialNumber().equals(ConstSystem.PRACTICE_BOT_RIO);
return RobotController.getSerialNumber().equals(ConstSystem.PRACTICE_BOT_RIO_SERIAL_NUMBER);
}
}
6 changes: 6 additions & 0 deletions src/main/java/frc/robot/constants/ConstDrivetrain.java
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,10 @@ public static class PRACTICE_BOT {
public static final double SLOW_MODE_MULTIPLIER = 0.5;

// Physical dimensions
// TODO: Confirm Gear Ratios
public static Ratios GEAR_RATIOS = Ratios.MK4I.L2;

// TODO: Replace with actual measurement
public static Distance WHEEL_DIAMETER = Inches.of(4.0);
public static Distance MODULE_OFFSET_LOCATIONS = ModuleLocations.frame29x29;

Expand Down Expand Up @@ -107,6 +109,7 @@ public static class PRACTICE_BOT {
public static final double MEASUREMENT_STD_DEV_HEADING = Units.Radians.convertFrom(5, Units.Degrees);

// Inverts
// TODO: Replace with actual measurement
public static final boolean INVERT_LEFT_SIDE_DRIVE = false;
Comment thread
TaylerUva marked this conversation as resolved.
public static final boolean INVERT_RIGHT_SIDE_DRIVE = true;
public static final boolean INVERT_STEER = true;
Expand Down Expand Up @@ -159,6 +162,7 @@ public static class PRACTICE_BOT {
public static class AUTO_ALIGN {
public static final LinearVelocity MIN_DRIVER_OVERRIDE = ConstDrivetrain.REAL_DRIVE_SPEED.div(10);

// TODO: Replace with actual PID
public static final PIDController POSE_TRANS_CONTROLLER = new PIDController(
3,
0,
Expand All @@ -171,6 +175,7 @@ public static class AUTO_ALIGN {

public static final Distance AT_POINT_TOLERANCE = Units.Inches.of(0.5);

// TODO: Replace with actual PID
public static final ProfiledPIDController POSE_ROTATION_CONTROLLER = new ProfiledPIDController(
2, 0, 0, new TrapezoidProfile.Constraints(TURN_SPEED.in(Units.DegreesPerSecond),
Math.pow(TURN_SPEED.in(Units.DegreesPerSecond), 2)));
Expand Down Expand Up @@ -209,6 +214,7 @@ public static class SIMULATION {
public static final Voltage kDriveFrictionVoltage = Volts.of(0.2);
}

// TODO: Replace with actual PID
public static class ROTATION_PID {
public static final double kP = 5.0;
public static final double kI = 0.0;
Expand Down
1 change: 1 addition & 0 deletions src/main/java/frc/robot/constants/ConstField.java
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ public static boolean isRedAlliance() {
};

public static class FieldElements {
// TODO: Replace with actual measurement
private static final Pose2d RESET_POSE = new Pose2d(0, 0, new Rotation2d());

}
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/frc/robot/constants/ConstSystem.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

public final class ConstSystem {

public static final String PRACTICE_BOT_RIO = ""; // TODO: Replace with actual RIO name
public static final String PRACTICE_BOT_RIO_SERIAL_NUMBER = ""; // TODO: Replace with actual RIO serial number

public static class constControllers {
public static final double DRIVER_LEFT_STICK_DEADBAND = 0.05;
Expand Down
4 changes: 4 additions & 0 deletions src/main/java/frc/robot/constants/ConstVision.java
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ public static class IMUMode {
}

public static final double IMU_ASSIST_ALPHA_VALUE = 0.01;
// TODO: Replace with actual names
public static final String LIMELIGHT_RIGHT_NAME = "limelight-right";
public static final String LIMELIGHT_LEFT_NAME = "limelight-left";
public static final String LIMELIGHT_BACK_NAME = "limelight-back";
Expand Down Expand Up @@ -93,6 +94,7 @@ public static class IMUMode {
public static final Boolean USE_MEGA_TAG_2 = true;

// The below values are accounted for in the limelight interface, NOT in code
// TODO: Replace with actual measurement
public static class LimelightRight {
public static final Distance LL_FORWARD = Units.Meters.of(0.269494);
public static final Distance LL_RIGHT = Units.Meters.of(0.307594);
Expand All @@ -103,6 +105,7 @@ public static class LimelightRight {
public static final Angle LL_YAW = Units.Degrees.of(51.25);
}

// TODO: Replace with actual measurement
public static class LimelightLeft {
public static final Distance LL_FORWARD = Units.Meters.of(0.269494);
public static final Distance LL_RIGHT = Units.Meters.of(-0.307594);
Expand All @@ -114,6 +117,7 @@ public static class LimelightLeft {

}

// TODO: Replace with actual measurement
public static class LimelightBack {
public static final Distance LL_FORWARD = Units.Meters.of(0.3429);
public static final Distance LL_RIGHT = Units.Meters.of(0);
Expand Down
Loading