From c75d7f9f2e935847271b0efabd76b957fc76a547 Mon Sep 17 00:00:00 2001 From: CoryNessCTR Date: Thu, 26 Oct 2023 10:29:52 -0400 Subject: [PATCH] Rename get speeds so it's clear they're robot relative speeds --- .../src/main/java/frc/robot/CommandSwerveDrivetrain.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/java/SwerveWithPathPlanner/src/main/java/frc/robot/CommandSwerveDrivetrain.java b/java/SwerveWithPathPlanner/src/main/java/frc/robot/CommandSwerveDrivetrain.java index 3684b547..884b426b 100644 --- a/java/SwerveWithPathPlanner/src/main/java/frc/robot/CommandSwerveDrivetrain.java +++ b/java/SwerveWithPathPlanner/src/main/java/frc/robot/CommandSwerveDrivetrain.java @@ -38,7 +38,7 @@ private void configurePathPlanner() { AutoBuilder.configureHolonomic( ()->this.getState().Pose, // Supplier of current robot pose this::seedFieldRelative, // Consumer for seeding pose against auto - this::getCurrentSpeeds, + this::getCurrentRobotChassisSpeeds, (speeds)->this.setControl(autoRequest.withSpeeds(speeds)), // Consumer of ChassisSpeeds to drive the robot new HolonomicPathFollowerConfig(new PIDConstants(10, 0, 0), new PIDConstants(10, 0, 0), @@ -79,7 +79,7 @@ public void seedFieldRelative(Pose2d location) { } } - public ChassisSpeeds getCurrentSpeeds() { + public ChassisSpeeds getCurrentRobotChassisSpeeds() { return m_kinematics.toChassisSpeeds(getState().ModuleStates); } }