Log in

View Full Version : Critical Talon Srx help needed


Team5860-Alex
17-02-2016, 21:17
This is our rookie year and programming is off to a great start however we want to use encoders to do a series of commands. We have tried our best efforts, referred to the software manual and still cant get it to work. We do have an encoder read out and can find/reset the encoder position, however in teleop we cant get the motors to move at all. We are using digital quadrature encoders on the versa planetary gearboxes right to the CAN talon srx's. If we could get some code or code pictures to help out that would be much appreciated. the examples werent much success either:(

nickbrickmaster
17-02-2016, 21:19
Are you using PID control or percent control?

Here's the Talon SRX software reference manual. There is some example code in there for whatever you are doing.

https://www.ctr-electronics.com/Talon%20SRX%20Software%20Reference%20Manual.pdf

Team5860-Alex
17-02-2016, 21:34
Are you using PID control or percent control?

Here's the Talon SRX software reference manual. There is some example code in there for whatever you are doing.

https://www.ctr-electronics.com/Talon%20SRX%20Software%20Reference%20Manual.pdf

PID

TimTheGreat
17-02-2016, 21:35
PID

Do you have any code?

Team5860-Alex
17-02-2016, 21:49
this is the code

https://www.dropbox.com/s/aid95e1i31bydq6/Screenshot%20%287%29.png?dl=0

Matt-T-FRC
17-02-2016, 22:24
Can we see a snapshot of your Begin.vi and Telop.vi please

nickbrickmaster
17-02-2016, 22:27
I'm not very familiar with LabVIEW, but I'll try to help as much as I can. What are the PID values you are using with the Talon? You can try increasing P until you see the motor move (safely). I've found that the Talon self-test is pretty helpful for checking problems.

You have the quad encoder hooked up to the talon via the breakout board, yes?

Team5860-Alex
17-02-2016, 22:29
Can we see a snapshot of your Begin.vi and Telop.vi please

Yes using breakout board

PID Values
https://www.dropbox.com/s/dvhe5a325zqmsqe/Screenshot%20%2810%29.png?dl=0

Begin
https://www.dropbox.com/s/wzamoeuelciuykq/Screenshot%20%288%29.png?dl=0

Teleop
https://www.dropbox.com/s/1o918lpwrfdomaq/Screenshot%20%289%29.png?dl=0

nickbrickmaster
17-02-2016, 22:41
Those are some seriously huge PID values. P should be between 0 and 1 in most cases. I would start tuning with just a P value and no I/D, which you can add later if you need the stabilization.

The Talon SRX software reference manual has some good tips on PID tuning. You can use the self-test button to determine error, and calculate your initial P value based on that.

Matt-T-FRC
17-02-2016, 22:43
Alright, that's a great start. Your Begin.vi you need everything to the right of the loop in your Telop.vi minus the driver station start communication. In your Telop.vi, you need everything inside the while loop except for the timer. Besides that, have you attempted to run this program at all on your robot?

Team5860-Alex
17-02-2016, 22:53
Alright, that's a great start. Your Begin.vi you need everything to the right of the loop in your Telop.vi minus the driver station start communication. In your Telop.vi, you need everything inside the while loop except for the timer. Besides that, have you attempted to run this program at all on your robot?

Yes we ran it but nothing happened, is it an automatic process or should we assign this to a button?

Matt-T-FRC
17-02-2016, 22:59
It should be assign to a button with the number of rotations that you would like the motor to turn.

Team5860-Alex
17-02-2016, 23:10
It should be assign to a button with the number of rotations that you would like the motor to turn.

Like so??
https://www.dropbox.com/s/81gj2e6wt4agmgd/Screenshot%20%2812%29.png?dl=0

Matt-T-FRC
17-02-2016, 23:35
Unless your resetting your PID in telop, this should be all you need to control that motor

Team5860-Alex
17-02-2016, 23:46
Unless your resetting your PID in telop, this should be all you need to control that motor

Nope still nothing