Class PhysicalPropertiesJson

java.lang.Object
swervelib.parser.json.PhysicalPropertiesJson

public class PhysicalPropertiesJson extends Object
SwerveModulePhysicalCharacteristics parsed data. Used to configure the SwerveModule.
  • Field Details

    • conversionFactor

      public MotorConfigDouble conversionFactor
      Conversion factor applied to the motor controllers PID loops. Can be calculated with SwerveMath.calculateDegreesPerSteeringRotation(double, double) for angle motors or SwerveMath.calculateMetersPerRotation(double, double, double) for drive motors.
    • conversionFactors

      public ConversionFactorsJson conversionFactors
      Conversion Factors composition. Auto-calculates the conversion factors.
    • currentLimit

      public MotorConfigInt currentLimit
      The current limit in AMPs to apply to the motors.
    • rampRate

      public MotorConfigDouble rampRate
      The minimum number of seconds to take for the motor to go from 0 to full throttle.
    • wheelGripCoefficientOfFriction

      public double wheelGripCoefficientOfFriction
      The grip tape coefficient of friction on carpet. Used to calculate the practical maximum acceleration.
    • optimalVoltage

      public double optimalVoltage
      The voltage to use for the smart motor voltage compensation, default is 12.
  • Constructor Details

    • PhysicalPropertiesJson

      public PhysicalPropertiesJson()
  • Method Details