Skip to content

Elevator may not hold position between commands in auto #2

Description

@JershJopstin

You may find the elevator doesn't hold position between elevator commands in auto. Emerson correctly deduced this would occur, and added a call to start_elevatorMotor() in autonomousPeriodic() to force it to hold the position every loop; however, this contributed to the speed up issue we saw yesterday, as the command itself also calls start_elevatorMotor(), leading to it getting called an extra time while the command is running.

A potential fix would be to add a start_elevatorMotor() call back to autonomousPeriodic(), while removing that line from this function: https://github.com/FRC-4750-Bishop-Eustace/Bert_XIII/blob/8496ee48b562273df61fd5ebb0ef9d23fea0daab/BertXIII/robot.py#L402C3-L403C52

That way, the command just updates the setpoint, while autonomousPeriodic() will handle calling the function to update the elevator voltage.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions