-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Se/swerve commands #11
Conversation
Co-authored-by: Tmanxyz <Tmanxyz@users.noreply.github.com> Co-authored-by: metereel <Material-Energy@users.noreply.github.com> Co-authored-by: alex <alex-wanger@users.noreply.github.com> Co-authored-by: rzheng287 <rzheng287@users.noreply.github.com>
Co-authored-by: Tmanxyz <Tmanxyz@users.noreply.github.com> Co-authored-by: metereel <Material-Energy@users.noreply.github.com> Co-authored-by: alex <alex-wanger@users.noreply.github.com> Co-authored-by: rzheng287 <rzheng287@users.noreply.github.com>
Co-authored-by: naveed1117 <naveed1117@users.noreply.github.com> Co-authored-by: jopy-man <jopy-man@users.noreply.github.com> Co-authored-by: Tmanxyz <Tmanxyz@users.noreply.github.com>
private Pose2d getSpeakerTargetPose(Rotation2d angleToSpeaker) { | ||
//Everything under is from aiming at center of speaker | ||
Vector2D robotPose = new Vector2D(Odometry.getInstance().getPose().getTranslation()); | ||
Vector2D targetPose = new Vector2D(this.targetPose.getTranslation()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interpolate between target poses +- certain y distance from the center of the speaker to adjust the point which the robot will aim at for shooting.
private final HolonomicController controller; | ||
private final FieldObject2d targetPose2d; | ||
|
||
public SwerveDriveToShoot(Pose2d targetPose) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove unused targetPose param
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This command is supposed to align from any point on the field to a certain shooting distance away from the speaker and to point at the speaker target position. then shoot.
Merge branch 'main' of https://github.com/StuyPulse/BigWang into se/swerve-commands
SwerveDrivetoShoot doesnt work as intended
SwerveDriveXMode should be tested on real robot