View Single Post
  #8   Spotlight this post!  
Unread 06-02-2007, 16:28
Uberbots's Avatar
Uberbots Uberbots is offline
Mad Programmer
AKA: Billy Sisson
FRC #1124 (ÜberBots)
Team Role: College Student
 
Join Date: Jan 2006
Rookie Year: 2005
Location: Avon
Posts: 739
Uberbots has a reputation beyond reputeUberbots has a reputation beyond reputeUberbots has a reputation beyond reputeUberbots has a reputation beyond reputeUberbots has a reputation beyond reputeUberbots has a reputation beyond reputeUberbots has a reputation beyond reputeUberbots has a reputation beyond reputeUberbots has a reputation beyond reputeUberbots has a reputation beyond reputeUberbots has a reputation beyond repute
Re: limiting voltage to the speed controller

Quote:
you can also run the joystick value through a math function to get your answer
left = ((left -127) /2 ) + 127
Dont forget to typecast or else you will overflow.

left = (( (int)left - 127) /2 ) + 127

you can replace 2 with any value that you want to in order to further dampen the speed.
__________________
A few of my favorite numbers:
175 176 177 195 230 558 716 1024 1071 1592 1784 1816
RPI 2012
BREAKAWAY