LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

working with large .wav files labview

I am trying to work with a ~7 hour .wav file in Labview.  This file plays in QuickTime, but cannot be read by Labview.  When run through the sound player.vi example, the program crashes.  Any advice for breaking it up into smaller, readable pieces?

0 Kudos
Message 1 of 2
(2,827 Views)

You should be able to read blocks of the wave file directly in LabVIEW with Sound File Read.vi, using an appropriate number of samples and rolling sample offset. The waveform chunks can then be fed to the sound output VIs for playback.

 

There will be a bit of juggling between reading the wave file, feeding the waveform to the playback VI, reading the next chunk while the playback is occurring, and waiting for the playback to finish before sending the next bit of the waveform. Sounds like a good producer/consumer candidate...

 

You could also break up the wave file into smaller files using an external program such as Audacity (assuming it doesn't choke on a 7h file).




Certified LabVIEW Architect
Unless otherwise stated, all code snippets and examples provided
by me are "as is", and are free to use and modify without attribution.
0 Kudos
Message 2 of 2
(2,808 Views)