LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

sound generator application crashes

I'm generating 90-degree phase offset sinusoids with noise on two sound card outputs (each card has stereo out for in-phase and quadrature output). I'm generating 4 sinusoids per soundcard and my user interface provides control over frequency and amplitude for the 8 complex sinusoids (16 real) as well as the noise amplitude. I'm using 4 "Noise and Tones Waveform" vi's to generate the tones and noise for four outputs (left and right channel on the 2 sound cards). I'm running at a 44.1kHz sample rate and the "Noise and Tones Waveform" vi is set for a block size of 4096 samples. The Sound Output (SO_xxxx) vi's are used for sound card output and I've configured the # of buffers from 2 to about 8.

I need to be able to adjust all the t
one parameters while the tones are playing.

My problem is that, after the application has been running for 15 minutes or so, the sound output stops. I can still move the sliders and other user controls on the front panel and the diplayed numbers change, but I cannot halt the vi using the usual method using a button the change the while condition to false inside my main while loop.

My Dell PC has a 1.8MHz P4 with 512MB of RAM and I'm using 2 Creative Labs Sound Blaster Audigy PCI soundcards.

Thanks!
0 Kudos
Message 1 of 10
(3,159 Views)
kevinm,

Have you tried to reduce the application to generate only one channel simple waveform at a time ? What is the long term behaviour of such reduced vi ?

Arkadiusz Roszczewski
National Instruments
0 Kudos
Message 2 of 10
(3,159 Views)
I reduced the application to a single stereo channel (left and right channel for a single sound card), for a total of 8 sinusoids using 2 "Tones and Noise Waveform" vi's. It has been running for about 4 hours with no problems.

Thanks,

Kevin
0 Kudos
Message 3 of 10
(3,159 Views)
Not so fast ... after another hour, the sound output bacame "choppy" -- pulsing about 4-5 times per second. Task Manager shows CPU Usage at 13% and Memory Usage at ~ 352000K.

If I switch between applications (using Alt-Tab), the output stops momentarily. When I opened Outlook, the output stopped, then began pulsing at a slower rate, and the rate climed to ~ 4-5 pulses per second.

Sounds like some sort of realtime deadline was missed and wasn't recovered cleanly. I wouldn't mind if the output stopped momentarily if I start up a big application, but for it to go into this persistent pulsing behavior with no way to recover is unacceptable.
0 Kudos
Message 4 of 10
(3,159 Views)
kevinm,

Do you generate a waveform in every step of the loop or only when parameters (eg. frequency) have to be changed ? Could you send a fragment of your code which can reproduce the problem.

Arkadiusz Roszczewski
National Instruments
0 Kudos
Message 5 of 10
(3,159 Views)
I've attached the reduced version of the application.

How would I change it so that the waveforms are only generated on parameter changes?
0 Kudos
Message 6 of 10
(3,159 Views)
kevinm,

I have reproduced this behaviour with your reduced application. The problem has been reported for investigation. I will inform you about the status or the solution on Tuesday 20.

Arkadiusz Roszczewski
National Instruments
0 Kudos
Message 7 of 10
(3,159 Views)
kevinm,

It seems that the problem can be caused by SO Wait.vi and its interactions with the sound driver. Detailed description of this behaviour has been sent to our R&D department for further investigation.
Thank you for your feedback.

Arkadiusz Roszczewski
National Instruments
0 Kudos
Message 8 of 10
(3,159 Views)
Is anyone working on this issue? When could I expect an answer? Thanks!
0 Kudos
Message 9 of 10
(3,159 Views)
kevinm,

The issue has been reported and confirmed. Our R&D department is looking into it and will work on a solution for the future release of LabVIEW.

Arkadiusz Roszczewski
National Instruments
0 Kudos
Message 10 of 10
(3,159 Views)