Go to Post *puts on flame suit and goes to hide in the corner* :D - Wayne Doenges [more]
Home
Go Back   Chief Delphi > Technical > Programming > NI LabVIEW
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 12-12-2008, 21:32
darkpheonix darkpheonix is offline
Registered User
FRC #2225
 
Join Date: Jan 2008
Location: Minnesota
Posts: 5
darkpheonix is an unknown quantity at this point
How do you program joystick buttons in LabVIEW?

Hi guys,
How do you program joystick buttons in LabVIEW, or program anything with the joystick for that matter? I kinda figured out how the drive VI and joystick get axis VI work but I'm lost on how to use the joystick get VI to do anything else. I'm totally new to LabVIEW so any help would be appreciated.
Reply With Quote
  #2   Spotlight this post!  
Unread 13-12-2008, 00:03
ZInventor's Avatar
ZInventor ZInventor is offline
Registered User
AKA: Zeno Le Héricy
FRC #2915 (Riverdale Robotics Pandamonium)
Team Role: Alumni
 
Join Date: Feb 2008
Rookie Year: 2000
Location: Portland Oregon USA
Posts: 247
ZInventor is just really niceZInventor is just really niceZInventor is just really niceZInventor is just really nice
Re: How do you program joystick buttons in LabVIEW?

here's a simple program i wrote to output the data from my USB COMBATSTICH 568


it just displays the outputs, but it should help you get started...

the data is oupput as clusters, that you can unbundle, and use the data from...

-Z
Attached Files
File Type: vi cool joystick prog nilabview.vi (31.3 KB, 1324 views)
__________________
[center]
Reply With Quote
  #3   Spotlight this post!  
Unread 13-12-2008, 00:51
whitetiger0990's Avatar
whitetiger0990 whitetiger0990 is offline
Registered User
no team
Team Role: Programmer
 
Join Date: Mar 2006
Rookie Year: 2006
Location: Earth
Posts: 157
whitetiger0990 is a glorious beacon of lightwhitetiger0990 is a glorious beacon of lightwhitetiger0990 is a glorious beacon of lightwhitetiger0990 is a glorious beacon of lightwhitetiger0990 is a glorious beacon of light
Re: How do you program joystick buttons in LabVIEW?

Are we talking about getting it off the DS, or off a joystick plugged into the computer?

If the second, then ZInventor's VI should work, if you're looking for help for this year's control system, then see the attached. Joystick Get outputs 2 bundles, one with 12 booleans (for the buttons), the other with 6 doubles (for the axises (I've never seen more than 3 though...))
Attached Thumbnails
Click image for larger version

Name:	joystickunbundle.png
Views:	1036
Size:	5.6 KB
ID:	7027  
__________________
print$q=chr(ord($q)+$1)while("7443-0201-8465130105-12-03135-82482113-06-7672-070208-0613-70"=~/(-?\d\d)/g);
Reply With Quote
  #4   Spotlight this post!  
Unread 09-04-2014, 07:06
bol_clubiste's Avatar
bol_clubiste bol_clubiste is offline
Registered User
no team
 
Join Date: Apr 2014
Location: tunisia
Posts: 3
bol_clubiste is an unknown quantity at this point
Re: How do you program joystick buttons in LabVIEW?

I don't have joystick Get function in my palette , what should I do please ?
Reply With Quote
  #5   Spotlight this post!  
Unread 09-04-2014, 19:50
EDesbiens's Avatar
EDesbiens EDesbiens is offline
Passionate crackpot
AKA: Étienne Desbiens
FRC #5859 (i)
Team Role: College Student
 
Join Date: Apr 2014
Rookie Year: 2013
Location: Canton de Hatley, QC, Canada
Posts: 296
EDesbiens is a glorious beacon of lightEDesbiens is a glorious beacon of lightEDesbiens is a glorious beacon of lightEDesbiens is a glorious beacon of lightEDesbiens is a glorious beacon of lightEDesbiens is a glorious beacon of light
Re: How do you program joystick buttons in LabVIEW?

To get it, just do like on this image:
Attached Thumbnails
Click image for larger version

Name:	joystick.png
Views:	276
Size:	160.2 KB
ID:	16800  
Reply With Quote
  #6   Spotlight this post!  
Unread 09-04-2014, 19:53
Joe Ross's Avatar Unsung FIRST Hero
Joe Ross Joe Ross is offline
Registered User
FRC #0330 (Beachbots)
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 1997
Location: Los Angeles, CA
Posts: 8,560
Joe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond repute
Re: How do you program joystick buttons in LabVIEW?

Quote:
Originally Posted by bol_clubiste View Post
I don't have joystick Get function in my palette , what should I do please ?
This is a forum for the FIRST Robotics competition, which has it's own LabVIEW library. The FIRST Library will not do what you want. I recommend asking at the NI Community forums for a general answer.
Reply With Quote
  #7   Spotlight this post!  
Unread 09-04-2014, 20:00
bol_clubiste's Avatar
bol_clubiste bol_clubiste is offline
Registered User
no team
 
Join Date: Apr 2014
Location: tunisia
Posts: 3
bol_clubiste is an unknown quantity at this point
Re: How do you program joystick buttons in LabVIEW?

Thank you ! I already have looked in the Net about this problem and I found that I must install WPI Robotics Library , but I coudn't find a link or a site to download , Please can you give me a link ?? thank you very much brother
Reply With Quote
  #8   Spotlight this post!  
Unread 09-04-2014, 22:51
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,112
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: How do you program joystick buttons in LabVIEW?

Unless you're going to be controlling a National Instruments cRIO-FRC with associated I/O hardware and a networked Driver Station, the WPI library won't do anything helpful for you. For reading joysticks, what you probably want is in the Connectivity -> Input Device function palette.
Reply With Quote
  #9   Spotlight this post!  
Unread 10-04-2014, 01:30
tcjinaz tcjinaz is offline
Tim
FRC #3853
Team Role: Mentor
 
Join Date: May 2011
Rookie Year: 2011
Location: Arizona
Posts: 206
tcjinaz has a spectacular aura abouttcjinaz has a spectacular aura about
Re: How do you program joystick buttons in LabVIEW?

Quote:
Originally Posted by bol_clubiste View Post
I don't have joystick Get function in my palette , what should I do please ?
Look for Connectivity->Input Devices

There are joystick & keyboard functions there. I have been using them to explore the SpaceMouse and the Logitech GamePad interfaces.
__________________
Software Mentor
3853 Pridetronics[

Reply With Quote
  #10   Spotlight this post!  
Unread 10-04-2014, 07:13
EDesbiens's Avatar
EDesbiens EDesbiens is offline
Passionate crackpot
AKA: Étienne Desbiens
FRC #5859 (i)
Team Role: College Student
 
Join Date: Apr 2014
Rookie Year: 2013
Location: Canton de Hatley, QC, Canada
Posts: 296
EDesbiens is a glorious beacon of lightEDesbiens is a glorious beacon of lightEDesbiens is a glorious beacon of lightEDesbiens is a glorious beacon of lightEDesbiens is a glorious beacon of lightEDesbiens is a glorious beacon of light
Re: How do you program joystick buttons in LabVIEW?

But, do you have the FRC version of Labview?
Reply With Quote
  #11   Spotlight this post!  
Unread 13-04-2014, 10:20
pastelpony's Avatar
pastelpony pastelpony is offline
Programmer/Electrical
AKA: Zach M
FRC #3525 (Nuts and Bolts of Fury)
Team Role: Programmer
 
Join Date: Feb 2014
Rookie Year: 2013
Location: Waterbury, Connecticut
Posts: 152
pastelpony will become famous soon enough
Re: How do you program joystick buttons in LabVIEW?

Wire an "unbundle by name" to the "buttons" output on the joystick "Get" command. The buttons generated will be treated as booleans and can be used in tandem with case structures, subVIs, etc to complete an operation with a button press.

Last edited by pastelpony : 13-04-2014 at 10:22.
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Tip if you ever want to program network applications in LabVIEW Michael Hill National Instruments LabVIEW and Data Acquisition 1 24-10-2008 20:31
Programing joystick buttons Shivang1923 Programming 8 09-02-2008 16:21
Buttons to Pins on Joystick yarb65 Electrical 1 24-08-2007 20:39
How many buttons do you have? Bcahn836 Chit-Chat 12 01-09-2004 23:34
Does anyone have an idea on how to make a joystick program for an operating board? necroprime Programming 8 09-11-2002 19:04


All times are GMT -5. The time now is 03:44.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi