LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

VI saves blank data file

Hello,

      I just started using Labview a few weeks ago and am having trouble with a VI that I was given by someone who previously worked on the project. The VI's function is to acquire and record data from a scanivalve array of 11 pressure taps. Up until a few days ago, everything worked fine (for a test run) but now, when I try to run the VI, its just saves a blank lvm file (with just the variable headers). There are no error messages from the run and I haven't changed anything in the VI or any of the sub VIs. Has anyone encountered a problem like this or I'd appreciate any suggestions on how to deal with this. (The computer I'm using is a few years old and is running LabVIEW 7.1 on Windows XP).

 

Thanks,

Aarthi

 

0 Kudos
Message 1 of 15
(3,640 Views)

I don't think you give enough information to troubleshoot.

 

How do you interface to the hardware? Does the DAQ hardware still actually work? Maybe no data is acquired?

 

Since you have access to the VIs, see if errors are handled properly. Maybe no errors are shown because they are not handled or even suppressed.

0 Kudos
Message 2 of 15
(3,628 Views)

Thanks for getting back to me. The scanivalve interfaces to the computer via an NI DAQ (PCI 6221). I was working on trying to confirm if the DAQ itself works and I used the Measurement and Automation explorer to do this - all channels are connected like they should be and I'm getting the expected trend from the values. I also tried creating a small sample VI in LabVIEW with just a DAQ assistant and a Write to LVM file utility and  that worked fine as well. Reg the error handling, the VI that I'm having trouble with does use the General Error Handler. Would it be alright if I post the VI here so you could take a look at it? It comes with a few sub VIs as well and I could include those as well. 

 

Thank you for your time.

0 Kudos
Message 3 of 15
(3,612 Views)

Hi Aarts

 

Yes, you can attach your VI and I'll take a look at it for you.

Peter E
Applications Engineer
National Instruments
0 Kudos
Message 4 of 15
(3,586 Views)

Hello,

     Please find attached the VI that I've been having trouble with (the main VI is testing and the other 2 are sub-VIs). There are another 5 sub VIs that go into the main one but I couldn't attach all of them since the maximum number of attachments for a post is limited to 3. The two sub VIs that I have attached here are the ones that directly relate to the writing of the data but I'll be happy to put up the rest as multiple posts if you need to look at them as well.

 

Thanks again for your time,

Aarti

0 Kudos
Message 5 of 15
(3,581 Views)

I see that you also have an indicator for the data that is outputting to the .lvm file. Does any information show up on the front panel under "Data" when you run this VI?

Peter E
Applications Engineer
National Instruments
0 Kudos
Message 6 of 15
(3,576 Views)

It is hard to tell without the hardware and all the missing subVIs, but the 2D array in the shift register gets cleared when "scan" is pressed. I probably would also initialize that shift register. (assuming that the comtrol named "array" remains empty, because it never gets written and is not assigned to a connector)

 

(Overall, ther seems way too much unecessary code.)

0 Kudos
Message 7 of 15
(3,572 Views)

Thank you for the reply , Peter. No, the data array stays grayed out during the run. Is there anything else I could check on to make sure the data is being passed into the VI?

0 Kudos
Message 8 of 15
(3,559 Views)

I agree there is too much unnecessary code as well but as I had mentioned, this is something that was given to me by someone who worked on the project earlier and Im not sure if I should start getting rid of parts. I'm still trying to work on the shift register as you had mentioned and will let you know how it goes. Thank you for your time.

0 Kudos
Message 9 of 15
(3,558 Views)

I agree with Altenbach on both accounts there (initalization and the fact that scan clears the array).

Peter E
Applications Engineer
National Instruments
0 Kudos
Message 10 of 15
(3,553 Views)