LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

sound card control in LabWindow

I am a labWindow/CVI user. I am trying to control sound card to read and write data but have no idea how to do it.

Any help will apprciated. Thanks.
0 Kudos
Message 1 of 4
(3,980 Views)
John,

CVI does not provide specific functions to use the sound card, but this does not means that you can't use it. There are several ways you can do this, here a re a couple of options:

1) Use the Windows SDK to access the sound card. This would require you to call certain function in the Winmm.dll to open the sound card setup the buffer and start the acquisition. There is an example that ships with CVI that plays some files using the winmm.dll you can start form there and call the appropriate function; you can use the Windows SDK helps file included in CVI to find out more specifics. Here are some of the functions that you'll need:

waveInOpen
waveInStart
waveInReset
waveIn...etc....


2) Use activeX to control another application that would do
the recording for you. You can have Media Player for example, embedded in you CVI code. Here is an example that could get you started.

I hope this helps,

Regards,

Juan Carlos
N.I.
Message 2 of 4
(3,981 Views)

hi...Juan Carlos

Im using LabVIEW8.0...you have specified some functions in winmm.dll...

i need to play a wave file using functions waveoutopen,waveoutReset and WaveOutWrite...but i dont know how to use them here...

i have tried as per structures provided in SDK...but i could not get the result...can you get me out.....

 

Thanks and Regards

SODLB

0 Kudos
Message 3 of 4
(3,652 Views)

Hi SODLB,

this board is dedicated to CVI users, so you are not likely to find much help on very specific LabVIEW functions here: you should better post this question in the LabiVIEW forum, where I saw you have already posted similar questions.

As per calling SDK functions in LabVIEW I can point you to this KB entry that gives you some general rules on calling DLL functions via a Call Library node.



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 4 of 4
(3,644 Views)