Hello, I’m prepping code now before anything is built because I know the rough logic of what will be done and how to do it for our robot this year. One of the things I was running into while writing the base program for our shooter is getting velocity from a Talon SRX Quadrature encoder. I know how to get it back but don’t know what to expect as a return value. I haven’t been able to find a clear answer in the documentation. Any help is appreciated.
So if ur wanting to get rpm u divide the value by ur encoder(for the ctre mag encoder its 4096) multiple by 10 to get to seconds then multiple by 60 to get to minutes
Thank you this is what I needed. I’m programming in Labview and wrongly assumed that other languages would have the same or very similar documentation.
Much Appreciated!
@AlexanderDeFuria Take a look at our documentation here:
I advise going through the setup process, including the Talon SRX bring up and Talon SRX Sensors bring up section which will walk through the features and API calls.
@jpeadebo
That function call is from the legacy, Pre-Phoenix API (pre-2018).
The equivalent function call in Phoenix would be TalonSRX.getSelectedSensorVelocity()
http://www.ctr-electronics.com/downloads/api/java/html/classcom_1_1ctre_1_1phoenix_1_1motorcontrol_1_1can_1_1_base_motor_controller.html#ac32c42e4f01f0a9c6b9535257bd02d95
If you’re using LabVIEW, all of the regular status data for TalonSRX comes from the Get VI.
The velocity value is in Raw Sensor Units per 100ms.
If you’re using an SRX Magnetic encoder, there’s 4096 units per rotation.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.