View Single Post
  #5   Spotlight this post!  
Unread 12-03-2009, 23:36
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: 9,112
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
Re: Camera servo control off of the Joystick axes

Quote:
Originally Posted by m3rc1l3ss View Post
I just need to know how to make it so the joystick axes have a value of 0-179 instead of a value of -1 to 1. I would be most greatful if anyone were to help me with this.
It's a simple linear equation. Multiply by 89.5 then add 89.5, and you've got what you need. Alternatively, add 1 then multiply by 89.5 and you get the same thing.

Quote:
Also, reading the servo position into the current value of a pid and having the modified joystick on the input would allow me to run the servos as such, correct? (I cant explain this too well so I can give a screenshot if anyone wants it.)
I suppose you could do this, but why would you want to? The servo itself does its own closed-loop feedback control of position.
Reply With Quote