Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Convert from .wav to .raw
Date: Thu, 29 Oct 2009 14:33:19 +0000 (UTC)
Organization: STFC Rutherford Appleton Laboratory
Lines: 27
Message-ID: <hcc93f$aad$1@fred.mathworks.com>
References: <hcc7pn$fat$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-03-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1256826799 10573 172.30.248.38 (29 Oct 2009 14:33:19 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 29 Oct 2009 14:33:19 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 968489
Xref: news.mathworks.com comp.soft-sys.matlab:580989


"Fabrizio Di Paolo" <fabry1981@gmail.com> wrote in message <hcc7pn$fat$1@fred.mathworks.com>...
> Hi,
> 
> I have a problem about a speech recognition.
> 
> I have to modify a function that recognize the words in an audio file, but I need for a .raw file. 
> 
> I record the speech from a microphone with wavrecord(), and so I obtain a .wav file.
> 
> So, the issue is: how can I convert .wav file in a .raw file? 
> Otherwise, can I get audio data directly in a .raw file?
> 
> Thanks to all.
> 
> Fabrizio

What do you mean by a .raw format? If you mean that the data isn't compressed, then I was under the impression that is exactly what the wavread gave you, thus

[rawdata,samplefrequency,digitizationlevel] = wavread(myfile.wav);

gives you a two column vector output in rawdata (one for the left microphone, one for the right - if you are messing about with a stereo setup). The samplefrequency gives you frequency at which it was sampled (set in wavrecord), and effectively digitizationlevel gives you the number of bits in your ADC which converted your data. Thus it is possible to apply all sorts of DSP algorithms, including speech recognition, directly on the rawdata array.

Come back if I have misunderstood you,

Regards

Dave Robinson