LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Passing data into a variable

Hi, 

 

All I want to do is pass numerical data into a variable, and then access it later. 

 

Specifically, I use the Read Vector Space Position VI to find the X and Y positions of my motors. When I press a button, I want the X and Y position at that moment to be saved, so that I can access this information later.

I would like to do this in a subVI.

 

I have read tutorials on functional global variables, but so far they have been quite confusing. Specifically I do not know how to place/use uninitialized shift registers. 

 

If someone could create a simple example code, that would be extremely helpful. I am using Labview 2011.

 

Thanks

0 Kudos
Message 1 of 3
(2,488 Views)
What specifically do you find confusing?

To create an uninitialized shift register, you create a loop, put a shift register on the loop, and then don't initialize it.

Inside the loop you put logic that defines when you want to write data into the shift register, and when you just want to read out what is already there.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 2 of 3
(2,483 Views)

Action Engine <- must read nugget

 

If you don't understand shift registers...

3 Hour Introduction
6 Hour Introduction
LabVEW Basics
Self Paced training for students
Self Paced training beginner to advanced, SSP Required
LabVIEW Wiki on Training


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 3 of 3
(2,478 Views)