View Single Post
  #2   Spotlight this post!  
Unread 16-02-2009, 16:44
rhoads2234's Avatar
rhoads2234 rhoads2234 is offline
Registered User
AKA: Erin
FRC #2234
Team Role: Programmer
 
Join Date: Jan 2007
Rookie Year: 2007
Location: PA
Posts: 80
rhoads2234 will become famous soon enough
Re: Programming buttons help!

if you want it to only rotate 90 degrees, you will have to have some sort of sensor (limit switch, encoder or potentiometer) Be careful if you use a potentiometer- they have a limited range.

As for how to get a button to send signal to a motor,
use the "get" VI for a joystick and unbundle the button output (I recommend unbundle by name)
wire one of the buttons you want to use to a case structure (to the question mark) and in the true statement put a set speed for your motor. Create a constant for the speed.
wire the other button to another case structure and do the same thing, but your constant should be 0 this time.
__________________
ALWAYS a mechanical problem!
Reply With Quote