View Single Post
  #21   Spotlight this post!  
Unread 31-01-2006, 20:51
Astronouth7303's Avatar
Astronouth7303 Astronouth7303 is offline
Why did I come back?
AKA: Jamie Bliss
FRC #4967 (That ONE Team)
Team Role: Mentor
 
Join Date: Jan 2004
Rookie Year: 2004
Location: Grand Rapids, MI
Posts: 2,071
Astronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud ofAstronouth7303 has much to be proud of
Re: Manual Velocity PID, anyone successful?

Quote:
Originally Posted by Rick TYler
Yeah, but, writing PID from scratch is hard. Does anyone have some sample code I could show to our student programmers?
The Navigation code Kevin made for last year's robot has PID in it.

And it's pretty easy.
Code:
error = current - target
integral += error
derivative = error - prevError
output = Kp * error + Ki * integral + Kd * derivative
prevError = error
(The implementation details are left to the reader )