Class MoveUnjamComprisedCommand¶
Defined in File move_unjam_comprised_command.hpp
Inheritance Relationships¶
Base Type¶
public tap::control::ComprisedCommand(Class ComprisedCommand)
Class Documentation¶
-
class MoveUnjamComprisedCommand : public tap::control::ComprisedCommand¶
A comprised command that combines the unjam and move commands.
Assuming no jams occur, this command behaves like a MoveCommand. It will schedule once and end once the target displacement is reached. If it gets jammed while trying to move then the command will then schedule a UnjamCommand. At this point the command will end when the UnjamCommand ends.
See
UnjamCommandandMoveCommandfor more details on their respective logic.Public Functions
-
MoveUnjamComprisedCommand(tap::Drivers *drivers, SetpointSubsystem *setpointSubsystem, float moveDisplacement, uint32_t moveTime, uint32_t pauseAfterMoveTime, bool setToTargetOnEnd, float setpointTolerance, float unjamDisplacement, float unjamThreshold, uint32_t maxUnjamWaitTime, uint_fast16_t unjamCycleCount)¶
- Parameters:
drivers – [in] A pointer to the
Driversstruct.setpointSubsystem – [in] The subsystem to interact with.
moveDisplacement – [in] The displacement the command will apply to the subsystem
moveTime – [in] See
MoveCommandfor more details, passed on directly to its constructor.pauseAfterMoveTime – [in] See
MoveCommandfor more details, passed on directly to its constructor.setToTargetOnEnd – [in] See
MoveCommandfor more details, passed on directly to its constructor.setpointTolerance – [in] See
MoveCommandfor more details, passed on directly to its constructor.unjamDisplacement – [in] See
UnjamCommand’s constructor for more details, passed on directly to this command’s constructor.unjamThreshold – [in] See
UnjamCommand’s constructor for more details, passed on directly to this command’s constructor.unjamCycleCount – [in] See
UnjamCommand’s constructor for more details, passed on directly to this command’s constructor.maxUnjamWaitTime – [in] See
UnjamCommand’s constructor for more details, passed on directly to this command’s constructor.
-
virtual void initialize() override¶
-
virtual void execute() override¶
-
virtual void end(bool interrupted) override¶
-
virtual bool isFinished() const override¶
-
inline virtual const char *getName() const override¶
Protected Attributes
-
SetpointSubsystem *setpointSubsystem¶
-
MoveCommand agitatorRotateCommand¶
-
UnjamCommand agitatorUnjamCommand¶
-
bool unjamSequenceCommencing¶
-
bool agitatorDisconnectFault¶
-
MoveUnjamComprisedCommand(tap::Drivers *drivers, SetpointSubsystem *setpointSubsystem, float moveDisplacement, uint32_t moveTime, uint32_t pauseAfterMoveTime, bool setToTargetOnEnd, float setpointTolerance, float unjamDisplacement, float unjamThreshold, uint32_t maxUnjamWaitTime, uint_fast16_t unjamCycleCount)¶