Class TunerConstants2025
java.lang.Object
frc.alotobots.library.subsystems.swervedrive.constants.mk4i2025.TunerConstants2025
- All Implemented Interfaces:
TunerConstants
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic class -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncom.ctre.phoenix6.swerve.SwerveModuleConstants<com.ctre.phoenix6.configs.TalonFXConfiguration,com.ctre.phoenix6.configs.TalonFXConfiguration, com.ctre.phoenix6.configs.CANcoderConfiguration> Gets the configuration constants for the back left swerve module.com.ctre.phoenix6.swerve.SwerveModuleConstants<com.ctre.phoenix6.configs.TalonFXConfiguration,com.ctre.phoenix6.configs.TalonFXConfiguration, com.ctre.phoenix6.configs.CANcoderConfiguration> Gets the configuration constants for the back right swerve module.Gets the length of the robot with bumpers.Gets the width of the robot with bumpers.doubleGets the radius of the drive base from center to furthest module.Gets the PID controller for maintaining robot heading while driving.com.ctre.phoenix6.configs.Slot0ConfigsGets the PID gains for the drive motors.com.ctre.phoenix6.swerve.SwerveDrivetrainConstantsGets the general drivetrain constants for the swerve drive.org.ironmaple.simulation.drivesims.configs.DriveTrainSimulationConfigGets the simulation config for Maple-Simcom.ctre.phoenix6.swerve.SwerveModuleConstants<com.ctre.phoenix6.configs.TalonFXConfiguration,com.ctre.phoenix6.configs.TalonFXConfiguration, com.ctre.phoenix6.configs.CANcoderConfiguration> Gets the configuration constants for the front left swerve module.com.ctre.phoenix6.swerve.SwerveModuleConstants<com.ctre.phoenix6.configs.TalonFXConfiguration,com.ctre.phoenix6.configs.TalonFXConfiguration, com.ctre.phoenix6.configs.CANcoderConfiguration> Gets the configuration constants for the front right swerve module.com.pathplanner.lib.controllers.PPHolonomicDriveControllerGets the holonomic drive controller for path following.doubleGets the maximum rotational rate of individual modules.Gets the physical positions of all swerve modules relative to the robot center.Gets the robot's standard operating speed.doubleGets the frequency at which odometry updates are processed.com.pathplanner.lib.path.PathConstraintsGets the constraints for PathPlanner pathfinding.com.pathplanner.lib.config.RobotConfigGets the PathPlanner configuration for the robot.doubleGets the radius in which precision align should functioncom.pathplanner.lib.controllers.PPHolonomicDriveControllerGets the precision align holonomic drive controller for path following.doubleGets the precision align tolerance (when it stops trying to correct)Gets the robot's maximum speed at 12 volts.com.ctre.phoenix6.configs.Slot0ConfigsGets the PID gains for the steer motors.Gets the robot's maximum boosted speed.Gets the robot's reduced speed for precision control.
-
Constructor Details
-
TunerConstants2025
public TunerConstants2025()
-
-
Method Details
-
getFrontLeft
public com.ctre.phoenix6.swerve.SwerveModuleConstants<com.ctre.phoenix6.configs.TalonFXConfiguration,com.ctre.phoenix6.configs.TalonFXConfiguration, getFrontLeft()com.ctre.phoenix6.configs.CANcoderConfiguration> Description copied from interface:TunerConstantsGets the configuration constants for the front left swerve module.- Specified by:
getFrontLeftin interfaceTunerConstants- Returns:
- SwerveModuleConstants containing TalonFX and CANcoder configurations for the front left module
-
getFrontRight
public com.ctre.phoenix6.swerve.SwerveModuleConstants<com.ctre.phoenix6.configs.TalonFXConfiguration,com.ctre.phoenix6.configs.TalonFXConfiguration, getFrontRight()com.ctre.phoenix6.configs.CANcoderConfiguration> Description copied from interface:TunerConstantsGets the configuration constants for the front right swerve module.- Specified by:
getFrontRightin interfaceTunerConstants- Returns:
- SwerveModuleConstants containing TalonFX and CANcoder configurations for the front right module
-
getBackLeft
public com.ctre.phoenix6.swerve.SwerveModuleConstants<com.ctre.phoenix6.configs.TalonFXConfiguration,com.ctre.phoenix6.configs.TalonFXConfiguration, getBackLeft()com.ctre.phoenix6.configs.CANcoderConfiguration> Description copied from interface:TunerConstantsGets the configuration constants for the back left swerve module.- Specified by:
getBackLeftin interfaceTunerConstants- Returns:
- SwerveModuleConstants containing TalonFX and CANcoder configurations for the back left module
-
getBackRight
public com.ctre.phoenix6.swerve.SwerveModuleConstants<com.ctre.phoenix6.configs.TalonFXConfiguration,com.ctre.phoenix6.configs.TalonFXConfiguration, getBackRight()com.ctre.phoenix6.configs.CANcoderConfiguration> Description copied from interface:TunerConstantsGets the configuration constants for the back right swerve module.- Specified by:
getBackRightin interfaceTunerConstants- Returns:
- SwerveModuleConstants containing TalonFX and CANcoder configurations for the back right module
-
getDrivetrainConstants
public com.ctre.phoenix6.swerve.SwerveDrivetrainConstants getDrivetrainConstants()Description copied from interface:TunerConstantsGets the general drivetrain constants for the swerve drive.- Specified by:
getDrivetrainConstantsin interfaceTunerConstants- Returns:
- SwerveDrivetrainConstants containing overall drivetrain configuration
-
getPathfindingConstraints
public com.pathplanner.lib.path.PathConstraints getPathfindingConstraints()Description copied from interface:TunerConstantsGets the constraints for PathPlanner pathfinding.- Specified by:
getPathfindingConstraintsin interfaceTunerConstants- Returns:
- PathConstraints containing velocity and acceleration limits
-
getHolonomicDriveController
public com.pathplanner.lib.controllers.PPHolonomicDriveController getHolonomicDriveController()Description copied from interface:TunerConstantsGets the holonomic drive controller for path following.- Specified by:
getHolonomicDriveControllerin interfaceTunerConstants- Returns:
- PPHolonomicDriveController for path following control
-
getPrecisionAlignHolonomicDriveController
public com.pathplanner.lib.controllers.PPHolonomicDriveController getPrecisionAlignHolonomicDriveController()Description copied from interface:TunerConstantsGets the precision align holonomic drive controller for path following.- Specified by:
getPrecisionAlignHolonomicDriveControllerin interfaceTunerConstants- Returns:
- PPHolonomicDriveController for path following control
-
getBumperLength
Description copied from interface:TunerConstantsGets the length of the robot with bumpers.- Specified by:
getBumperLengthin interfaceTunerConstants- Returns:
- The bumper length as a Distance
-
getBumperWidth
Description copied from interface:TunerConstantsGets the width of the robot with bumpers.- Specified by:
getBumperWidthin interfaceTunerConstants- Returns:
- The bumper width as a Distance
-
getDriveBaseRadius
public double getDriveBaseRadius()Description copied from interface:TunerConstantsGets the radius of the drive base from center to furthest module.- Specified by:
getDriveBaseRadiusin interfaceTunerConstants- Returns:
- The drive base radius in meters
-
getOdometryFrequency
public double getOdometryFrequency()Description copied from interface:TunerConstantsGets the frequency at which odometry updates are processed.- Specified by:
getOdometryFrequencyin interfaceTunerConstants- Returns:
- The odometry update frequency in hertz
-
getSteerGains
public com.ctre.phoenix6.configs.Slot0Configs getSteerGains()Description copied from interface:TunerConstantsGets the PID gains for the steer motors.- Specified by:
getSteerGainsin interfaceTunerConstants- Returns:
- Slot0Configs containing PID and feedforward gains for steering
-
getDriveGains
public com.ctre.phoenix6.configs.Slot0Configs getDriveGains()Description copied from interface:TunerConstantsGets the PID gains for the drive motors.- Specified by:
getDriveGainsin interfaceTunerConstants- Returns:
- Slot0Configs containing PID and feedforward gains for driving
-
getSpeedAt12Volts
Description copied from interface:TunerConstantsGets the robot's maximum speed at 12 volts.- Specified by:
getSpeedAt12Voltsin interfaceTunerConstants- Returns:
- The maximum speed as a LinearVelocity
-
getTurtleSpeed
Description copied from interface:TunerConstantsGets the robot's reduced speed for precision control.- Specified by:
getTurtleSpeedin interfaceTunerConstants- Returns:
- The turtle mode speed as a LinearVelocity
-
getNominalSpeed
Description copied from interface:TunerConstantsGets the robot's standard operating speed.- Specified by:
getNominalSpeedin interfaceTunerConstants- Returns:
- The nominal speed as a LinearVelocity
-
getTurboSpeed
Description copied from interface:TunerConstantsGets the robot's maximum boosted speed.- Specified by:
getTurboSpeedin interfaceTunerConstants- Returns:
- The turbo mode speed as a LinearVelocity
-
getMaxModularRotationalRate
public double getMaxModularRotationalRate()Description copied from interface:TunerConstantsGets the maximum rotational rate of individual modules.- Specified by:
getMaxModularRotationalRatein interfaceTunerConstants- Returns:
- The maximum rotational rate in radians per second
-
getPathPlannerConfig
public com.pathplanner.lib.config.RobotConfig getPathPlannerConfig()Description copied from interface:TunerConstantsGets the PathPlanner configuration for the robot.- Specified by:
getPathPlannerConfigin interfaceTunerConstants- Returns:
- RobotConfig containing PathPlanner-specific settings
-
getDriveFacingAnglePIDController
Description copied from interface:TunerConstantsGets the PID controller for maintaining robot heading while driving.- Specified by:
getDriveFacingAnglePIDControllerin interfaceTunerConstants- Returns:
- ProfiledPIDController for heading control
-
getPrecisionAlignTolerance
public double getPrecisionAlignTolerance()Description copied from interface:TunerConstantsGets the precision align tolerance (when it stops trying to correct)- Specified by:
getPrecisionAlignTolerancein interfaceTunerConstants- Returns:
- double of tolerance
-
getPrecisionAlignAllowRadius
public double getPrecisionAlignAllowRadius()Description copied from interface:TunerConstantsGets the radius in which precision align should function- Specified by:
getPrecisionAlignAllowRadiusin interfaceTunerConstants- Returns:
- double of tolerance
-
getDriveTrainSimulationConfig
public org.ironmaple.simulation.drivesims.configs.DriveTrainSimulationConfig getDriveTrainSimulationConfig()Description copied from interface:TunerConstantsGets the simulation config for Maple-Sim- Specified by:
getDriveTrainSimulationConfigin interfaceTunerConstants- Returns:
- The simulation config
-
getModuleTranslations
Description copied from interface:TunerConstantsGets the physical positions of all swerve modules relative to the robot center.- Specified by:
getModuleTranslationsin interfaceTunerConstants- Returns:
- Array of Translation2d representing module positions
-