View Single Post
  #1   Spotlight this post!  
Unread 21-08-2012, 16:43
baronep's Avatar
baronep baronep is offline
Student President
FRC #2848 (Jesuit All-Sparks)
Team Role: Leadership
 
Join Date: Jan 2010
Rookie Year: 2010
Location: Dallas TX
Posts: 167
baronep is on a distinguished road
Programming Puzzle

So I am trying to solve a programming problem that we are having with our T-Shirt cannon.

We have an analog rotation sensor that, as the cannon rotates a full rotation, the analog signal changes between 0 and 5V (linearly).

My question is how I should deal with the transition between 0 to 5 volts in code. I want to be able to index the cannon so that it will snap to a position every 1/6th of the rotation. How should I do this?
Reply With Quote