LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Regarding .wav file to readable string conversion

How can I convert Audio (.wav) and video files to readable string (text) in labVIEW? I am using the LabVIEW 2015 & USRP 2932/NI USRP N210. 

here I am attaching a VI, in this VI I am getting the string of float numbers. Is there any method by which I can convert this string to readable text or directly from the waveform received I can get the readable string. Please let me know.

0 Kudos
Message 1 of 13
(5,519 Views)

hi rinks,

sorry to be pedantic, but why would you convert a video to string?

 

video is a binary format, at least for me it makes no sense to strip all nonprintable chars and have the rest as string.


If Tetris has taught me anything, it's errors pile up and accomplishments disappear.
0 Kudos
Message 2 of 13
(5,516 Views)

As I am transmittiing a video file but my VI takes the string input that's why I need to convert the video into readable text string.

Is there any other method?

kindly let me know.

0 Kudos
Message 3 of 13
(5,508 Views)

As u said video is a binary format so how could I extract the binary array of the video?

0 Kudos
Message 4 of 13
(5,504 Views)

@Rinks wrote:

As I am transmittiing a video file but my VI takes the string input that's why I need to convert the video into readable text string.

Is there any other method?

kindly let me know.


Way to little information to make even a reasonable guess what would be the best solution.

Which VI does take a string input?

Why do you talk about readable text string for a binary file format? There could be many ways of making a readable text string such as taking each byte and printing the hex value of this in the text string. I doubt that this is what you want to to, but just saying.

Maybe your function wants really text, maybe it just wants a binary byte array represented as a string (quite possible as there are a few LabVIEW functions that traditionally use strings when they should really have used a byte array instead).

Tell use what you want to do with the video file, what functions you want to use to process it, etc, etc.

Rolf Kalbermatter
My Blog
0 Kudos
Message 5 of 13
(5,476 Views)

In the attached zip file, there is packet transmitter and packet receiver code which is taking string (text) input but I need to transmit video input. How can I transmit the video file from transmitter to receiver? 

If there is any other way to do this kindly let me know.

0 Kudos
Message 6 of 13
(5,450 Views)

So the real question you are asking is:

How do I transmit a .wav file (which is an audio format - how did we get to talking about video?) using the uploaded code?

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 7 of 13
(5,442 Views)

I guess you could just use the Read from Text File? Function, convert it into an array of bytes and then use the Number to Decimal String to convert it into something readable.  Then do the opposite at the other end.  But that seems hugely inefficient to me.

 

This seems like a classic case of "When all you have is a hammer, all problems look like nails."  I recommend getting - or making - the right tool for the job.

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 8 of 13
(5,439 Views)

Hello, In the attached file I m converting the audio input to readable string and from the input waveform get back audio file as output but in this I m getting very much noise or the string is not the exact string? How can I remove the noise or how to get the exact string? 

Audio is also in binary format but i am unable to find the binary format of audio file. kindly help me.

Download All
0 Kudos
Message 9 of 13
(5,416 Views)

@Rinks wrote:

Hello, In the attached file I m converting the audio input to readable string and from the input waveform get back audio file as output but in this I m getting very much noise or the string is not the exact string? How can I remove the noise or how to get the exact string? 

Audio is also in binary format but i am unable to find the binary format of audio file. kindly help me.


I have no idea what this code is supposed to do, but it's not doing what you said it should do.  I'll give you a starting point.  Forget about transmission for now.  Concentrate on encoding the file to a string format.  (Simple if it just needs to be a stream of bytes, but a bit complicated if it has to be ASCII.)  Then concentrate on decoding back into binary.  (Again, simple if just a byte stream, a bit complicated if ASCII).  Only after success should you even worry about using the software you've provided.

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 10 of 13
(5,401 Views)