LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Methods to break down large VI so that it runs faster


DianeS wrote:
I knew about the method for setting all front panel controls to default, but obviously I didn't know about the one for individual controls.  Thanks!  That might come in handy for me some day...

I think We are ALL getting a lot of good ideas out of this thread.  WOW! great OP and the OP is working hard to master concepts and style.  I could stick with threads like this all day!


"Should be" isn't "Is" -Jay
Message 41 of 68
(1,303 Views)

Agreed on all points!  There's nothing more fun than helping someone who genuinely wants to learn and who works hard in order to do so -- and there's the added bonus that the rest of us get to learn right along with them!

 

Go, OP!!  Smiley Happy

Message 42 of 68
(1,302 Views)

Haha,

 

The OP also feels like a bonehead for missing that one.  I'm chalking it up to a long week, and it being Friday.

 

Speaking of which, Happy Friday to everyone, and thanks for the compliments!

 

Hoping to finish cleaning it up this weekend, and post Monday.

 

Message 43 of 68
(1,289 Views)

Is there a way to enque two elements in a given order in one operation? 

 

I've condensed my state machine quite a bit (thanks Jeff for that suggestion) but I still have instances where I want one case to follow another for a given event. I could probably combine states further, but it does help keep the code clean by breaking out a few of those states.

 

Currently I wrote it (incorrectly) by adding an element to the queue from within the state machine.

 

 

 

0 Kudos
Message 44 of 68
(1,260 Views)

Also,

 

Is there any caveat to using action engines?  I find myself prefering them over using shift registers on the main vi, as they result in cleaner looking code.  Do they use any more or less memory, processor, etc?

0 Kudos
Message 45 of 68
(1,258 Views)
One more question (for now), is there a way to get an initialize, or first run type of event? As one could assume from my last post, I have some AE's storing data for me, and wanted to add an initialize case, so that I could use that to set some defaults. I would only want it to run the first time though.
0 Kudos
Message 46 of 68
(1,256 Views)
I seem to have figured a few of those out.  What is the best method to post the whole code?  Zip file of the folder tree?
Message Edited by krwlz101 on 03-14-2010 04:46 PM
0 Kudos
Message 47 of 68
(1,250 Views)
If you have more than 2-3 files i'd say zip. 🙂
G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 48 of 68
(1,231 Views)

Ok,

 

So not as clean as I would like it.  Long Monday.  Anyway, here is the code, its a little laggy for the solution to the forced response (probably all the sines and cosines).   Not sure if I added multiple tasks to the queue in the best way either.

 

Is there a way to disable the FP during certain solve type actions?  It would be nice to have a light or something at least to indicate solve time. 

 

I think I still end up stacking up multiple solves under certain cases.   I'm considering moving the solve to another state, and activating it differently.

 

I think most of the code could be improved, but since I am my own customer, this can be a work in progress for a long time.
Message 49 of 68
(1,207 Views)

And I'm very unhappy with my fourier series.  It works most of the time, but if the number of number of points in the evaluation isn't high enough for the peak amplitude, the error value eventually skyrockets, causing an infinite loop.

 

If the FFT will do what I need, perhaps I should look harder into that.

Message 50 of 68
(1,198 Views)