LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Re: Read large wav files

I am having trouble reading .wav files greater than 1 GB. It seems the position offset is not offsetting - I keep getting the same set of points even though the offset out is incrementing. This happens no matter how many samples are read - even a small number like 256. No problem for files less than 1 GB. I am running 64 bit labview with 32 GB ram.

0 Kudos
Message 1 of 7
(2,413 Views)

Hi miklovicd,

 

so there is a problem with your VI - but you don't show that VI…

Mind to attach some code? (No "images of code", real code please!)

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 7
(2,405 Views)

@miklovicd wrote:

I am having trouble reading .wav files greater than 1 GB. ... No problem for files less than 1 GB. I am running 64 bit labview with 32 GB ram.


Look at the function you are using to read the data. While the low level file functions in LV do support files with offsets that can be described by an I32, the higher level file (Read Delimited Spreadsheet.vi for example) functions do not.

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 3 of 7
(2,379 Views)

I did a Web search for Read large WAV files.  There is some discussion of this, including a note that WAV files are limited to 4GB because they use a U32 for the File Size header, but if you are using LabVIEW 64, you (optimistically) should not have a problem.

 

But you also say you can't reliably "read in chunks", which seems to be the solution others have used successfully.  So it's either Hardware, Bad Data, or Software.  We can eliminate the first two -- can you "play" your sound file through your PC using Media Player or something similar alright?  If so, that leaves Software -- for help with that, attach your VI (don't bother attaching a non-executable picture).

 

Bob Schor

0 Kudos
Message 4 of 7
(2,365 Views)

Its none of this. Turns out labview just doesn't support wav files over 2 GB.

0 Kudos
Message 5 of 7
(2,136 Views)

@miklovicd wrote:

Its none of this. Turns out labview just doesn't support wav files over 2 GB.


That's the first time I've heard of that.  Are you sure it's not a case of what Ben discusses above?  Anyone know of a 2 GB limit on a wav file (that doesn't involve a memory/file/OS issue)?

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 6 of 7
(2,103 Views)

@miklovicd wrote:

Its none of this. Turns out labview just doesn't support wav files over 2 GB.


Wild guessing time!

 

Are you using he file functions found under the

 

Graphics & Sound >>> Sound >>> Files palette

 

that invokes a dll with input values that are an I32 ?

 

If so yes, an I32 is limited to a max of 2G.

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 7 of 7
(2,096 Views)