View Single Post
  #2   Spotlight this post!  
Unread 02-02-2004, 16:00
Dave Flowerday Dave Flowerday is offline
Software Engineer
VRC #0111 (Wildstang)
Team Role: Engineer
 
Join Date: Feb 2002
Rookie Year: 1995
Location: North Barrington, IL
Posts: 1,366
Dave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond repute
Re: OI and analog: Zero value

Quote:
Originally Posted by Astronouth7303
Get this: no joystick (infinate resistance, no voltage) has a value of 127.
Now take a potentiometer and wire it to a analog port. Turn it all the down.
It will read: 127, 0, ..., 127, ..., 255. A little heads up! Or is this unusual?
It sounds like you connected ground to one side of your pot and +5 to the other. If so, you're supposed to leave the "ground" side unconnected. This is explained on page 5 of the FRC OI guide at IFI's site. From that document, "In the event that an analog input is less than 0.05V, a value of 127 will be generated." This is on purpose so that if nothing is connected to a joystick port, an internal pulldown resistor in the OI will pull the analog pins down to 0 volts and the OI software will translate that to 127. This way, if you accidentally unplug your drive joystick (for example), your robot won't start running full tilt backwards!