Data returned by Audioread
17 ビュー (過去 30 日間)
古いコメントを表示
I have a question regarding the audioread function in Matlab. Audioread('file.wav') will return a normalized data of -1 to 1 that represents the amplitude of the sound. My question is, Are sensors (ex. Mica2) when acquire a sound signal and after doing the AD sampling will give me the same samples data that i'll get using Audioread?
0 件のコメント
回答 (1 件)
Star Strider
2017 年 5 月 25 日
The audioread function will read a previously-recorded audio file, so it will not itself record data from a sensor. You first have to record the data from your sensor and then play it through audioread.
See the documentation for audiorecorder (link) if you want to record sound directly from a sensor that your operating system and MATLAB support.
13 件のコメント
Walter Roberson
2017 年 5 月 29 日
The normalization is according to what the internal data type can hold, not according to the stored range of data.
Jan
2017 年 5 月 29 日
@Walter: Thanks. Ah, I think I get is slowly: When the signal is stored as int16, the values -32768 and 32767 are scaled to [-1, +1 - e] (with a tiny e such that 0 is still 0 inspite of the tiny asymmetry). And if the maximum value is 17, the output of audioread will be 17/32768.
This means that audioread scales the range, but not the actual signal. Then "normalized values between −1.0 and 1.0" is misleading, at least for me. I ask TMW if they could improve the help text.
参考
カテゴリ
Help Center および File Exchange で Audio I/O and Waveform Generation についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!