Skip to content

Allow user to specify the sensor position value to reset to when a limit switch closes #2

@DeanDavis

Description

@DeanDavis

I have an arm that moves linearly and a Talon SRX controlling a motor that runs the arm out when forward and back when motor is in reverse.

I have limit switches at the ends of travel of the arm.
So, the sensor (quad encoder) of the motor reads 0 when the arm is in its most extended and 10660 when it is most retracted.

When the forward limit switch closes it is terrific to have the Talon auto set the encoder to 0.
But, I'd like to be able to program the Talon to set the encoder value to 10660 (or obviously any value) when the rear limit switch is triggered. Right now it can only reset to 0.

To overcome I have to watch the rear limit switch value in periodic tasks and if true then I set the sensor position to 10660 using "Set Sensor Pos" VI.

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