Hello RRRRSSSS,
Have you gotten a chance to look at the shipping examples that come with LabVIEW? There are some from the Example Finder that I think may work in this situation (trying to play a file continuously).
Look at Play Sound.vi, which plays a sound using the sndPlaySound Windows API. This demonstrates how to use the Call Library Function to call a DLL.
Sound File to Sound Output.vi also illustrates how to play a sound file continuously, reading the sound file in pieces, and playing each piece at a time.
Good luck!
Janell R | applications engineer
"Sound file to sound output "is what my vi is made from, the example only play's once.
I made an attempt to modify it and cannot get it to play once and repeat.
I did not find a " Play sound file' , I found a 'Play sound" example.
In addition to what I have I need to be able to set the volume, which does not seem possible in "play sound".
I have a working program with the older LV 6.1 sound files, but I was wanting to use the 8.2 vi 's , figured just replace them and it would be good to go but this has not been the case.
Hi RRRRSSSS,
See attached image. The idea is to read the WAV file and then run the sound data in a loop. You could keep loop delay to 1ms. In my case 10ms worked fine.
I could get my sound data to play as long as I hit the 'Stop' button.
Hope this helps.
- Gurdas
The soundOutput.vi file is exactly what I wanted done except I need to add something to the code which would search for a wav file in a folder and then play it.
Any help would be appreciated. I am new to Labview and I have no idea how to start it.
Thanks