You use Phoenix libraries. The user guide tells to use the same line of code the you would use in a TalonSRX. However the TalonSRX doesn’t have a built in encoder. So how come? Any help?
I’m unfamiliar with TalonFXs, but with TalonSRXs, they have a method called getSelectedSensorPosition(), there’s also a more advanced object with more data that you can use called getSensorCollection().