From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

vi works in LabVIEW, but not when executed by TestStand.

Hi everybody.  I'm using LabVIEW 8 with the Sound and Vibration Toolkit, and TestStand2.  I am planning on using TestStand to execute a series of performance tests on an audio processing board.  When run independently, the vi (which I have attached here) runs correctly, and returns a value for the parameter being tested.  In this case it is SNR.

However, when executed by TestStand, the vi seems to run correctly, but returns a value of "NaN".  This causes TestStand to fail the test.

Does anybody know what is going on here?  I've checked FAQs and help files, etc...  Why would the vi work on its own but not in TestStand?

Thanks.

Brett Gildersleeve
Download All
0 Kudos
Message 1 of 14
(3,796 Views)
Hi,
 
Unfortunately, Your VI uses functions that I dont have, so I have removed them and used a constant.
Therefore I am not seeing your problem.
 
Teststand 2.0 VIs only have two outputs  Test Data Out and Error Out. So I thought maybe its your SNR output on the connector pane, but that doesn't seem to have any effect..
 
I would recommend actlually wiring up the Error cluster and feed in to the Error Out. Maybe you are actually getting and error generated but are not seeing it reported.
 
Did you say you are seeing the actual value at snr indicator?
 
Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 2 of 14
(3,788 Views)
Hi Ray,  Thanks for the reply.

Basically, when I run the VI on its own, I see the SNR value appearing both in the SNR indicator and in the Test Data Out cluster under Numeric Measurement.  The rest of the indicators are empty (string, report text, status, code, source).  My waveform graph shows an FFT of the signal.

However, when running the exact same VI through TestStand, I get NaN as the output.  The FFT of the signal is NOT displayed in the waveform graph...  strange.  No errors are received.

In order to make it easier to debug, I replaced all of the analysis functions with functions included in LabVIEW 8.  Now everybody should be able to run it.  I do a simple THD test this time around.  With the VI running on its own, I get a value of 1.8 as the THD and the Numeric Measurement of Test Data Out.  However, whenever running the test with TestStand, I get a value of NaN.

Same problem.

Any suggestions?

By the way, what exactly do you mean by "wiring up the Error cluster and feed in to the Error Out."?  I'd like to try it out, but I'm not sure exactly what you mean.  I already have the Error out cluster wired up, I think.

Message Edited by TheSleeve on 05-22-2006 12:12 PM

Download All
0 Kudos
Message 3 of 14
(3,785 Views)
Hmmm... new update.  I think perhaps the fact that I'm executing with TestStand is throwing off the synchronization of my SubVIs.  The general idea of this test is that the Play Waveform and Acquire Sound subVIs need to execute at the exact same time.  For some reason it looks like TestStand is making them execute seperately, while they normally execute at the same time otherwise.

Since Acquire Sound is executing AFTER Play Waveform, the acquired signal is essentially zero...  when doing tests on an input of zero, SNR and THD tests will by definition have undefined results.

So it seems I may have pinpointed the problem.  But how do I fix it?

Is there any way to force two SubVIs to execute at the same time (or nearly at the same time)?
0 Kudos
Message 4 of 14
(3,773 Views)

Hello Sleeve,

I've executed your VI in LV8.0.1 and ran your SEQ in TS3.5. Everything runs as expected - the numeric value is always reported correctly in TS.

Guenter

0 Kudos
Message 5 of 14
(3,774 Views)
Hello Sleeve,
 
"Is there any way to force two SubVIs to execute at the same time (or nearly at the same time)?"  --> 
Wire the
Signal Generator's Error Out
to
Play Waveform Error In
and
Acquire Sound Error In.
 
Guenter
0 Kudos
Message 6 of 14
(3,764 Views)
Vielen Dank, Herr Mueller.

Sehr interessant, nicht wahr?  It seems that the same code that is not working on my machine is working fine on yours.  Very interesting indeed.  I am using LabVIEW 8.0, and TestStand 2, but it is the TestStand evaluation version.  I wonder if there is a difference.  Can anybody else replicate these results?

Brett
0 Kudos
Message 7 of 14
(3,763 Views)
Guenther,

Thanks for the advice.  I have tried connecting the error lines as you instructed.  This has not changed my result.

Brett
0 Kudos
Message 8 of 14
(3,762 Views)
Hi,
 
The evaluation versions only allow an execution runtime of a few minutes. How long is your runtime?
 
Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 9 of 14
(3,753 Views)
Hi Ray,

Thanks for the tip.  In fact, my run time for this sequence is generally under 5 seconds, so unfortunately it seems that might not be a factor here.  Are there any other limitations with the evaluation version?
0 Kudos
Message 10 of 14
(3,749 Views)