LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Why can't I save this file?

Solved!
Go to solution

Hi!

 

I'm having some problems with this labview file. I want to create a 16 stacked sequence loop of the same controls which includes 12 valve controls and two linear actuator ( the files are attached below). Each sequence of the 16 stacked sequene are essentially a duplicate of the same set of VIs. However, I found that the save times are getting increasingly longer as I approached 16 stacks. For example, at the 12th stack it took about 15 minutes and then at the 13th stack it took 20 mins.

 

This wouldn't be a problem normally as I'll just have to wait longer right? Nope, at the 16th stack and whilst saving, the program keep alternating between a non-responding program and a responding program according to the windows task manager. The file also cant seem to be saved no matter how long I wait. Is this a problem regarding the computer processing power? or is there a limit on the labview program itself (like cant have more than 15th stacked sequences, too redundant codes etc). I am using labview 2013, a NI DAQ usb-6223 (I think) and two motors for this particular program.  I posted a file that contains the motor controls that i want to put in each sequence as well as a shortened version of the valve control file.

 

Regards,

Gabriel

0 Kudos
Message 1 of 3
(2,905 Views)

1. That many Stacked Sequence Structures usually point to a bad architecture.  Perhaps you should change to use a State Machine instead.

2. A single VI should not be approaching 4MB.  That tells me you have a very non-scalable architecture.  Perhaps you should change to using arrays or reentrant VIs and subpanels (essentially making a plugin architecture).


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 2 of 3
(2,884 Views)
Solution
Accepted by topic author Learning1

I suggest you take some LabVIEW tutorials, urgently. I saw you said 'stacked sequence' and then saw that your VI was 4mb in size (most are <1mb) so I suspected that something definitely wasn't right.

 

1) Get rid of the stacked sequence structure. It is a horrible construction and hides most of your code!

2) The button/case structure/true or false constant is completely redundant, you can just wire the values to the DAQ assistant, like this:

2015-10-27_15-03-50.png

3) Limit your block diagram to a single screen in size, I had to scroll through a lot of empty space to find your diagram!

4) Lose the 150 or so DAQ assistant VIs and replace them with the appropriate DAQmx functions. You will probably be able to replace all 150 instances of the DAQ assistant with a single DAQmx write. Each of those DAQ assistants contain a whole heap of code to initialise the device, write the data and then close the device which is why the VI is 4MB in size and probably why the whole thing runs slowly. You can probably replace the whole lot with a single while loop & case structrure, depending on what you're actually trying to achieve.


LabVIEW Champion, CLA, CLED, CTD
(blog)
Message 3 of 3
(2,881 Views)