View Single Post
  #4   Spotlight this post!  
Unread 31-01-2013, 17:34
Jefferson Jefferson is offline
Registered User
AKA: Jeff Clements
FRC #0016 (Bomb Squad)
Team Role: Mentor
 
Join Date: Jan 2011
Rookie Year: 2010
Location: Mountain Home, AR
Posts: 257
Jefferson has a brilliant futureJefferson has a brilliant futureJefferson has a brilliant futureJefferson has a brilliant futureJefferson has a brilliant futureJefferson has a brilliant futureJefferson has a brilliant futureJefferson has a brilliant futureJefferson has a brilliant futureJefferson has a brilliant futureJefferson has a brilliant future
Re: Gyro PID Programming

Quote:
Originally Posted by UriF View Post
Hello,
(I am under the impression that the Output and Source variables should be scaled to the same range, please tell me if this is wrong.)
This is unnecessary. You can use the unscaled input (0-360). The right control variables will be different if you use the scaled input. But I can't think of a good reason to scale like you did.

Also, you could probably use the unmodified version of the PIDContoller by just setting up two controllers. They would both use the gyro as an input, but the output would be different (the two drive motors). The gains for one side will be the inverse of the other side in order to invert the output. I don't think you can do this with Robot Builder, but you could create them by hand in the RobotMap class.
Reply With Quote