Decode the keys in DTMF using FFT

16 ビュー (過去 30 日間)
Pavel Musorsky
Pavel Musorsky 2020 年 3 月 22 日
回答済み: Leonardo Aquino 2021 年 6 月 14 日
UPDATE:
The problem was solved! See the first comment.
I need to detect the keys pressed in the wav file using the FFT. But I'm completely stuck with it, just don't know what to do. I have read that you can detect the tones with the help of Goertzel algorythm, but, again, I haven't found nor explanation for it nor any example of working code. With audioread I got the wave and created the plot of it, but what should I do next to identify the frequencies for each key and filnally the keys?
Can someone please share with me an algorithm how to solve this problem?
  9 件のコメント
Pavel Musorsky
Pavel Musorsky 2020 年 9 月 1 日
Did you use the wav file? And does it lie in the same folder as your project?
Abdul Rahim Mohammad
Abdul Rahim Mohammad 2020 年 9 月 16 日
編集済み: Abdul Rahim Mohammad 2020 年 9 月 16 日
Hi Pavel,
I used the code with a wav file generated from your suggested link but the following error pops up:
Output argument "c" (and maybe others) not assigned during call to "FFT>detect".
Error in FFT (line 27)
KEYS = [KEYS,detect(val)];
Could you also specify how to use the mat file as well, as in how to use the generated wave file and your file?
I reckon this might be a incomplete code snippted since the function you made takes no input arguments, I am sorta new to MATLAB and this seems extemely out of place compared to python. Thanks!

サインインしてコメントする。

回答 (1 件)

Leonardo Aquino
Leonardo Aquino 2021 年 6 月 14 日
hi @Pavel Musorsky, i have a problem with the ejecution your code, i have this error:
Error using reshape
Size arguments must be real integers.
Error in fft (line 11)
dataS = reshape(data(1:height*width),width,height)

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by