LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

I want to use multiple sound cards with LabView

Hello,
Has anyone used more than one sound card in a Windows XP machine and called them from LabVIEW to play multiple wav files at the same time?
The Sound VIs in LabVIEW mention calling the Windows API to determine the number of sound cards available and their capacities. In Windows XP, what would this function call be?
0 Kudos
Message 1 of 2
(2,640 Views)
Hi,

You can definitely do this however you can't use the Play Sound vis. The VI to play a wav file is a direct call to the OS to play the file, Windows will find the most appropriate sound card and play it there.

The way to achieve this is by opening up the WAV file and use the Snd Write Waveform VI. One of the inputs for this VI is the device number. Usually they start at 0 and increment by one. You can have a VI where you open the 2 files and then use 2 write waveform vis using different device numbers.

You can get all the information about the soundcards by calling the Windows SDK, however this can take some work and may be easier to do it in a DLL.

Let me know if you have any questions.

Regards,

Juan Carlos
N.I.
0 Kudos
Message 2 of 2
(2,640 Views)