Go to Post Give me enough gearboxes and I'll move the world. - SenorZ [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 04-02-2012, 01:19
Ddres0605's Avatar
Ddres0605 Ddres0605 is offline
Registered User
FRC #2638
 
Join Date: Jan 2012
Location: Great Neck
Posts: 3
Ddres0605 is an unknown quantity at this point
Joystick - Action Only Once

Hey. I need some help with some joystick programming. I want to make it so an action happens only when the button is pressed down. Example: A button is pressed and a bimba extends or something like that then, it only retracts when the button is pressed again. Any help would be appreciated! Thanks!
Reply With Quote
  #2   Spotlight this post!  
Unread 04-02-2012, 08:16
MotorHead's Avatar
MotorHead MotorHead is offline
Programming Mentor
AKA: Jeff Beltramo
FRC #1922 (OZ-Ram)
Team Role: Coach
 
Join Date: Jan 2008
Rookie Year: 2006
Location: Concord, NH
Posts: 68
MotorHead is a splendid one to beholdMotorHead is a splendid one to beholdMotorHead is a splendid one to beholdMotorHead is a splendid one to beholdMotorHead is a splendid one to beholdMotorHead is a splendid one to beholdMotorHead is a splendid one to behold
Re: Joystick - Action Only Once

What you are referring to is called latching a button. Once you press and release a button, it maintains that state until it is pressed again. In the LabView FRC examples, there is an example demonstrating this. You can get to it by starting at the LabView Getting Started Window. Select 'Support' on the left and select 'Find FRC Examples'. You will see folder call 'Joystick'. Under here is an example program demonstrating button latching.

Give it a try and if you have more questions, post back.
__________________
Jeff Beltramo
Team #1922
Concord, New Hampshire

Reply With Quote
  #3   Spotlight this post!  
Unread 04-02-2012, 11:47
cilginbilgin cilginbilgin is offline
Registered User
FRC #2905
 
Join Date: Jan 2010
Location: Istanbul,Turkey
Posts: 188
cilginbilgin is a jewel in the roughcilginbilgin is a jewel in the roughcilginbilgin is a jewel in the roughcilginbilgin is a jewel in the rough
Re: Joystick - Action Only Once

Quote:
Originally Posted by Ddres0605 View Post
Hey. I need some help with some joystick programming. I want to make it so an action happens only when the button is pressed down. Example: A button is pressed and a bimba extends or something like that then, it only retracts when the button is pressed again. Any help would be appreciated! Thanks!
Team 358 shares some code examples on this link including various button examples. Hope that helps:

http://team358.org/files/programming...2009-/LabVIEW/
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


All times are GMT -5. The time now is 22:32.

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