Jump to content

passing data between VI's


Recommended Posts

Hi Freinds,

I want to acess the data of one Vi (which is local to that loop) in the other loop ,How can i do this ?

My both Vis are running in parellal.

Harsh

5827[/snapback]

There are a number of ways:

1 Set up a Q, and write data in one VI and read a Q element from the other VI.

2 Use a Notifier. When you have data, notify it to the other VI. With notifiers there is no caching of data (like a Q) so if you don't listen when its sent, it will be missed.

3 Use a Global between the two VI's.

Neville.

Link to comment

And if you have to take the easy way out and use a global, don't use a LabVIEW global. Read up on LV2 or Functional globals, which are VI's that retain information in between calls (so they can be called anywhere to access that information, thus making them global). Regular LabVIEW globals are in general, a bad idea.

Edited to add, btw...... this is probably in the wrong forum. Maybe the sysadmins can move it.

Link to comment
Hi Freinds,

I want to acess the data of one Vi (which is local to that loop) in the other loop ,How can i do this ?

My both Vis are running in parellal.

Harsh

5827[/snapback]

Since I see you are new to LabView you may not be familiar with all the terms discussed.

here is a simple vi I built a while back that shows the various ways to transfer data between loops.

Download File:post-584-1124939201.llb 7.1 version

Download File:post-584-1124942360.llb 6.1 version

I would personally recommend learning to use Queues.

functionals second

and locals only when you have to. (Writing to a Input Control)

good luck

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.