Go to Post Don't let my students know I skimmed that blog and didn't read it thoroughly. - rlance [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 30-01-2010, 20:44
Must Be Drama Must Be Drama is offline
Registered User
no team
 
Join Date: Feb 2009
Rookie Year: 2007
Location: Brooklyn
Posts: 62
Must Be Drama is an unknown quantity at this point
Is there a Way To refrence a true false statement

yeah is there a way?
Reply With Quote
  #2   Spotlight this post!  
Unread 30-01-2010, 20:52
DonRotolo's Avatar
DonRotolo DonRotolo is offline
Back to humble
FRC #0832
Team Role: Mentor
 
Join Date: Jan 2005
Rookie Year: 2005
Location: Atlanta GA
Posts: 7,011
DonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond repute
Re: Is there a Way To refrence a true false statement

Do you mean the output of a T/F statement? That is, whether it ended up T or F? Or something else?
__________________

I am N2IRZ - What's your callsign?
Reply With Quote
  #3   Spotlight this post!  
Unread 30-01-2010, 20:57
Must Be Drama Must Be Drama is offline
Registered User
no team
 
Join Date: Feb 2009
Rookie Year: 2007
Location: Brooklyn
Posts: 62
Must Be Drama is an unknown quantity at this point
Re: Is there a Way To refrence a true false statement

i didnt explain it well
since we have the basic.vi and teleop.vi
i want to route the motor invert from basic.vi into the teleop to use a case structure to invert the motor at a push of a button
Reply With Quote
  #4   Spotlight this post!  
Unread 30-01-2010, 21:08
Mark McLeod's Avatar
Mark McLeod Mark McLeod is online now
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,833
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Is there a Way To refrence a true false statement

I don't know of any "Basic.vi," but yes you can pass variables between vi's.
There are several different ways to do so.

Tell us a little bit about basic.vi first, like where is it and what are you doing in it.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle
Reply With Quote
  #5   Spotlight this post!  
Unread 30-01-2010, 21:09
Must Be Drama Must Be Drama is offline
Registered User
no team
 
Join Date: Feb 2009
Rookie Year: 2007
Location: Brooklyn
Posts: 62
Must Be Drama is an unknown quantity at this point
Re: Is there a Way To refrence a true false statement

i ment begin sorry about that;
Reply With Quote
  #6   Spotlight this post!  
Unread 30-01-2010, 21:30
Mark McLeod's Avatar
Mark McLeod Mark McLeod is online now
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,833
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Is there a Way To refrence a true false statement

You know, I know another team that wants to do something like that too.
Planning to Close and Reopen your 2 or 4 motor drive?

You can simplify that particular problem, since Begin.vi is only ever called one time and the starting values of Invert are hardcoded. You already know in Teleop.vi what values would be passed in. It's much easier to just keep that information local to teleop.vi.

You can pass the value of your Invert to teleop.vi with a global variable if you so choose. Your team probably used global variables last year.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle

Last edited by Mark McLeod : 30-01-2010 at 21:31. Reason: o
Reply With Quote
  #7   Spotlight this post!  
Unread 30-01-2010, 21:38
Must Be Drama Must Be Drama is offline
Registered User
no team
 
Join Date: Feb 2009
Rookie Year: 2007
Location: Brooklyn
Posts: 62
Must Be Drama is an unknown quantity at this point
Re: Is there a Way To refrence a true false statement

we didnt use global variables last year, i dont understand how to use them
Reply With Quote
  #8   Spotlight this post!  
Unread 30-01-2010, 22:29
Mark McLeod's Avatar
Mark McLeod Mark McLeod is online now
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,833
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Is there a Way To refrence a true false statement

This is in LabVIEW Help, but it's a bit hard to find.
  • Open the Begin.vi block diagram
  • Right-click for the Functions palette and go to Programming -> Structures and you'll see "GLOB" (for global variable) down at the bottom. Add that to your Begin.vi
  • Double click on the Global and you'll get a blank front panel.
  • Right-click on the Global front panel and add two boolean controls (doesn't matter which ones) to the global front panel. Rename them "Left Motor Invert" and "Right Motor Invert" or whatever you want to call them.
  • Save and close that global front panel. You'll be asked to give it a name, pick whatever you like, but be creative. I hate boring names.
  • Back in the Begin.vi block diagram right-click on that global you added before (it'll look like a globe), and choose Select Item -> Left Motor Invert.
  • Now copy and paste that global and right-click Select Item -> Right Motor Invert on that new one.
  • Wire both of those to you-know-where. Those values you wanted to send to Teleop.vi.
  • Save it and you now have global variables you can use anywhere.
Meanwhile, over in teleop.vi...
  • Highlight the two global variables you just made in Begin.vi and copy them.
  • Open the Teleop.vi block diagram and paste the global variables in.
  • Right-click on each of them and select "Change To Read" and now you can drag a wire from it to your case statement.
  • You can make more copies wherever you want to write back to them.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle

Last edited by Mark McLeod : 30-01-2010 at 22:32.
Reply With Quote
  #9   Spotlight this post!  
Unread 30-01-2010, 22:32
Brandon_L Brandon_L is offline
Back @ it again with the white vans
AKA: Brandon Liatys
FRC #2180 (Zero Gravity)
Team Role: Mentor
 
Join Date: Jan 2008
Rookie Year: 2007
Location: Newark, NJ
Posts: 1,207
Brandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond repute
Re: Is there a Way To refrence a true false statement

A little off topic, but it reminded me:

Do you HAVE to close whatever it is in the end vi? I forgot to and didn't notice a difference.
__________________
FRC 2495 - Hamilton West Robotics [2007-2014] - whats a..."hive mind"?
FRC 3929 - Atomic Dragons [2012-2013]
FRC 2180 - Zero Gravity [2017-]

Just trying to collect all the possible team colors
Reply With Quote
  #10   Spotlight this post!  
Unread 30-01-2010, 22:34
Mark McLeod's Avatar
Mark McLeod Mark McLeod is online now
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,833
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Is there a Way To refrence a true false statement

That is bizarrely off-topic...
Did you just pick the uppermost thread on the portal to ask your question?

If you fail to close things they will come back to haunt you after the season...
Attached Images
 
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle

Last edited by Mark McLeod : 31-01-2010 at 08:38.
Reply With Quote
  #11   Spotlight this post!  
Unread 30-01-2010, 23:56
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,113
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: Is there a Way To refrence a true false statement

It might be easier for you to add a case block to either multiply your motor control value by -1 or leave it alone, based on your pushbutton.
Reply With Quote
  #12   Spotlight this post!  
Unread 31-01-2010, 11:05
Must Be Drama Must Be Drama is offline
Registered User
no team
 
Join Date: Feb 2009
Rookie Year: 2007
Location: Brooklyn
Posts: 62
Must Be Drama is an unknown quantity at this point
Re: Is there a Way To refrence a true false statement

thanks alot imma try it when i reach today; i was searching in the help but it only gave me a small description how to do it
Reply With Quote
  #13   Spotlight this post!  
Unread 01-02-2010, 10:29
Danielle Danielle is offline
Registered User
AKA: Jake
FRC #2164 (The Corps)
Team Role: Programmer
 
Join Date: Jan 2010
Rookie Year: 2009
Location: Harrisonville
Posts: 2
Danielle is an unknown quantity at this point
Re: Is there a Way To refrence a true false statement

You could use a joystick button and wire it directly to the open motor invert terminal.

1) Unbundle the buttons (brown 'out' terminal) on the JoystickGet.vi [this can be done by right clicking on the terminal, most things in LabView can, I've found new love for my right mouse button ]

2) Wire the desired button to the invert terminal on the OpenMotor.vi (2 motors or 4, it doesn't matter)
Reply With Quote
  #14   Spotlight this post!  
Unread 01-02-2010, 10:30
Danielle Danielle is offline
Registered User
AKA: Jake
FRC #2164 (The Corps)
Team Role: Programmer
 
Join Date: Jan 2010
Rookie Year: 2009
Location: Harrisonville
Posts: 2
Danielle is an unknown quantity at this point
Re: Is there a Way To refrence a true false statement

BTW; I'm picturing this code in the Begin.vi
Reply With Quote
  #15   Spotlight this post!  
Unread 01-02-2010, 10:56
Mark McLeod's Avatar
Mark McLeod Mark McLeod is online now
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,833
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Is there a Way To refrence a true false statement

That solution won't work in this case.
The Begin.vi happens only once when the robot is first turned on, and they want to change the value on-the-fly during the match.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle
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
Is there a way to display Cmaer Live footage? Tottanka FRC Control System 0 12-12-2008 11:21
Is it true that there is not going to be UC Davis Sacramento Region next year? jimmythetulip22 General Forum 14 03-03-2008 23:54
Is there a way to read your Team Colour during autonomous mode? Firestorm Programming 2 19-02-2005 18:57
Way back there. Size of Nationals, and a solution archiver 2001 23 24-06-2002 03:28
is it true? are there pics of TEAM 1?? archiver 2000 3 23-06-2002 22:19


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

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