Falcon 500 Encoder Problems

Hey everybody,
We are having some issues getting our Talon FX encoders to work. We are connected to a Falcon 500, wired up with CAN, and are using Phoenix Tuner as directed in the documentation. We can connect to (and run with output percent) the motor at will, but the encoder does not return a value in the “plot” tab. The plot tab shows correct percent output, but encoder position and velocity always remain at zero, whether the motor is being run, hand turned, or left alone. Additionally, when we run our code, the talonSRX methods getSelectedSensorPosition() and getSelectedSensorVelocity() ,which are supposed to return the encoder position and velocity, always return zero. Any ideas as for what could be causing this issue?
Thanks.

Assuming this is your Github, you set up the encoders on the Falcons like this:
leftDrive.configSelectedFeedbackSensor(FeedbackDevice.QuadEncoder, PID_TYPE, DEFAULT_TIMEOUT);

Two things: One, you initialize your Falcons as TalonSRX and not as TalonFX. Second, to initialize an internal encoder, you need to write it like this:

leftDrive.configSelectedFeedbackSensor(FeedbackDevice.IntegratedSensor, PID_TYPE, DEFAULT_TIMEOUT);

Thanks for the help! We will try that out

I think you don’t have to configure a feedback sensor for the Talon FX.

You do, you do it exactly as jdao showed it.

I agree. Also I’m curious how many quotes we can embed.

Don’t select quadrature, there is no quadrature port on FX.

Its worth noting that if you create a TalonFX, and use configAllSettings() and the corresponding configAll object, the default value for selected feedback device is also Integrated-Sensor.

2 Likes

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