Changing the end of a Ramsete Command

We are trying to do some funky things for our autonomous. We are using a ramsete controller and ramsete command and switching from our auto driving to a ball tracking algorithm. When it switches to the ball tracking commands it stops the currently driving robot for a half a second and then continues. In the ramsete command in the end() method it sets the output to 0 is there any way to override the end method or circumvent the method in a way?

You probably want to do something like this? Derive a new command from your existing Ramsete command, and then override the end function. Then use the derived command instead of the original one in your autonomous sequence.

public class MyRamseteCommandWithoutStop extends MyRamseteCommand {

    @Override
    public void end(boolean interrupted) {
        // Do nothing here.
    }
}

You can use the TrajectoryConstraint.setEndVelocity(velocity) method to keep the robot rolling at the end of the command.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.