08-22-2008 09:38 AM - edited 08-22-2008 09:47 AM
I am using labview to strip the file header from a wave file. I have already done this (it's easy).
THen I want to write the information back to a file. When I do this I end up with 4 bytes appearing in the file that arn't in the information I am sending. They arn't the same 4 bytes if I change the informaiton I am sending.
I think I have it narrowed down to the actual write funtion, If I take the read funtion and wire it to the write function I end up with the 4 extra bytes of data.
08-22-2008 09:41 AM
Hi crewex,
connect a false constant to the top right boolean input of the write binary function. It writes some additional information to the file and this input is true as default.
Mike
08-22-2008 09:48 AM - edited 08-22-2008 09:48 AM
Also, from the LabVIEW Help:
prepend array or string size? indicates whether LabVIEW includes data size information at the beginning of refnum out when data is an array or string. If prepend array or string size? is FALSE, LabVIEW does not include the size information. The default is TRUE. prepend array or string size? only controls the top-level data size information. Arrays and strings in hierarchical data types such as clusters always include size information.
08-22-2008 12:48 PM
Thank you that of course was the problem, but now the code is only writing 253 bytes of data instead of the 2300
08-22-2008 01:11 PM - edited 08-22-2008 01:11 PM
Hi crewex,
i think it´s because you divide the file size by 8. You don´t need it. It´s already in bytes.
Mike
04-19-2016 04:10 AM
I was struggling in saving single at 1uSec into binary and reading back with junk data.
This saved my life. thanks.