[commands] Add constructor for SwerveControllerCommand that takes a HolonomicDriveController (#4785)

Also adds copy and move constructors to HolonomicDriveController.
This commit is contained in:
Ryan Blue
2022-12-25 21:48:27 -05:00
committed by GitHub
parent 1e7fcd5637
commit 6efb9ee405
4 changed files with 282 additions and 14 deletions

View File

@@ -45,6 +45,12 @@ class WPILIB_DLLEXPORT HolonomicDriveController {
frc2::PIDController xController, frc2::PIDController yController,
ProfiledPIDController<units::radian> thetaController);
HolonomicDriveController(const HolonomicDriveController&) = default;
HolonomicDriveController& operator=(const HolonomicDriveController&) =
default;
HolonomicDriveController(HolonomicDriveController&&) = default;
HolonomicDriveController& operator=(HolonomicDriveController&&) = default;
/**
* Returns true if the pose error is within tolerance of the reference.
*/