Uses of Interface
edu.wpi.first.wpilibj2.command.Subsystem
Package | Description |
---|---|
edu.wpi.first.wpilibj2.command |
-
Uses of Subsystem in edu.wpi.first.wpilibj2.command
Classes in edu.wpi.first.wpilibj2.command that implement Subsystem Modifier and Type Class Description class
PIDSubsystem
A subsystem that uses aPIDController
to control an output.class
SubsystemBase
A base for subsystems that handles registration in the constructor, and provides a more intuitive method for setting the default command.Methods in edu.wpi.first.wpilibj2.command that return types with arguments of type Subsystem Modifier and Type Method Description java.util.Set<Subsystem>
Command. getRequirements()
Specifies the set of subsystems used by this command.java.util.Set<Subsystem>
CommandBase. getRequirements()
Methods in edu.wpi.first.wpilibj2.command with parameters of type Subsystem Modifier and Type Method Description void
CommandBase. addRequirements(Subsystem... requirements)
Adds the specified requirements to the command.Command
CommandScheduler. getDefaultCommand(Subsystem subsystem)
Gets the default command associated with this subsystem.default boolean
Command. hasRequirement(Subsystem requirement)
Whether the command requires a given subsystem.void
CommandScheduler. registerSubsystem(Subsystem... subsystems)
Registers subsystems with the scheduler.Command
CommandScheduler. requiring(Subsystem subsystem)
Returns the command currently requiring a given subsystem.void
CommandScheduler. setDefaultCommand(Subsystem subsystem, Command defaultCommand)
Sets the default command for a subsystem.void
CommandScheduler. unregisterSubsystem(Subsystem... subsystems)
Un-registers subsystems with the scheduler.Constructors in edu.wpi.first.wpilibj2.command with parameters of type Subsystem Constructor Description FunctionalCommand(java.lang.Runnable onInit, java.lang.Runnable onExecute, java.util.function.Consumer<java.lang.Boolean> onEnd, java.util.function.BooleanSupplier isFinished, Subsystem... requirements)
Creates a new FunctionalCommand.InstantCommand(java.lang.Runnable toRun, Subsystem... requirements)
Creates a new InstantCommand that runs the given Runnable with the given requirements.NotifierCommand(java.lang.Runnable toRun, double period, Subsystem... requirements)
Creates a new NotifierCommand.PIDCommand(PIDController controller, java.util.function.DoubleSupplier measurementSource, double setpoint, java.util.function.DoubleConsumer useOutput, Subsystem... requirements)
Creates a new PIDCommand, which controls the given output with a PIDController.PIDCommand(PIDController controller, java.util.function.DoubleSupplier measurementSource, java.util.function.DoubleSupplier setpointSource, java.util.function.DoubleConsumer useOutput, Subsystem... requirements)
Creates a new PIDCommand, which controls the given output with a PIDController.RunCommand(java.lang.Runnable toRun, Subsystem... requirements)
Creates a new RunCommand.StartEndCommand(java.lang.Runnable onInit, java.lang.Runnable onEnd, Subsystem... requirements)
Creates a new StartEndCommand.