View Single Post
  #14   Spotlight this post!  
Unread 27-03-2006, 00:52
iamthetallpaul iamthetallpaul is offline
Registered User
FRC #1189
 
Join Date: Jan 2006
Location: Grosse Pointe
Posts: 13
iamthetallpaul is on a distinguished road
Re: How does your auto-aim work?

I wish I had had more experience to learn about PD, PID, and PI loops, this was my first and only year as our only programmer (any my only year on the team). Th last one graduated and left me with nothing.

I used a slightly modified version of Kevin's code. Instead of driving a pan servo based on the pan_error, pan_error is just added to or subtracted from 127 to drive the turret motor towards the center of the light. Actually slightly off center since the camer is mounted off center. Tilt is exactly the same and the hood is a lookup table.