15 #include <networktables/NetworkTableEntry.h> 16 #include <support/mutex.h> 18 #include "Commands/Command.h" 19 #include "ErrorBase.h" 20 #include "SmartDashboard/SendableBase.h" 38 void SetEnabled(
bool enabled);
46 void ProcessCommandAddition(
Command* command);
48 Command::SubsystemSet m_subsystems;
49 wpi::mutex m_buttonsMutex;
50 typedef std::vector<ButtonScheduler*> ButtonVector;
51 ButtonVector m_buttons;
52 typedef std::vector<Command*> CommandVector;
53 wpi::mutex m_additionsMutex;
54 CommandVector m_additions;
55 typedef std::set<Command*> CommandSet;
56 CommandSet m_commands;
57 bool m_adding =
false;
58 bool m_enabled =
true;
59 std::vector<std::string> commands;
60 std::vector<double> ids;
61 std::vector<double> toCancel;
65 bool m_runningCommandsChanged =
false;
void AddCommand(Command *command)
Add a command to be scheduled later.
Definition: Scheduler.cpp:46
void Run()
Runs a single iteration of the loop.
Definition: Scheduler.cpp:116
Definition: RobotController.cpp:14
void RegisterSubsystem(Subsystem *subsystem)
Registers a Subsystem to this Scheduler, so that the Scheduler might know if a default Command needs ...
Definition: Scheduler.cpp:178
Definition: Subsystem.h:23
void InitSendable(SendableBuilder &builder) override
Initializes this Sendable object.
Definition: Scheduler.cpp:228
void ResetAll()
Completely resets the scheduler.
Definition: Scheduler.cpp:217
static Scheduler * GetInstance()
Returns the Scheduler, creating it if one does not exist.
Definition: Scheduler.cpp:31
Base class for most objects.
Definition: ErrorBase.h:74
void Remove(Command *command)
Removes the Command from the Scheduler.
Definition: Scheduler.cpp:191
Definition: SendableBase.h:19
Definition: SendableBuilder.h:23
NetworkTables Entry.
Definition: NetworkTableEntry.h:35
The Command class is at the very core of the entire command framework.
Definition: Command.h:48
Definition: Scheduler.h:27