Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   NI LabVIEW (http://www.chiefdelphi.com/forums/forumdisplay.php?f=182)
-   -   PID Gain Scheduling/Deadband Filtering For a Non-Linear Output (http://www.chiefdelphi.com/forums/showthread.php?t=125964)

Qwuke 06-02-2014 20:12

PID Gain Scheduling/Deadband Filtering For a Non-Linear Output
 
So I am new to PID control theory(and labview altogether), but I want to create rate PIDs for the motors on our talon drive train by grabbing a rate value from an encoder on each wheel. However, in order to make our drive train run smoother I've squared the function, added a deadband, and then adjusted the slopes. To my knowledge, for my PID to work correctly with this new function being applied, I will have to implement gain scheduling and deadband filtering within the PID for this to work.
Take note, I'm a novice to control theory/PIDs, so I apologize if the solution is right in front of me and I haven't taken notice.
If anyone has any idea about this, references or examples, or place to point me to, my team would be honor-bound to you. But seriously I would deeply appreciate some assistance.

Jared Russell 06-02-2014 20:51

Re: PID Gain Scheduling/Deadband Filtering For a Non-Linear Output
 
What is the problem you are trying to solve?

You mention making the drive train smoother. Are you talking about autonomous mode or teleop? Why do you think it should be smoother?

Qwuke 06-02-2014 21:20

Re: PID Gain Scheduling/Deadband Filtering For a Non-Linear Output
 
First, I deeply appreciate the feedback on my difficulties. Thanks.

But my problem is that because I am squaring my motor outputs, a PID for my drive train motors for speed will not work effectively - according to what I have read. I do not know how to implement gain scheduling or deadband filters for something like this and have found a lack of resources for implementing these things.

I am squaring and adding deadbands(I also decrease the slope of the input function to accommodate the dead band) to the joystick inputs for teleop mode to allow our drivers to have finer motor control when attempting to aim or position the bot. We have found linear outputs have 'jumpy' outputs when trying to do these things.

Again, thank you. I have virtually no backup on my team for programming so when I run into problems I typically resort to google/CD for help, and this doesn't have a lot of solutions.

Jared Russell 06-02-2014 21:35

Re: PID Gain Scheduling/Deadband Filtering For a Non-Linear Output
 
I am happy to help...But you didn't answer my questions :)

It seems like you are trying to use PID control of speed during teleop while simultaneously using a non-linear joystick curve. I understand why a non-linear joystick curve can help with a jumpy robot, but I do not understand why you want to do PID speed control.

gpetilli 06-02-2014 21:35

Re: PID Gain Scheduling/Deadband Filtering For a Non-Linear Output
 
we typically square the joystick inputs, not the PID outputs. PID is a linear system, which you violate with the squaring. Squaring the joystick (PID setpoint) before the PID changes the driver responsiveness but does not change the PID math. BTW: to square use newjoy= joy * abs(joy) to preserve the sign.

Qwuke 06-02-2014 21:47

Re: PID Gain Scheduling/Deadband Filtering For a Non-Linear Output
 
Quote:

Originally Posted by Jared341 (Post 1338861)
I am happy to help...But you didn't answer my questions :)

It seems like you are trying to use PID control of speed during teleop while simultaneously using a non-linear joystick curve.

Whoops! "What is the problem you are trying to solve?" I'm trying to solve the fact that PID does not appreciate that I am going to feed a curved joystick input according to literature I have found


"Are you talking about autonomous mode or teleop?" This is in teleop

"Why do you think it should be smoother?" I think it should be smooth because our drivers have difficulty aiming with a linear joystick input. Again, jumpiness.

"I understand why a non-linear joystick curve can help with a jumpy robot, but I do not understand why you want to do PID speed control." This year our robot is using a mecanum drive train. Right now I observe that our robot's wheels don't spin at the same speed depending on how even the terrain is, and this is a problem when we are rotating/strafing. I want to implement speed control in order to keep our wheels at the outputs we are feeding them instead of having a messed up strafe/rotation function.

Thanks, and I apologize for any miscommunication.

Qwuke 06-02-2014 21:53

Re: PID Gain Scheduling/Deadband Filtering For a Non-Linear Output
 
Quote:

Originally Posted by gpetilli (Post 1338862)
Squaring the joystick (PID setpoint) before the PID changes the driver responsiveness but does not change the PID math.

..."For a Non-Linear Output"...

...And I thought I did my research before asking this question. I am actually squaring the joystick input and not the output, that was a typo. I should have put this together before I asked this question because that was obvious. Thank you both for your input, I can now go ahead and work on implementing my PIDs.

Woo! Collaboration solves confusion!


All times are GMT -5. The time now is 09:44.

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