diff --git a/wpilibcExamples/src/main/cpp/examples/MecanumControllerCommand/cpp/subsystems/DriveSubsystem.cpp b/wpilibcExamples/src/main/cpp/examples/MecanumControllerCommand/cpp/subsystems/DriveSubsystem.cpp index bd80ad9284..8d357f429f 100644 --- a/wpilibcExamples/src/main/cpp/examples/MecanumControllerCommand/cpp/subsystems/DriveSubsystem.cpp +++ b/wpilibcExamples/src/main/cpp/examples/MecanumControllerCommand/cpp/subsystems/DriveSubsystem.cpp @@ -48,8 +48,8 @@ void DriveSubsystem::Periodic() { } void DriveSubsystem::Drive(double xSpeed, double ySpeed, double rot, - bool feildRelative) { - if (feildRelative) { + bool fieldRelative) { + if (fieldRelative) { m_drive.DriveCartesian(ySpeed, xSpeed, rot, -m_gyro.GetAngle()); } else { m_drive.DriveCartesian(ySpeed, xSpeed, rot); diff --git a/wpilibcExamples/src/main/cpp/examples/MecanumControllerCommand/include/subsystems/DriveSubsystem.h b/wpilibcExamples/src/main/cpp/examples/MecanumControllerCommand/include/subsystems/DriveSubsystem.h index 3313596f77..f27155be93 100644 --- a/wpilibcExamples/src/main/cpp/examples/MecanumControllerCommand/include/subsystems/DriveSubsystem.h +++ b/wpilibcExamples/src/main/cpp/examples/MecanumControllerCommand/include/subsystems/DriveSubsystem.h @@ -39,7 +39,7 @@ class DriveSubsystem : public frc2::SubsystemBase { * @param fieldRelative Whether the provided x and y speeds are relative to * the field. */ - void Drive(double xSpeed, double ySpeed, double rot, bool feildRelative); + void Drive(double xSpeed, double ySpeed, double rot, bool fieldRelative); /** * Resets the drive encoders to currently read a position of 0. diff --git a/wpilibcExamples/src/main/cpp/examples/SwerveControllerCommand/include/subsystems/DriveSubsystem.h b/wpilibcExamples/src/main/cpp/examples/SwerveControllerCommand/include/subsystems/DriveSubsystem.h index 9fd548cffd..4cabdc67c1 100644 --- a/wpilibcExamples/src/main/cpp/examples/SwerveControllerCommand/include/subsystems/DriveSubsystem.h +++ b/wpilibcExamples/src/main/cpp/examples/SwerveControllerCommand/include/subsystems/DriveSubsystem.h @@ -43,7 +43,7 @@ class DriveSubsystem : public frc2::SubsystemBase { */ void Drive(units::meters_per_second_t xSpeed, units::meters_per_second_t ySpeed, units::radians_per_second_t rot, - bool feildRelative); + bool fieldRelative); /** * Resets the drive encoders to currently read a position of 0.