mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-20 00:51:42 +00:00
[docs] Add missing JavaDocs (#6146)
This commit is contained in:
@@ -426,6 +426,7 @@ class Command : public wpi::Sendable, public wpi::SendableHelper<Command> {
|
||||
protected:
|
||||
Command();
|
||||
|
||||
/// Requirements set.
|
||||
wpi::SmallSet<Subsystem*, 4> m_requirements;
|
||||
|
||||
/**
|
||||
|
||||
@@ -74,9 +74,16 @@ class PIDCommand : public CommandHelper<Command, PIDCommand> {
|
||||
frc::PIDController& GetController();
|
||||
|
||||
protected:
|
||||
/// PID controller.
|
||||
frc::PIDController m_controller;
|
||||
|
||||
/// Measurement getter.
|
||||
std::function<double()> m_measurement;
|
||||
|
||||
/// Setpoint getter.
|
||||
std::function<double()> m_setpoint;
|
||||
|
||||
/// PID controller output consumer.
|
||||
std::function<void(double)> m_useOutput;
|
||||
};
|
||||
} // namespace frc2
|
||||
|
||||
@@ -69,7 +69,10 @@ class PIDSubsystem : public SubsystemBase {
|
||||
frc::PIDController& GetController();
|
||||
|
||||
protected:
|
||||
/// PID controller.
|
||||
frc::PIDController m_controller;
|
||||
|
||||
/// Whether PID controller output is enabled.
|
||||
bool m_enabled{false};
|
||||
|
||||
/**
|
||||
|
||||
@@ -139,9 +139,16 @@ class ProfiledPIDCommand
|
||||
frc::ProfiledPIDController<Distance>& GetController() { return m_controller; }
|
||||
|
||||
protected:
|
||||
/// Profiled PID controller.
|
||||
frc::ProfiledPIDController<Distance> m_controller;
|
||||
|
||||
/// Measurement getter.
|
||||
std::function<Distance_t()> m_measurement;
|
||||
|
||||
/// Goal getter.
|
||||
std::function<State()> m_goal;
|
||||
|
||||
/// Profiled PID controller output consumer.
|
||||
std::function<void(double, State)> m_useOutput;
|
||||
};
|
||||
} // namespace frc2
|
||||
|
||||
@@ -91,7 +91,10 @@ class ProfiledPIDSubsystem : public SubsystemBase {
|
||||
frc::ProfiledPIDController<Distance>& GetController() { return m_controller; }
|
||||
|
||||
protected:
|
||||
/// Profiled PID controller.
|
||||
frc::ProfiledPIDController<Distance> m_controller;
|
||||
|
||||
/// Whether the profiled PID controller output is enabled.
|
||||
bool m_enabled{false};
|
||||
|
||||
/**
|
||||
|
||||
@@ -41,6 +41,7 @@ class WaitCommand : public CommandHelper<Command, WaitCommand> {
|
||||
void InitSendable(wpi::SendableBuilder& builder) override;
|
||||
|
||||
protected:
|
||||
/// The timer used for waiting.
|
||||
frc::Timer m_timer;
|
||||
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user