LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Combining Two VIs

Hello,
I am working on two different VIs. One of them is Vibration analysis and other one is voltage reader. I collect the amplitude and frequency values as well as Peak to Peak voltage and RMS voltge from the first VI. I collect just the voltage values resulting from a pressure transducer. I would like two cobine these two VIs, so that I can get all the values in one sheet and also able to see the graphs of different variable in one VI. I have PCI-4452 DAQ board with SHC-68 switch connected by BNC cables. I am attaching the VIs, I work on. Thank you.
0 Kudos
Message 1 of 19
(4,274 Views)

Hi Nishant,

I haven't looked at your vi's yet. 

Typically, you can do this by treating the 2 vi's as sub-vi's within a vi.

One question is:  do you need to synchronize the acquisitions?  In other words, is there a time dependency between the two? Or are they treated as two completely seperate entities?  This will impact any suggestions.

RayR

0 Kudos
Message 2 of 19
(4,265 Views)
Ray,
 
thanks for the reply. I need these two VIs run at same time. I will be reading the amplitude value and the corresponding pressure(votage from the second VI) value at that point, thank you.
 
Nishant
0 Kudos
Message 3 of 19
(4,252 Views)

Nishanth,

  • You cannot Run two Analog input tasks/ two seperate Analog Input acquisition VI's on the same Device
  • So acquire all your Voltage signals in one single acquisition Task/ VI. Now from the acquired values, index out all the vibration data channels, perform your Vibration analysis only on those channels

Hope this helps

Regards

Dev

0 Kudos
Message 4 of 19
(4,233 Views)

Well,

it depends, you can acquire multiple channels simultaneously 😉

It's a question of design:  requirements vs solutions.

Anything can be done.... it's all a matter of time & $$$  😄

0 Kudos
Message 5 of 19
(4,209 Views)
Dev,
 
Thanx for the reply. Would you eloborate on the method you mentioned above. I am still a novice to LabVIEW, thank you.
 
Nishant
0 Kudos
Message 6 of 19
(4,198 Views)

Joe,

Have you looked at my VIs, what are the chances running both at the same time? Would you explain, thank you.

Nishant

0 Kudos
Message 7 of 19
(4,199 Views)
Without looking at all into what you are aquiring or how... i notice you have two while loops in whiich I assume all the data collection is taking place.

If you have the screen for it... just copy the code from the one and paste it side by sdie with the other, you can run parallel while loops.

This is just looking at your code for a couple seconds... and assuming they can be run at the same time independently. I assumed you are currently running these two VIs at the same time. Hope this helps
0 Kudos
Message 8 of 19
(4,190 Views)

Hi Nishant,

I am looking at your vi's right now... or at least trying to.. 😉

it appears that you have a project setup for this..  Is that correct?  And using LV8.0?

I don't have many of the sub-vi's that are needed to run the vi, such as "AI clear.vi", "AI Config.vi", "AI Start.vi", "My Data Processing.vi", "AI Read.vi", "AI Read (waveform).vi", "SVT Weighting Filter.vi", "SVT Weighting Filter (1 Ch).vi", "SVT Power Spectrum", "SVT Power Spectrum (1 Ch)", and others...

When there is a will, there is a way...  😉

At the moment, I don't see what would prevent you from being able to implement a solution where both run simultaneously.  As long as they do not use the exact same resource at the very same time.  It may require modifying the sub-vi's, but I can't tell without seeing the overall vi's (they are full of missing vi's)..

RayR

0 Kudos
Message 9 of 19
(4,186 Views)

Hi MJB,

I will try the way you suggested. Let you know, if i get anymore problems, thank you.

Nishant

0 Kudos
Message 10 of 19
(4,177 Views)