OCCRA
Go to Post Our strong support is the result of 14 years of very organized "nagging". :) - OZ_341 [more]
Home
Go Back   Chief Delphi > Technical > Programming > NI LabVIEW
CD-Events   CD-Media   CD-Spy   FRC-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rating: Thread Rating: 14 votes, 5.00 average. Display Modes
  #1   Spotlight this post!  
Unread 05-15-2012, 09:41 AM
DavidVang.2012's Avatar
DavidVang.2012 DavidVang.2012 is offline
TeTsuTo
FRC #2500 (Herobotics)
Team Role: Programmer
 
Join Date: Jan 2011
Rookie Year: 2010
Location: Minneapolis, MN
Posts: 2
DavidVang.2012 is an unknown quantity at this point
Closed PID loop for Speed Control

We are currently trying to create a closed PID loop that will essentially be able to control the speed output of our drive wheels as we give input through our joysticks.

Is there anyone out there who is willing to share their developed [and working] closed PID loop so that I can get a better picture of what I need to include in the program? A simple closed PID loop program will be sufficient.

Thank you very much.
Reply With Quote
  #2   Spotlight this post!  
Unread 05-15-2012, 12:04 PM
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 7,837
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Send a message via AIM to Alan Anderson
Re: Closed PID loop for Speed Control

LabVIEW includes PID functions already. To find them, open the function palette and search for "PID".

Since you want to control speed instead of position, you have two basic options. Either use the output of the PID function to add to or subtract from your motor power instead of using it as the motor power directly, or get an equivalent effect by running the PID function using the I term as if it were the proportional constant.
Reply With Quote
  #3   Spotlight this post!  
Unread 05-15-2012, 08:48 PM
Tom Line's Avatar
Tom Line Tom Line is offline
Raptors can't turn doorknobs.
FRC #1718 (The Fighting Pi)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 1999
Location: Armada, Michigan
Posts: 2,136
Tom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond repute
Re: Closed PID loop for Speed Control

Check out the Velocity PID (2012) located here:

http://www.fightingpi.org/Controls.html

It's in labview, and is commented fairly well and should be self explanatory if you know basic PID theory. Thanks to Jared from team 341 for giving the derivation in 2009 that we used to create this PID to control our shooter this year.

Last edited by Tom Line : 05-15-2012 at 08:51 PM.
Reply With Quote
  #4   Spotlight this post!  
Unread 05-15-2012, 10:15 PM
blackflame2996's Avatar
blackflame2996 blackflame2996 is offline
VP of Programming, Driver
AKA: David Donahue
FRC #2996 (Cougars Gone Wired)
Team Role: Programmer
 
Join Date: Nov 2011
Rookie Year: 2011
Location: Colorado springs, CO
Posts: 67
blackflame2996 is a name known to allblackflame2996 is a name known to allblackflame2996 is a name known to allblackflame2996 is a name known to allblackflame2996 is a name known to allblackflame2996 is a name known to all
Send a message via Skype™ to blackflame2996
Re: Closed PID loop for Speed Control

Just out of curiosity, why use PID for a user controlled drive system? This seems unnecessary. PID is nice for things like shooters, but why use it with the drive?
__________________
2009 Regional Winners
2011 Regional Chairman's Award
2012 Regional Winners
2013 Regional Chairman's Award
Reply With Quote
  #5   Spotlight this post!  
Unread 05-15-2012, 10:20 PM
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 6,069
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: Closed PID loop for Speed Control

Quote:
Originally Posted by blackflame2996 View Post
Just out of curiosity, why use PID for a user controlled drive system? This seems unnecessary. PID is nice for things like shooters, but why use it with the drive?
Autonomous. Computer-assisted bridge balancing. More predictable response to driver commands in the presence of varying battery voltages.


Reply With Quote
  #6   Spotlight this post!  
Unread 05-15-2012, 11:08 PM
Tom Line's Avatar
Tom Line Tom Line is offline
Raptors can't turn doorknobs.
FRC #1718 (The Fighting Pi)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 1999
Location: Armada, Michigan
Posts: 2,136
Tom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond repute
Re: Closed PID loop for Speed Control

Traction control (2009).

Maintaining a set field position.

We're not even talking about a swerve drive....
Reply With Quote
  #7   Spotlight this post!  
Unread 05-17-2012, 05:11 PM
blackflame2996's Avatar
blackflame2996 blackflame2996 is offline
VP of Programming, Driver
AKA: David Donahue
FRC #2996 (Cougars Gone Wired)
Team Role: Programmer
 
Join Date: Nov 2011
Rookie Year: 2011
Location: Colorado springs, CO
Posts: 67
blackflame2996 is a name known to allblackflame2996 is a name known to allblackflame2996 is a name known to allblackflame2996 is a name known to allblackflame2996 is a name known to allblackflame2996 is a name known to all
Send a message via Skype™ to blackflame2996
Re: Closed PID loop for Speed Control

I see. we'll keep that in mind.
__________________
2009 Regional Winners
2011 Regional Chairman's Award
2012 Regional Winners
2013 Regional Chairman's Award
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 11:24 PM.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


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