View Single Post
  #7   Spotlight this post!  
Unread 07-02-2012, 16:29
Tommy F.'s Avatar
Tommy F. Tommy F. is offline
Yeah! Collages!
AKA: 7h0m45
FRC #1985 (Robohawks)
Team Role: Alumni
 
Join Date: Mar 2011
Rookie Year: 2010
Location: St. Louis, MO
Posts: 188
Tommy F. is just really niceTommy F. is just really niceTommy F. is just really niceTommy F. is just really nice
Re: Shooter PID loop

Quote:
Originally Posted by Teamcodeorange View Post
So what do I do from here? I am kind of a noob in complex data management.
From there, I would go to "Help" > "Find Examples..." and in the NI Example Finder search for "PID" and look for the General PID Simulator.vi (or any other one you would like to use)

In the block diagram of the example, I would copy the PID gain cluster and the bundle + chart with the PV Setpoint Output label, so your code might look something like below.

Click image for larger version

Name:	pid.JPG
Views:	111
Size:	15.3 KB
ID:	11791

I like to include the graph so that the gains are easier to tune, as well as using the controls so you can adjust them while the code is running. (When you get the gains the way you want them, be sure to write them down and take out the controls and replace them with constants; they tend to reset themselves.)
__________________

FTC 289, 290 & 291 :: FRC 1985

2013 St. Louis Regional Semi-Finalist (with 3411 and 4330), Industrial Design Award
2013 Queen City Regional Winner (with 379 and 447)

Reply With Quote