View Single Post
  #4   Spotlight this post!  
Unread 20-02-2009, 13:25
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: Program so far - help please

Well first you have to do the obvious, you need to open the relay device, and the joystick devices if you still havent.

you can use the joystick "get.vi" which (among other things) returns a cluster of button values for you to use. simply do an "unbundle by name" to access the individual buttons (button 1, 2, 7, etc)

i dont know which buttons are the ones you are referring to, but they should be clearly numbered on the joystick itself (i think 5 is the trigger and 2 is the thumb button. i think)

next you need to make a case structure. because you have two different buttons that dont neccesarily operate independently (and telling a motor to go both forwards and backwards doesnt work) you need to make the labview equivalent of an if-elseif-else structure. see the attached VI for details. im assuming you are somewhat familiar with binary numbers with this one (-;

i have those random controls in there so the VI wouldnt be broke. you can turn it into a subvi if you want to.
Attached Files
File Type: vi chinkley-relay-ex.vi (37.4 KB, 32 views)
__________________
A few of my favorite numbers:
175 176 177 195 230 558 716 1024 1071 1592 1784 1816
RPI 2012
BREAKAWAY

Last edited by Uberbots : 20-02-2009 at 13:26. Reason: 1010010101011
Reply With Quote