|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
|||
|
|||
|
Re: Using Encoders with TalonSRX
Ok, I just thought set() was something else that applied to CANTalon modes and PID control. I figured out that the set() values in speed mode go from 0 to 1000. Everything works now. Thank you so much for your help!
|
|
#2
|
||||
|
||||
|
Re: Using Encoders with TalonSRX
Quote:
So do you see how in section 17.1 (Talon SRX software reference manual) the example math for a CPR=360 quadrature encoder calculates a speed of 28800 for 20 rotations per second (or RPM=1200)? So set(28800) would servo a velocity of 1200RPM in the positive direction IF using a quad encoder (that's CPR=360). Make sense? |
|
#3
|
|||
|
|||
|
Re: Using Encoders with TalonSRX
Ohhh. Our encoder is the E4P-250-250-D-D-D-B. I don't know the CPR, is it 250? If we set the speed to 500, the encoder reads a velocity of 300.
|
|
#4
|
||||
|
||||
|
Re: Using Encoders with TalonSRX
Quote:
Quote:
Last edited by Ether : 11-02-2015 at 17:58. |
|
#5
|
|||
|
|||
|
Re: Using Encoders with TalonSRX
Thanks! How many rotations would the encoder have then? I don't know where to find the setpoint-process_variable error, but the ClosedLoopError variable in the self-test section is 200. The motor not going 500 is probably a result of me messing with the PID variables. I was changing the P variable around to see the ocsillation and other things. The motor goes a velocity of 300 when my P = 1.5, and my I and D equal 0.
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|