View Single Post
  #2   Spotlight this post!  
Unread 04-02-2014, 20:07
Ginto8's Avatar
Ginto8 Ginto8 is offline
Programming Lead
AKA: Joe Doyle
FRC #2729 (Storm)
Team Role: Programmer
 
Join Date: Oct 2010
Rookie Year: 2010
Location: Marlton, NJ
Posts: 174
Ginto8 is a glorious beacon of lightGinto8 is a glorious beacon of lightGinto8 is a glorious beacon of lightGinto8 is a glorious beacon of lightGinto8 is a glorious beacon of light
Re: Programming a Potentiometer

A potentiometer is just a voltage divider, so at one end of the dial its output is your input voltage (5V probably), and at the other end your output is 0V. Wire this output into your analog module, and use an AnalogChannel and its getAverageVoltage() method to read the output. You should experiment to see what the voltage should be for the limits.
__________________
I code stuff.
Reply With Quote