BrokenArrow Posted January 29, 2009 Report Share Posted January 29, 2009 In a loop performing reads on a card 24 hours a day, (analog inputs in this case), are there any issues with regard to using a Sub-VI or not? Note the JPG, and note that in this case the loop is slow, so we don't care so much about the 2.5uS (?) that it takes to open tand close the VI every loop iteration - I'm just wondering about the effect on memory in the long term. I would definately turn off debugging, but what about any gains with the Prioroty settings? Or Reload for each call vs. load and retain vs. load with callers ... etc. Quote Link to comment
PaulL Posted January 29, 2009 Report Share Posted January 29, 2009 I don't think you will encounter any issues using a subVI. Have you experienced any issues after deploying the application and monitoring the PC's memory usage? Quote Link to comment
Grampa_of_Oliva_n_Eden Posted January 29, 2009 Report Share Posted January 29, 2009 QUOTE (BrokenArrow @ Jan 28 2009, 08:24 AM) In a loop performing reads on a card 24 hours a day, (analog inputs in this case), are there any issues with regard to using a Sub-VI or not? Note the JPG, and note that in this case the loop is slow, so we don't care so much about the 2.5uS (?) that it takes to open tand close the VI every loop iteration - I'm just wondering about the effect on memory in the long term. I would definately turn off debugging, but what about any gains with the Prioroty settings? Or Reload for each call vs. load and retain vs. load with callers ... etc. The only thing I see that could be different is the cluster. In the lower no-sub-VI loop, LV can reapeatedly through the last value into the buffer that is the output tunnel of the while loop. In the sub-VI flavor the sub-VI does not know the cluster is not being used whil looping so it has to return a copy of that data each time. Ben Quote Link to comment
BrokenArrow Posted January 29, 2009 Author Report Share Posted January 29, 2009 QUOTE (Paul_at_Lowell @ Jan 28 2009, 11:14 AM) I don't think you will encounter any issues using a subVI. Have you experienced any issues after deploying the application and monitoring the PC's memory usage? Well, no, not on this application, but in the past, I had an RT application that had a huge memory leak. Some of that issue ended up being a bug that NI admitted (fixed on 8.5.1). But since then, I get very nervous around applications that run for days on end. QUOTE (beBulus @ Jan 28 2009, 11:28 AM) The only thing I see that could be different is the cluster. In the lower no-sub-VI loop, LV can reapeatedly through the last value into the buffer that is the output tunnel of the while loop. In the sub-VI flavor the sub-VI does not know the cluster is not being used whil looping so it has to return a copy of that data each time. On the non-SubVI flavor, which was a paste from the SubVI, I forgot the shift register for the incomming cluster. It should be there. Actually, since the cluster will change every iteration, I could just wire a constant there. Thanks Ben, I like you new name. ------ What do we think about setting a SubVI like this one to 'Load and retain' ? Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.