Go to Post Ken Patton rocks my socks off! - Josh Hambright [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

 
 
 
Thread Tools Rating: Thread Rating: 2 votes, 4.50 average. Display Modes
Prev Previous Post   Next Post Next
  #1   Spotlight this post!  
Unread 31-12-2014, 17:00
BitTwiddler's Avatar
BitTwiddler BitTwiddler is offline
electronics/programming mentor
AKA: Mr Tanguay
FRC #1726 (N.E.R.D.S.)
Team Role: Mentor
 
Join Date: Oct 2008
Rookie Year: 2006
Location: Sierra Vista, AZ
Posts: 243
BitTwiddler is on a distinguished road
Team 1726 button toggle & SR Latch code

We used these handy little utilities last year and I'd like to be able to re-use the code this year if it comes in handy again. Therefore I am posting the source VI code for other teams to use in the spirit of R13 for the 2015 game.
Button toggle allows the drive team to use a game controller button like a toggle switch. It detects the button press and flips the true/false state of the toggle output to turn something on or off as desired.
SR latch uses one button to set the output to true and second button to reset it back to false.
If you wish to clone multiple copies of these VIs in your code make sure to make them re-entrant to avoid confusion with shared resources.
Hope some other teams also find these useful.
Attached Files
File Type: vi Button Toggle.vi (11.8 KB, 65 views)
File Type: vi s-rflipflop.vi (8.5 KB, 34 views)

Last edited by BitTwiddler : 31-12-2014 at 18:50.
Reply With Quote
 


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 08:47.

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