Physical Properties Configuration
Swerve Module Physical Properties (modules/physicalproperties.json
)
modules/physicalproperties.json
)This JSON configures the physical properties shared with all the Swerve Modules. It maps 1:1 with PhysicalPropertiesJson
which creates SwerveModulePhysicalCharacteristics
.
Use the Standard Conversion Factors page to set the conversion factors for your robot if you're using a COTS swerve module!
Fields
conversionFactors
Y
Conversion factor composition. Factor is calculated on startup.
optimalVoltage
Voltage
Y
Optimal voltage to compensate to and base feedforward calculations off of.
currentLimit
N
The current limit in AMPs to apply to the motors. Supply limit for SparkMAXs, Stator limit for TalonFXs.
rampRate
N
The minimum number of seconds to take for the motor to go from 0 to full throttle.
friction
N
The minimum voltage to move the wheel or module. Defaults to 0.2
for drive motors, and 0.3
for angle motors.
robotMass
Lb (Pounds)
N
Default is 50
kgs.
steerRotationalInertia
KilogramMetersSquare
N
The rotational inertia in KilogramMetersSquare
. Defaults to 0.03
.
wheelGripCoefficientOfFriction
Coefficient of Friction on Carpet
N
The grip tape coefficient of friction on carpet. Used to calculate the practical maximum acceleration.
MotorConfig
drive
Number
Y
Drive motor value.
angle
Number
Y
Angle motor value.
Conversion Factor Composition
drive
Y
Drive conversion factor composition
angle
Y
Angle conversion factor composition
Drive Conversion Factor Composition
diameter
Inches
Y
Diameter of the wheel.
gearRatio
Number
Y
Gear ratio of the drive motor to wheel.
factor
Number
N
Pre-calculated conversion factor.
Angle Conversion Factor Composition
gearRatio
Number
Y
Gear ratio of the angle/steering/azimuth motor to wheel.
factor
Number
N
Pre-calculated conversion factor.
Example Configuration File
Last updated