Package xbot.common.trajectory
Class SwerveSimpleTrajectoryLogic
java.lang.Object
xbot.common.trajectory.SwerveSimpleTrajectoryLogic
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncalculatePowers
(Pose2d currentPose, PIDManager positionalPid, HeadingModule headingModule) calculatePowers
(Pose2d currentPose, PIDManager positionalPid, HeadingModule headingModule, double maximumVelocity) getGoalVector
(Pose2d currentPose) boolean
recommendIsFinished
(Pose2d currentPose, PIDManager positionalPid, HeadingModule headingModule) void
void
setAimAtGoalDuringFinalLeg
(boolean aimAtGoalDuringFinalLeg) void
setAimAtIntermediateNonFinalLegs
(boolean aimAtIntermediateNonFinalLegs) void
setConstantVelocity
(double constantVelocity) void
setDistanceThresholdToPrioritizeRotation
(double distanceThresholdToPrioritizeRotation) void
setDriveBackwards
(boolean driveBackwards) void
setEnableSpecialAimDuringFinalLeg
(boolean enableSpecialAimDuringFinalLeg) void
setEnableSpecialAimTarget
(boolean enableSpecialAimTarget) void
setGlobalKinematicValues
(SwervePointKinematics globalKinematics) void
setKeyPoints
(List<XbotSwervePoint> keyPoints) void
setKeyPointsProvider
(Supplier<List<XbotSwervePoint>> keyPointsProvider) void
setMaxPower
(double maxPower) void
setMaxTurningPower
(double maxTurningPower) void
setPrioritizeRotationIfCloseToGoal
(boolean prioritizeRotationIfCloseToGoal) setRotationPrioritizationScaleback
(double rotationPrioritizationScaleback) void
setSpecialAimTarget
(Pose2d specialAimTarget) void
setStopWhenFinished
(boolean newValue) void
void
setWaypointRouter
(ProvidesWaypoints waypointRouter)
-
Constructor Details
-
SwerveSimpleTrajectoryLogic
-
-
Method Details
-
setEnableSpecialAimTarget
public void setEnableSpecialAimTarget(boolean enableSpecialAimTarget) -
setRotationPrioritizationScaleback
public SwerveSimpleTrajectoryLogic setRotationPrioritizationScaleback(double rotationPrioritizationScaleback) -
setEnableSpecialAimDuringFinalLeg
public void setEnableSpecialAimDuringFinalLeg(boolean enableSpecialAimDuringFinalLeg) -
setSpecialAimTarget
-
setAimAtGoalDuringFinalLeg
public void setAimAtGoalDuringFinalLeg(boolean aimAtGoalDuringFinalLeg) -
setAimAtIntermediateNonFinalLegs
public void setAimAtIntermediateNonFinalLegs(boolean aimAtIntermediateNonFinalLegs) -
setDriveBackwards
public void setDriveBackwards(boolean driveBackwards) -
setWaypointRouter
-
setKeyPoints
-
setKeyPointsProvider
-
setMaxPower
public void setMaxPower(double maxPower) -
setMaxTurningPower
public void setMaxTurningPower(double maxTurningPower) -
getKeyPoints
-
getResolvedKeyPoints
-
setStopWhenFinished
public void setStopWhenFinished(boolean newValue) -
setPrioritizeRotationIfCloseToGoal
public void setPrioritizeRotationIfCloseToGoal(boolean prioritizeRotationIfCloseToGoal) -
setDistanceThresholdToPrioritizeRotation
public void setDistanceThresholdToPrioritizeRotation(double distanceThresholdToPrioritizeRotation) -
setVelocityMode
-
setConstantVelocity
public void setConstantVelocity(double constantVelocity) -
setGlobalKinematicValues
-
reset
-
getGoalVector
-
calculatePowers
public Twist2d calculatePowers(Pose2d currentPose, PIDManager positionalPid, HeadingModule headingModule) -
calculatePowers
public Twist2d calculatePowers(Pose2d currentPose, PIDManager positionalPid, HeadingModule headingModule, double maximumVelocity) -
recommendIsFinished
public boolean recommendIsFinished(Pose2d currentPose, PIDManager positionalPid, HeadingModule headingModule) -
getLastResult
-