Go to Post It takes a village to raise a robotics student... - Bob Steele [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
  #16   Spotlight this post!  
Unread 20-01-2009, 17:15
Booksy Booksy is offline
Registered User
FRC #1244 (Viking Robotics)
Team Role: Programmer
 
Join Date: Apr 2008
Rookie Year: 2007
Location: Great White North
Posts: 97
Booksy will become famous soon enoughBooksy will become famous soon enough
Re: How do i find a variable and use it on Labview

Quote:
Originally Posted by BLAQmx View Post
Every variable can be either read or written to.I n that sense there is only one variable but two states. This single variable may have multiple copies of readers and writers, but they are all reading and writing from the same place in memory.

Let me know if the screen shot I have attached helps at all.
I think you made a typo in your comments. The one says it has one writer and multiple readers, but it actually has one reader, and multiple writers.
__________________
My favorite CD quote ever(taken out of context of course):
Quote:
Originally Posted by ttldomination
water would be hard to build
Reply With Quote
  #17   Spotlight this post!  
Unread 20-01-2009, 21:22
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,748
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: How do i find a variable and use it on Labview

You click on the ???s and choose from the list of controls. If you rename a control, the variable also gets renamed.

Greg McKaskle
Reply With Quote
  #18   Spotlight this post!  
Unread 20-01-2009, 23:37
BLAQmx's Avatar
BLAQmx BLAQmx is offline
Software Engineer
no team (National Instruments)
Team Role: Engineer
 
Join Date: Sep 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 100
BLAQmx is a glorious beacon of lightBLAQmx is a glorious beacon of lightBLAQmx is a glorious beacon of lightBLAQmx is a glorious beacon of lightBLAQmx is a glorious beacon of lightBLAQmx is a glorious beacon of light
Re: How do i find a variable and use it on Labview

Quote:
I think you made a typo in your comments. The one says it has one writer and multiple readers, but it actually has one reader, and multiple writers
I'll double check and repost the screenshot. Thanks!

Quote:
In your example you have variables with "X" and "Y" in them all i get are "?"s how did you rename the variable.
BLAQmx where do you find the boolean, string, and numeric all i can find are local, global, and shared and how do you name them.
Tutorial: Local Variable, Global Variable, and Race Conditions
See the section Implementing a Global Variable

There is also a video of there tutorial here.
__________________
NI FIRST Community: Where to go for LabVIEW, Wind River, cRIO-FRC, and NXT support.
Reply With Quote
  #19   Spotlight this post!  
Unread 21-01-2009, 00: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 i find a variable and use it on Labview

I'm not really sure why you want to use variables. You might be thinking too much in terms of procedural programming (like C or even BASIC) instead of treating LabVIEW as a dataflow programming method -- which it is.

In LabVIEW programs, wires are essentially the variables. They're what "hold" values as they move from where they're produced to where they're used.
Reply With Quote
  #20   Spotlight this post!  
Unread 21-01-2009, 01:17
dgraves702 dgraves702 is offline
Registered User
FRC #0702 (Bagel Bytes)
Team Role: Mentor
 
Join Date: Jan 2009
Rookie Year: 2002
Location: Los Angeles
Posts: 7
dgraves702 is an unknown quantity at this point
Re: How do i find a variable and use it on Labview

Quote:
Originally Posted by Alan Anderson View Post
I'm not really sure why you want to use variables. You might be thinking too much in terms of procedural programming (like C or even BASIC) instead of treating LabVIEW as a dataflow programming method -- which it is.

In LabVIEW programs, wires are essentially the variables. They're what "hold" values as they move from where they're produced to where they're used.
Exactly. All you need to do is wire the output from your Get Axis VI from the Joystick Palette to the Set Speed VI (or equivalent if you are using your Drive motors) from the Motors Palette. You don't need to use variables at all.
Reply With Quote
  #21   Spotlight this post!  
Unread 21-01-2009, 07:30
Russ Beavis Russ Beavis is offline
Registered User
no team
 
Join Date: Nov 2005
Location: Manchester, NH - DEKA R&D Corp.
Posts: 341
Russ Beavis has a reputation beyond reputeRuss Beavis has a reputation beyond reputeRuss Beavis has a reputation beyond reputeRuss Beavis has a reputation beyond reputeRuss Beavis has a reputation beyond reputeRuss Beavis has a reputation beyond reputeRuss Beavis has a reputation beyond reputeRuss Beavis has a reputation beyond reputeRuss Beavis has a reputation beyond reputeRuss Beavis has a reputation beyond reputeRuss Beavis has a reputation beyond repute
Re: How do i find a variable and use it on Labview

Excellent point, Alan! Maybe Chris was getting too hung up on that concept.

In general, you should be able to do all of your programming without using global or local variables. Wires can go "everywhere" by simply wiring "through" structure boundaries or exploiting shift registers or sequence locals (look 'em up). Variables are only really necessary when

A) You want to clean up your block diagram since having wires everywhere can get out of hand.

or

B) You've got a set of parallel processes that need to share data (although I believe there may be a few other more advanced options that could be used). Processes WILL NOT run in parallel when they are wired together (since a wire cannot be read from until it is written to whereas variables can be read from at any time).

Another suggestion - check out Highlight Execution mode. It can be really handy for helping understand program flow and debugging.

Russ
Reply With Quote
  #22   Spotlight this post!  
Unread 21-01-2009, 10:50
Chris11246 Chris11246 is offline
Registered User
FRC #1647
 
Join Date: Jan 2009
Location: Southampton
Posts: 14
Chris11246 is an unknown quantity at this point
Re: How do i find a variable and use it on Labview

I was just trying to make a test vi that doesnt use the Crio but i couldnt make a value that could be used as the motor value that could be changed but still give me a value(i wanted to make it accelerate or decelerate and show the value of the motor) I can get what i want using the Crio stuff but I was just trying to figure out how to test it.
Reply With Quote
  #23   Spotlight this post!  
Unread 21-01-2009, 10:58
Jon236's Avatar
Jon236 Jon236 is offline
Registered User
AKA: Jon Mittelman
FRC #2648 (Infinite Loop)
Team Role: Mentor
 
Join Date: Jan 2004
Rookie Year: 2000
Location: Windsor, Maine
Posts: 741
Jon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond reputeJon236 has a reputation beyond repute
Re: How do i find a variable and use it on Labview

Simply create a control on the front panel to input your value.....then place an indicator to the output of your coding to show the result. Make sure to create a While loop to let it run.
__________________
Jon Mittelman

Senior Judge Advisor New England & Israel 2014-2015
Infinite Loop Mentor 2011-2015
TechnoTicks Mentor 2000-2011
Championship Chairman's Award 2009 Team236 TechnoTicks
Judge 2010-2015 Championships
Senior Judge Advisor New England District Championship 2014-2015
Judge Advisor Tel Aviv Regional 2007-2015
Judge Advisor Pine Tree Regional 2013
Maine Regional Planning Committee
New England District Planning Committee
Lead Inspector Microsoft Tel Aviv Regional 2006-2008
Judge & Lead Inspector GM/Technion Tel Aviv Regional 2006
Judge UTC Hartford Regional 2006
Reply With Quote
  #24   Spotlight this post!  
Unread 21-01-2009, 17:50
blackdeath's Avatar
blackdeath blackdeath is offline
Registered User
AKA: Shawn
FRC #2506 (Saber Robotics)
Team Role: Alumni
 
Join Date: Oct 2008
Rookie Year: 2008
Location: Franklin, WI
Posts: 6
blackdeath is an unknown quantity at this point
Re: How do i find a variable and use it on Labview

Just take the axis from the unbundle by name and hook it to the tank drive/arcade drive.vi input
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
Variable rollover with Labview (suggestions?) kamocat NI LabVIEW 7 22-08-2008 08:30
NEED GENERAL HELP on how to find programming and animation resources delphi demon General Forum 1 02-04-2007 15:58
how do i find the camera with labview? CompMaster NI LabVIEW 0 16-02-2006 12:52
How do you find time for sports and robots? Whalley General Forum 50 23-03-2005 12:11


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

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