LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can a sound card be configured to both output and input audio?

I am building a radio tester and would like to output a 1 kHz tone from the laptop's sound card, and then after its been through the radios, input the audio signal again and carry out a SINAD measurement on it.  I can get the VI's to carry out each operation separately  (that is, get one to produce and output a 1 kHz tone, and the other to read an input audio signal and produce a SINAD measurement), but I can't get the two to work together as required. 
 
I think the problem is to do with the device number.  In both VI's the device number is set as 0, so does this cause a problem when running them together.  The tone is being generated fine, but but it appears that this is what the SINAD VI is measuring, not the input coming from the radio.
 
Does the device number refer to the sound card itself, and if so, is it possible to distinguish between the audio in and audio out ports?
 
Any help would be appreciated.
0 Kudos
Message 1 of 9
(3,360 Views)
There is a simultaneous sound vi in the examples. It says that a PC would require two different sound devices.
0 Kudos
Message 2 of 9
(3,346 Views)

Thanks unclebump,

looks like I can't output audio and input audio on the same sound card at the same time.  Can anyone confirm if that is the case, and if so, suggest a way around the problem.  

As you can probably tell I'm very much a novice when it comes to Labview.  Any help will be gratefully received.

BD

0 Kudos
Message 3 of 9
(3,337 Views)
The question here is can your sound card support simultaneous input and output.  LabVIEW can do it if your sound card can.  Most modern sound cards can handle this.  There was a thread about this a few weeks ago, but I don't have a link handy.  The real question is the duplex capability of the sound card.
0 Kudos
Message 4 of 9
(3,324 Views)
Thanks for the info.  I've checked out the sound card and from what I can gather it is full duplex.  The question now is do I have to configure the sound card itself to allow simultaneous input and output, or do I have to do anything with my programs to allow it, or should the sound card automatically allow simultaneous input and output.
 
BD
0 Kudos
Message 5 of 9
(3,305 Views)
Well. I think you should look through the sound card examples and try the simultaneous sound in/sound out one.  I really use a Mac, so I can't say I have been through the test myself, but I think it is all in getting the right initialization from LabVIEW so that the sound task always refers to the same board for both sound in and sound out.  Good luck.
0 Kudos
Message 6 of 9
(3,297 Views)

"bigdog" <x@no.email> wrote in message
news:1143846609102-346566@exchange.ni.com...
> Thanks unclebump,
> looks like I can't output audio and input audio on the same sound card at
the same time.&nbsp; Can anyone confirm if that is the case, and if so,
suggest a way around the problem.&nbsp;&nbsp;
> As you can probably tell I'm very much a novice when it comes to
Labview.&nbsp; Any help will be gratefully received.
> BD

You certainly can - just look at your Windows Soundcard settings and play
with them for a bit. Are you using Line in and Line out? (speaker that is).
What I do is test them separately then together.You don't need two sound
cards by the way though you must inhibit line in so it doesn't play through
the speakers otherwise the input and output get mixed together.The otehr
problem you should have is that teh sine wave will sound as if it is
intermittant - there is a fix for this.


Tam


0 Kudos
Message 7 of 9
(3,272 Views)

Thanks for the advice, inhibitng the Line In has done the trick and the output and input are no longer mixed.  The sine wave output is reasonably solid but can be a little intermittant.  It is workable and can be used for testing purposes.

Cheers,

BD

0 Kudos
Message 8 of 9
(3,260 Views)
Hello Bigdog!
 
Could you please attach the .vi you use for this problem.
I have the same problem, but cannot fix it myself 😞 ,
I want to make a SINAD measurement of my audio device.
 
Thank you!
 
Mark
0 Kudos
Message 9 of 9
(2,808 Views)