diff --git a/docs/allclasses-index.html b/docs/allclasses-index.html index de6b6ec..c46c7f3 100644 --- a/docs/allclasses-index.html +++ b/docs/allclasses-index.html @@ -1,11 +1,11 @@
- +Notifier to keep odometry up to date.Translation2d Polar coordinate magnitude.SwerveDrive from JSON configuration directory.Translation2d magnitude given in Polar coordinates.Alert for if the absolute encoder does not support integrated offsets.drive(Translation2d, double, boolean, boolean) using 254's
correction.edu.wpi.first.wpilibj.smartdashboard.Field2dprivate doubleedu.wpi.first.wpilibj.smartdashboard.Field2dprivate doubleprivate doublebooleanbooleanprivate SwerveIMUprivate SwerveIMUfinal Cache<edu.wpi.first.math.geometry.Rotation3d>final Cache<edu.wpi.first.math.geometry.Rotation3d>final edu.wpi.first.math.kinematics.SwerveDriveKinematicsfinal edu.wpi.first.math.kinematics.SwerveDriveKinematicsprivate doubleprivate doubleprivate doubleprivate doubleprivate intprivate intprivate final Lockprivate final Lockprivate final edu.wpi.first.wpilibj.Notifierprivate final edu.wpi.first.wpilibj.NotifierNotifier to keep odometry up to date.private SwerveIMUSimulationprivate SwerveIMUSimulationfinal SwerveDriveConfigurationfinal SwerveDriveConfigurationfinal edu.wpi.first.math.estimator.SwerveDrivePoseEstimatorfinal edu.wpi.first.math.estimator.SwerveDrivePoseEstimatorprivate final SwerveModule[]private final SwerveModule[]private final Alertprivate final AlertOptional<edu.wpi.first.math.geometry.Translation3d>getAccel()voiddriveFieldOrientedandRobotOriented(edu.wpi.first.math.kinematics.ChassisSpeeds fieldOrientedVelocity,
+ edu.wpi.first.math.kinematics.ChassisSpeeds robotOrientedVelocity) Optional<edu.wpi.first.math.geometry.Translation3d>getAccel()edu.wpi.first.math.kinematics.ChassisSpeedsedu.wpi.first.math.kinematics.ChassisSpeedsgetGyro()getGyro()SwerveIMU.edu.wpi.first.math.geometry.Rotation3dedu.wpi.first.math.geometry.Rotation3dRotation3d of the robot, as reported by the imu.doubledoubleattainableMaxRotationalVelocityRadiansPerSecond or
SwerveControllerConfiguration.maxAngularVelocity.doubledoubleattainableMaxTranslationalSpeedMetersPerSecond or
maxSpeedMPS whichever is higher.SwerveModule's as a HashMap where the key is the swerve module configuration name.edu.wpi.first.math.kinematics.SwerveModulePosition[]edu.wpi.first.math.kinematics.SwerveModulePosition[]SwerveModules associated with the SwerveDrive.edu.wpi.first.math.geometry.Rotation2dedu.wpi.first.math.geometry.Rotation2dgetYaw().edu.wpi.first.math.geometry.Rotation2dgetPitch()edu.wpi.first.math.geometry.Rotation2dgetPitch()edu.wpi.first.math.geometry.Pose2dgetPose()edu.wpi.first.math.geometry.Pose2dgetPose()edu.wpi.first.math.kinematics.ChassisSpeedsedu.wpi.first.math.kinematics.ChassisSpeedsedu.wpi.first.math.geometry.Rotation2dgetRoll()edu.wpi.first.math.geometry.Rotation2dgetRoll()edu.wpi.first.math.kinematics.SwerveModuleState[]edu.wpi.first.math.kinematics.SwerveModuleState[]swerveController for the SwerveDrive which can be used to
generate ChassisSpeeds for the robot to orient it correctly given axis or angles, and apply
SlewRateLimiter to given inputs.edu.wpi.first.math.geometry.Pose2d[]getSwerveModulePoses(edu.wpi.first.math.geometry.Pose2d robotPose) edu.wpi.first.math.geometry.Pose2d[]getSwerveModulePoses(edu.wpi.first.math.geometry.Pose2d robotPose) edu.wpi.first.math.geometry.Rotation2dgetYaw()edu.wpi.first.math.geometry.Rotation2dgetYaw()voidlockPose()voidlockPose()voidpostTrajectory(edu.wpi.first.math.trajectory.Trajectory trajectory) voidpostTrajectory(edu.wpi.first.math.trajectory.Trajectory trajectory) voidvoidvoidreplaceSwerveModuleFeedforward(edu.wpi.first.math.controller.SimpleMotorFeedforward driveFeedforward) voidreplaceSwerveModuleFeedforward(edu.wpi.first.math.controller.SimpleMotorFeedforward driveFeedforward) voidvoidvoidresetOdometry(edu.wpi.first.math.geometry.Pose2d pose) voidresetOdometry(edu.wpi.first.math.geometry.Pose2d pose) voidvoidvoidsetAngleMotorConversionFactor(double conversionFactor) voidsetAngleMotorConversionFactor(double conversionFactor) voidsetChassisDiscretization(boolean enable,
+ double dtSeconds) voidsetChassisSpeeds(edu.wpi.first.math.kinematics.ChassisSpeeds chassisSpeeds) fieldOrientedVelocity - The field oriented velocties to userobotOrientedVelocity - The robot oriented velocties to useenable - Enable chassis velocity correction, which will use
+ ChassisSpeeds.discretize(ChassisSpeeds, double) with the following.dtSeconds - The duration of the timestep the speeds should be applied for.private SwerveModuleSimulationprivate final Stringprivate SwerveModuleSimulationprivate booleanvoidconfig - PIDFConfig of that should be set.config - PIDFConfig of that should be set.config - PIDFConfig of that should be set.private doublebooleansetAbsoluteEncoderOffset(double offset) Alert for if the encoder cannot report accurate velocities.SwerveAbsoluteEncodersetAbsoluteEncoderOffset in class SwerveAbsoluteEncoderoffset - the offset the Absolute Encoder uses as the zero point.offset - the offset the Absolute Encoder uses as the zero point in degrees.offset - the offset the Absolute Encoder uses as the zero point.offset - the offset the Absolute Encoder uses as the zero point in degrees.static SwerveModuleConfigurationgetSwerveModule(SwerveModule[] modules,
+static edu.wpi.first.math.geometry.Translation2d
+cubeTranslation(edu.wpi.first.math.geometry.Translation2d translation)
+
+Cube the Translation2d magnitude given in Polar coordinates.
+
+static SwerveModuleConfiguration
+getSwerveModule(SwerveModule[] modules,
boolean front,
boolean left)
-
+
Get the fruthest module from center based on the module locations.
-static edu.wpi.first.math.geometry.Translation2d
-limitVelocity(edu.wpi.first.math.geometry.Translation2d commandedVelocity,
+static edu.wpi.first.math.geometry.Translation2d
+limitVelocity(edu.wpi.first.math.geometry.Translation2d commandedVelocity,
edu.wpi.first.math.kinematics.ChassisSpeeds fieldVelocity,
edu.wpi.first.math.geometry.Pose2d robotPose,
double loopTime,
double robotMass,
List<Matter> matter,
SwerveDriveConfiguration config)
-
+
Limits a commanded velocity to prevent exceeding the maximum acceleration given by calcMaxAccel(edu.wpi.first.math.geometry.Rotation2d, java.util.List<swervelib.math.Matter>, double, swervelib.parser.SwerveDriveConfiguration).
-static double
-normalizeAngle(double angle)
-
+static double
+normalizeAngle(double angle)
+
Normalize an angle to be within 0 to 360.
-static double
-placeInAppropriate0To360Scope(double scopeReference,
+static double
+placeInAppropriate0To360Scope(double scopeReference,
double newAngle)
-
+
Put an angle within the 360 deg scope of a reference.
-static edu.wpi.first.math.geometry.Twist2d
-PoseLog(edu.wpi.first.math.geometry.Pose2d transform)
-
+static edu.wpi.first.math.geometry.Twist2d
+PoseLog(edu.wpi.first.math.geometry.Pose2d transform)
+
Logical inverse of the Pose exponential from 254.
+static edu.wpi.first.math.geometry.Translation2d
+scaleTranslation(edu.wpi.first.math.geometry.Translation2d translation,
+ double scalar)
+
+Scale the Translation2d Polar coordinate magnitude.
+
@@ -518,6 +529,34 @@ loadScripts(document, 'script');
+
+
+cubeTranslation
+public static edu.wpi.first.math.geometry.Translation2d cubeTranslation(edu.wpi.first.math.geometry.Translation2d translation)
+Cube the Translation2d magnitude given in Polar coordinates.
+
+- Parameters:
+translation - Translation2d to manipulate.
+- Returns:
+- Cubed magnitude from
Translation2d.
+
+
+
+
+
+scaleTranslation
+public static edu.wpi.first.math.geometry.Translation2d scaleTranslation(edu.wpi.first.math.geometry.Translation2d translation,
+ double scalar)
+Scale the Translation2d Polar coordinate magnitude.
+
+- Parameters:
+translation - Translation2d to use.
+scalar - Multiplier for the Polar coordinate magnitude to use.
+- Returns:
+Translation2d scaled by given magnitude scalar.
+
+
+
diff --git a/docs/swervelib/math/package-summary.html b/docs/swervelib/math/package-summary.html
index 1df650c..3ca8be5 100644
--- a/docs/swervelib/math/package-summary.html
+++ b/docs/swervelib/math/package-summary.html
@@ -1,11 +1,11 @@
-
+
swervelib.math
-
+
diff --git a/docs/swervelib/math/package-tree.html b/docs/swervelib/math/package-tree.html
index f6c3ff4..bba8f6c 100644
--- a/docs/swervelib/math/package-tree.html
+++ b/docs/swervelib/math/package-tree.html
@@ -1,11 +1,11 @@
-
+
swervelib.math Class Hierarchy
-
+
diff --git a/docs/swervelib/motors/SparkFlexSwerve.SparkMAX_slotIdx.html b/docs/swervelib/motors/SparkFlexSwerve.SparkMAX_slotIdx.html
index 187396c..3c01e5a 100644
--- a/docs/swervelib/motors/SparkFlexSwerve.SparkMAX_slotIdx.html
+++ b/docs/swervelib/motors/SparkFlexSwerve.SparkMAX_slotIdx.html
@@ -1,11 +1,11 @@
-
+
SparkFlexSwerve.SparkMAX_slotIdx
-
+
diff --git a/docs/swervelib/motors/SparkFlexSwerve.html b/docs/swervelib/motors/SparkFlexSwerve.html
index 80fd40a..5da98c9 100644
--- a/docs/swervelib/motors/SparkFlexSwerve.html
+++ b/docs/swervelib/motors/SparkFlexSwerve.html
@@ -1,11 +1,11 @@
-
+
SparkFlexSwerve
-
+
diff --git a/docs/swervelib/motors/SparkMaxBrushedMotorSwerve.html b/docs/swervelib/motors/SparkMaxBrushedMotorSwerve.html
index 885dce4..e0ec23e 100644
--- a/docs/swervelib/motors/SparkMaxBrushedMotorSwerve.html
+++ b/docs/swervelib/motors/SparkMaxBrushedMotorSwerve.html
@@ -1,11 +1,11 @@
-
+
SparkMaxBrushedMotorSwerve
-
+
diff --git a/docs/swervelib/motors/SparkMaxSwerve.SparkMAX_slotIdx.html b/docs/swervelib/motors/SparkMaxSwerve.SparkMAX_slotIdx.html
index e292410..fe9a91f 100644
--- a/docs/swervelib/motors/SparkMaxSwerve.SparkMAX_slotIdx.html
+++ b/docs/swervelib/motors/SparkMaxSwerve.SparkMAX_slotIdx.html
@@ -1,11 +1,11 @@
-
+
SparkMaxSwerve.SparkMAX_slotIdx
-
+
diff --git a/docs/swervelib/motors/SparkMaxSwerve.html b/docs/swervelib/motors/SparkMaxSwerve.html
index 26de12c..819f36c 100644
--- a/docs/swervelib/motors/SparkMaxSwerve.html
+++ b/docs/swervelib/motors/SparkMaxSwerve.html
@@ -1,11 +1,11 @@
-
+
SparkMaxSwerve
-
+
diff --git a/docs/swervelib/motors/SwerveMotor.html b/docs/swervelib/motors/SwerveMotor.html
index d520e3f..bba17d5 100644
--- a/docs/swervelib/motors/SwerveMotor.html
+++ b/docs/swervelib/motors/SwerveMotor.html
@@ -1,11 +1,11 @@
-
+
SwerveMotor
-
+
diff --git a/docs/swervelib/motors/TalonFXSwerve.html b/docs/swervelib/motors/TalonFXSwerve.html
index 9968d5f..a00df60 100644
--- a/docs/swervelib/motors/TalonFXSwerve.html
+++ b/docs/swervelib/motors/TalonFXSwerve.html
@@ -1,11 +1,11 @@
-
+
TalonFXSwerve
-
+
diff --git a/docs/swervelib/motors/TalonSRXSwerve.html b/docs/swervelib/motors/TalonSRXSwerve.html
index 3c2ff0b..3fc8778 100644
--- a/docs/swervelib/motors/TalonSRXSwerve.html
+++ b/docs/swervelib/motors/TalonSRXSwerve.html
@@ -1,11 +1,11 @@
-
+
TalonSRXSwerve
-
+
diff --git a/docs/swervelib/motors/package-summary.html b/docs/swervelib/motors/package-summary.html
index 28192ea..6d2a86f 100644
--- a/docs/swervelib/motors/package-summary.html
+++ b/docs/swervelib/motors/package-summary.html
@@ -1,11 +1,11 @@
-
+
swervelib.motors
-
+
diff --git a/docs/swervelib/motors/package-tree.html b/docs/swervelib/motors/package-tree.html
index a738a57..3205c64 100644
--- a/docs/swervelib/motors/package-tree.html
+++ b/docs/swervelib/motors/package-tree.html
@@ -1,11 +1,11 @@
-
+
swervelib.motors Class Hierarchy
-
+
diff --git a/docs/swervelib/package-summary.html b/docs/swervelib/package-summary.html
index a9929c4..ed97791 100644
--- a/docs/swervelib/package-summary.html
+++ b/docs/swervelib/package-summary.html
@@ -1,11 +1,11 @@
-
+
swervelib
-
+
diff --git a/docs/swervelib/package-tree.html b/docs/swervelib/package-tree.html
index 9d80d84..080ea51 100644
--- a/docs/swervelib/package-tree.html
+++ b/docs/swervelib/package-tree.html
@@ -1,11 +1,11 @@
-
+
swervelib Class Hierarchy
-
+
diff --git a/docs/swervelib/parser/Cache.html b/docs/swervelib/parser/Cache.html
index 36b6041..71d7b18 100644
--- a/docs/swervelib/parser/Cache.html
+++ b/docs/swervelib/parser/Cache.html
@@ -1,11 +1,11 @@
-
+
Cache
-
+
diff --git a/docs/swervelib/parser/PIDFConfig.html b/docs/swervelib/parser/PIDFConfig.html
index 6c6ad1e..f3df0e1 100644
--- a/docs/swervelib/parser/PIDFConfig.html
+++ b/docs/swervelib/parser/PIDFConfig.html
@@ -1,11 +1,11 @@
-
+
PIDFConfig
-
+
diff --git a/docs/swervelib/parser/SwerveControllerConfiguration.html b/docs/swervelib/parser/SwerveControllerConfiguration.html
index 04f4116..c25fd3d 100644
--- a/docs/swervelib/parser/SwerveControllerConfiguration.html
+++ b/docs/swervelib/parser/SwerveControllerConfiguration.html
@@ -1,11 +1,11 @@
-
+
SwerveControllerConfiguration
-
+
diff --git a/docs/swervelib/parser/SwerveDriveConfiguration.html b/docs/swervelib/parser/SwerveDriveConfiguration.html
index cb2ced0..aa3c093 100644
--- a/docs/swervelib/parser/SwerveDriveConfiguration.html
+++ b/docs/swervelib/parser/SwerveDriveConfiguration.html
@@ -1,11 +1,11 @@
-
+
SwerveDriveConfiguration
-
+
diff --git a/docs/swervelib/parser/SwerveModuleConfiguration.html b/docs/swervelib/parser/SwerveModuleConfiguration.html
index 5987191..99c8bd9 100644
--- a/docs/swervelib/parser/SwerveModuleConfiguration.html
+++ b/docs/swervelib/parser/SwerveModuleConfiguration.html
@@ -1,11 +1,11 @@
-
+
SwerveModuleConfiguration
-
+
diff --git a/docs/swervelib/parser/SwerveModulePhysicalCharacteristics.html b/docs/swervelib/parser/SwerveModulePhysicalCharacteristics.html
index 7eb3c06..beee4d4 100644
--- a/docs/swervelib/parser/SwerveModulePhysicalCharacteristics.html
+++ b/docs/swervelib/parser/SwerveModulePhysicalCharacteristics.html
@@ -1,11 +1,11 @@
-
+
SwerveModulePhysicalCharacteristics
-
+
diff --git a/docs/swervelib/parser/SwerveParser.html b/docs/swervelib/parser/SwerveParser.html
index c75f7e0..e86369e 100644
--- a/docs/swervelib/parser/SwerveParser.html
+++ b/docs/swervelib/parser/SwerveParser.html
@@ -1,11 +1,11 @@
-
+
SwerveParser
-
+
diff --git a/docs/swervelib/parser/deserializer/PIDFRange.html b/docs/swervelib/parser/deserializer/PIDFRange.html
index 8b0d579..d3cdd9a 100644
--- a/docs/swervelib/parser/deserializer/PIDFRange.html
+++ b/docs/swervelib/parser/deserializer/PIDFRange.html
@@ -1,11 +1,11 @@
-
+
PIDFRange
-
+
diff --git a/docs/swervelib/parser/deserializer/package-summary.html b/docs/swervelib/parser/deserializer/package-summary.html
index b93b396..372bfa6 100644
--- a/docs/swervelib/parser/deserializer/package-summary.html
+++ b/docs/swervelib/parser/deserializer/package-summary.html
@@ -1,11 +1,11 @@
-
+
swervelib.parser.deserializer
-
+
diff --git a/docs/swervelib/parser/deserializer/package-tree.html b/docs/swervelib/parser/deserializer/package-tree.html
index cdd14e3..c2cb087 100644
--- a/docs/swervelib/parser/deserializer/package-tree.html
+++ b/docs/swervelib/parser/deserializer/package-tree.html
@@ -1,11 +1,11 @@
-
+
swervelib.parser.deserializer Class Hierarchy
-
+
diff --git a/docs/swervelib/parser/json/ControllerPropertiesJson.html b/docs/swervelib/parser/json/ControllerPropertiesJson.html
index 9267f53..4ee6d71 100644
--- a/docs/swervelib/parser/json/ControllerPropertiesJson.html
+++ b/docs/swervelib/parser/json/ControllerPropertiesJson.html
@@ -1,11 +1,11 @@
-
+
ControllerPropertiesJson
-
+
diff --git a/docs/swervelib/parser/json/DeviceJson.html b/docs/swervelib/parser/json/DeviceJson.html
index 8ec6a7d..ae82679 100644
--- a/docs/swervelib/parser/json/DeviceJson.html
+++ b/docs/swervelib/parser/json/DeviceJson.html
@@ -1,11 +1,11 @@
-
+
DeviceJson
-
+
diff --git a/docs/swervelib/parser/json/ModuleJson.html b/docs/swervelib/parser/json/ModuleJson.html
index 7c71911..1d3f15c 100644
--- a/docs/swervelib/parser/json/ModuleJson.html
+++ b/docs/swervelib/parser/json/ModuleJson.html
@@ -1,11 +1,11 @@
-
+
ModuleJson
-
+
diff --git a/docs/swervelib/parser/json/MotorConfigDouble.html b/docs/swervelib/parser/json/MotorConfigDouble.html
index 6b6f5b1..32ed154 100644
--- a/docs/swervelib/parser/json/MotorConfigDouble.html
+++ b/docs/swervelib/parser/json/MotorConfigDouble.html
@@ -1,11 +1,11 @@
-
+
MotorConfigDouble
-
+
diff --git a/docs/swervelib/parser/json/MotorConfigInt.html b/docs/swervelib/parser/json/MotorConfigInt.html
index 8b6b787..e8f16c1 100644
--- a/docs/swervelib/parser/json/MotorConfigInt.html
+++ b/docs/swervelib/parser/json/MotorConfigInt.html
@@ -1,11 +1,11 @@
-
+
MotorConfigInt
-
+
diff --git a/docs/swervelib/parser/json/PIDFPropertiesJson.html b/docs/swervelib/parser/json/PIDFPropertiesJson.html
index 9765457..02a2c5a 100644
--- a/docs/swervelib/parser/json/PIDFPropertiesJson.html
+++ b/docs/swervelib/parser/json/PIDFPropertiesJson.html
@@ -1,11 +1,11 @@
-
+
PIDFPropertiesJson
-
+
diff --git a/docs/swervelib/parser/json/PhysicalPropertiesJson.html b/docs/swervelib/parser/json/PhysicalPropertiesJson.html
index a4be922..be1a2f7 100644
--- a/docs/swervelib/parser/json/PhysicalPropertiesJson.html
+++ b/docs/swervelib/parser/json/PhysicalPropertiesJson.html
@@ -1,11 +1,11 @@
-
+
PhysicalPropertiesJson
-
+
diff --git a/docs/swervelib/parser/json/SwerveDriveJson.html b/docs/swervelib/parser/json/SwerveDriveJson.html
index b4ecbda..348418c 100644
--- a/docs/swervelib/parser/json/SwerveDriveJson.html
+++ b/docs/swervelib/parser/json/SwerveDriveJson.html
@@ -1,11 +1,11 @@
-
+
SwerveDriveJson
-
+
diff --git a/docs/swervelib/parser/json/modules/BoolMotorJson.html b/docs/swervelib/parser/json/modules/BoolMotorJson.html
index eee80c8..cc620aa 100644
--- a/docs/swervelib/parser/json/modules/BoolMotorJson.html
+++ b/docs/swervelib/parser/json/modules/BoolMotorJson.html
@@ -1,11 +1,11 @@
-
+
BoolMotorJson
-
+
diff --git a/docs/swervelib/parser/json/modules/LocationJson.html b/docs/swervelib/parser/json/modules/LocationJson.html
index 2014499..1036b85 100644
--- a/docs/swervelib/parser/json/modules/LocationJson.html
+++ b/docs/swervelib/parser/json/modules/LocationJson.html
@@ -1,11 +1,11 @@
-
+
LocationJson
-
+
diff --git a/docs/swervelib/parser/json/modules/package-summary.html b/docs/swervelib/parser/json/modules/package-summary.html
index 5cd47a1..0984e0e 100644
--- a/docs/swervelib/parser/json/modules/package-summary.html
+++ b/docs/swervelib/parser/json/modules/package-summary.html
@@ -1,11 +1,11 @@
-
+
swervelib.parser.json.modules
-
+
diff --git a/docs/swervelib/parser/json/modules/package-tree.html b/docs/swervelib/parser/json/modules/package-tree.html
index 17a07fb..60d7d66 100644
--- a/docs/swervelib/parser/json/modules/package-tree.html
+++ b/docs/swervelib/parser/json/modules/package-tree.html
@@ -1,11 +1,11 @@
-
+
swervelib.parser.json.modules Class Hierarchy
-
+
diff --git a/docs/swervelib/parser/json/package-summary.html b/docs/swervelib/parser/json/package-summary.html
index fd37ced..36d59cd 100644
--- a/docs/swervelib/parser/json/package-summary.html
+++ b/docs/swervelib/parser/json/package-summary.html
@@ -1,11 +1,11 @@
-
+
swervelib.parser.json
-
+
diff --git a/docs/swervelib/parser/json/package-tree.html b/docs/swervelib/parser/json/package-tree.html
index 2c547b6..318b395 100644
--- a/docs/swervelib/parser/json/package-tree.html
+++ b/docs/swervelib/parser/json/package-tree.html
@@ -1,11 +1,11 @@
-
+
swervelib.parser.json Class Hierarchy
-
+
diff --git a/docs/swervelib/parser/package-summary.html b/docs/swervelib/parser/package-summary.html
index d8f034d..ae9b8ed 100644
--- a/docs/swervelib/parser/package-summary.html
+++ b/docs/swervelib/parser/package-summary.html
@@ -1,11 +1,11 @@
-
+
swervelib.parser
-
+
diff --git a/docs/swervelib/parser/package-tree.html b/docs/swervelib/parser/package-tree.html
index 27a4918..1a2aaa9 100644
--- a/docs/swervelib/parser/package-tree.html
+++ b/docs/swervelib/parser/package-tree.html
@@ -1,11 +1,11 @@
-
+
swervelib.parser Class Hierarchy
-
+
diff --git a/docs/swervelib/simulation/SwerveIMUSimulation.html b/docs/swervelib/simulation/SwerveIMUSimulation.html
index aed15f4..57a71e6 100644
--- a/docs/swervelib/simulation/SwerveIMUSimulation.html
+++ b/docs/swervelib/simulation/SwerveIMUSimulation.html
@@ -1,11 +1,11 @@
-
+
SwerveIMUSimulation
-
+
diff --git a/docs/swervelib/simulation/SwerveModuleSimulation.html b/docs/swervelib/simulation/SwerveModuleSimulation.html
index 4baa7fc..c57628c 100644
--- a/docs/swervelib/simulation/SwerveModuleSimulation.html
+++ b/docs/swervelib/simulation/SwerveModuleSimulation.html
@@ -1,11 +1,11 @@
-
+
SwerveModuleSimulation
-
+
diff --git a/docs/swervelib/simulation/package-summary.html b/docs/swervelib/simulation/package-summary.html
index 016c9ea..5a25b6d 100644
--- a/docs/swervelib/simulation/package-summary.html
+++ b/docs/swervelib/simulation/package-summary.html
@@ -1,11 +1,11 @@
-
+
swervelib.simulation
-
+
diff --git a/docs/swervelib/simulation/package-tree.html b/docs/swervelib/simulation/package-tree.html
index 73d8d44..ed83aef 100644
--- a/docs/swervelib/simulation/package-tree.html
+++ b/docs/swervelib/simulation/package-tree.html
@@ -1,11 +1,11 @@
-
+
swervelib.simulation Class Hierarchy
-
+
diff --git a/docs/swervelib/telemetry/Alert.AlertType.html b/docs/swervelib/telemetry/Alert.AlertType.html
index d86e64f..94d04a0 100644
--- a/docs/swervelib/telemetry/Alert.AlertType.html
+++ b/docs/swervelib/telemetry/Alert.AlertType.html
@@ -1,11 +1,11 @@
-
+
Alert.AlertType
-
+
diff --git a/docs/swervelib/telemetry/Alert.SendableAlerts.html b/docs/swervelib/telemetry/Alert.SendableAlerts.html
index 02412e2..8baf177 100644
--- a/docs/swervelib/telemetry/Alert.SendableAlerts.html
+++ b/docs/swervelib/telemetry/Alert.SendableAlerts.html
@@ -1,11 +1,11 @@
-
+
Alert.SendableAlerts
-
+
diff --git a/docs/swervelib/telemetry/Alert.html b/docs/swervelib/telemetry/Alert.html
index 4405af4..cc70129 100644
--- a/docs/swervelib/telemetry/Alert.html
+++ b/docs/swervelib/telemetry/Alert.html
@@ -1,11 +1,11 @@
-
+
Alert
-
+
diff --git a/docs/swervelib/telemetry/SwerveDriveTelemetry.TelemetryVerbosity.html b/docs/swervelib/telemetry/SwerveDriveTelemetry.TelemetryVerbosity.html
index 7d58db8..e8ebf7c 100644
--- a/docs/swervelib/telemetry/SwerveDriveTelemetry.TelemetryVerbosity.html
+++ b/docs/swervelib/telemetry/SwerveDriveTelemetry.TelemetryVerbosity.html
@@ -1,11 +1,11 @@
-
+
SwerveDriveTelemetry.TelemetryVerbosity
-
+
@@ -113,18 +113,26 @@ loadScripts(document, 'script');
Full swerve drive data is sent back in both human and machine readable forms.
-
+
+Medium telemetry data, swerve directory
+
+
+
Low telemetry data, only post the robot position on the field.
-
-
+
+
Only send the machine readable data related to swerve drive.
-
-
@@ -200,6 +208,20 @@ the order they are declared.
+
+INFO
+
+Medium telemetry data, swerve directory
+
+
+
+
+POSE
+
+Info level + field info
+
+
+
HIGH
diff --git a/docs/swervelib/telemetry/SwerveDriveTelemetry.html b/docs/swervelib/telemetry/SwerveDriveTelemetry.html
index f2fd7ba..d0426af 100644
--- a/docs/swervelib/telemetry/SwerveDriveTelemetry.html
+++ b/docs/swervelib/telemetry/SwerveDriveTelemetry.html
@@ -1,11 +1,11 @@
-
+
SwerveDriveTelemetry
-
+
diff --git a/docs/swervelib/telemetry/package-summary.html b/docs/swervelib/telemetry/package-summary.html
index e4777b0..38c9b76 100644
--- a/docs/swervelib/telemetry/package-summary.html
+++ b/docs/swervelib/telemetry/package-summary.html
@@ -1,11 +1,11 @@
-
+
swervelib.telemetry
-
+
diff --git a/docs/swervelib/telemetry/package-tree.html b/docs/swervelib/telemetry/package-tree.html
index a29de93..fd924bf 100644
--- a/docs/swervelib/telemetry/package-tree.html
+++ b/docs/swervelib/telemetry/package-tree.html
@@ -1,11 +1,11 @@
-
+
swervelib.telemetry Class Hierarchy
-
+
diff --git a/swervelib/SwerveDriveTest.java b/swervelib/SwerveDriveTest.java
index 85d9a45..848852c 100644
--- a/swervelib/SwerveDriveTest.java
+++ b/swervelib/SwerveDriveTest.java
@@ -360,7 +360,8 @@ public class SwerveDriveTest
double velocity = module.getAbsoluteEncoder().getVelocity();
SmartDashboard.putNumber("swerve/modules/" + module.configuration.name + "/SysId Angle Power", power);
SmartDashboard.putNumber("swerve/modules/" + module.configuration.name + "/SysId Angle Position", angle);
- SmartDashboard.putNumber("swerve/modules/" + module.configuration.name + "/SysId Absolute Encoder Velocity", velocity);
+ SmartDashboard.putNumber("swerve/modules/" + module.configuration.name + "/SysId Absolute Encoder Velocity",
+ velocity);
log.motor("angle-" + module.configuration.name)
.voltage(m_appliedVoltage.mut_replace(power, Volts))
.angularPosition(m_anglePosition.mut_replace(angle, Degrees))
diff --git a/swervelib/SwerveModule.java b/swervelib/SwerveModule.java
index 756ef79..1e94179 100644
--- a/swervelib/SwerveModule.java
+++ b/swervelib/SwerveModule.java
@@ -379,8 +379,10 @@ public class SwerveModule
if (SwerveDriveTelemetry.verbosity == TelemetryVerbosity.HIGH)
{
- SmartDashboard.putNumber("swerve/modules/" + configuration.name + "/Speed Setpoint", desiredState.speedMetersPerSecond);
- SmartDashboard.putNumber("swerve/modules/" + configuration.name + "/Angle Setpoint", desiredState.angle.getDegrees());
+ SmartDashboard.putNumber("swerve/modules/" + configuration.name + "/Speed Setpoint",
+ desiredState.speedMetersPerSecond);
+ SmartDashboard.putNumber("swerve/modules/" + configuration.name + "/Angle Setpoint",
+ desiredState.angle.getDegrees());
}
}
diff --git a/swervelib/math/SwerveMath.java b/swervelib/math/SwerveMath.java
index a808d7a..eb7de87 100644
--- a/swervelib/math/SwerveMath.java
+++ b/swervelib/math/SwerveMath.java
@@ -410,4 +410,27 @@ public class SwerveMath
moduleState.angle = lastModuleState.angle;
}
}
+
+ /**
+ * Cube the {@link Translation2d} magnitude given in Polar coordinates.
+ *
+ * @param translation {@link Translation2d} to manipulate.
+ * @return Cubed magnitude from {@link Translation2d}.
+ */
+ public static Translation2d cubeTranslation(Translation2d translation)
+ {
+ return new Translation2d(Math.pow(translation.getNorm(), 3), translation.getAngle());
+ }
+
+ /**
+ * Scale the {@link Translation2d} Polar coordinate magnitude.
+ *
+ * @param translation {@link Translation2d} to use.
+ * @param scalar Multiplier for the Polar coordinate magnitude to use.
+ * @return {@link Translation2d} scaled by given magnitude scalar.
+ */
+ public static Translation2d scaleTranslation(Translation2d translation, double scalar)
+ {
+ return new Translation2d(translation.getNorm() * scalar, translation.getAngle());
+ }
}