Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Java (http://www.chiefdelphi.com/forums/forumdisplay.php?f=184)
-   -   Talon SRX Encoder (http://www.chiefdelphi.com/forums/showthread.php?t=143454)

dukeeagle 08-02-2016 17:40

Talon SRX Encoder
 
We are trying to figure out how to get the number of rotations on our encoder through our CANTalon.
The FRC website offers a solution if you use the Encoder class, but we are doing it through the wpilib CANTalon class.
Here's what we have so far:
Code:

          CANTalon frontLeft = new CANTalon(RobotMap.frontLeft);

          public encoder(){
                frontLeft.changeControlMode(ControlMode.Position);
                frontLeft.setFeedbackDevice(FeedbackDevice.QuadEncoder);
                frontLeft.setPID(0.5, 0.001, 0.0);
                frontLeft.enableControl();
        }

Is there a way to do this through the CANTalon class? Help is much appreciated.

Ether 08-02-2016 17:46

Re: Talon SRX Encoder
 

Have you looked at Section 20 of the Talon SRX Software Reference Manual ?




All times are GMT -5. The time now is 08:29.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi