
Realtime sound spectrogram using FFT or linear prediction. Spectrogram is displayed on the display of PC. リアルタイム・スペクトログラム.解析の手法:FFT,線形予測法.スペクトログラムは PC のディスプレー装置に表示される.PC 側のプログラム:F446_Spectrogram.
Dependencies: Array_Matrix mbed SerialTxRxIntr F446_AD_DA UIT_FFT_Real
Revision 1:cc596a8d40c9, committed 2017-02-21
- Comitter:
- MikamiUitOpen
- Date:
- Tue Feb 21 13:25:58 2017 +0000
- Parent:
- 0:a539141b9dec
- Child:
- 2:acc16e3f91ac
- Commit message:
- 2
Changed in this revision
F446_AD_DA.lib | Show annotated file Show diff for this revision Revisions of this file |
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/F446_AD_DA.lib Fri Feb 17 04:55:10 2017 +0000 +++ b/F446_AD_DA.lib Tue Feb 21 13:25:58 2017 +0000 @@ -1,1 +1,1 @@ -http://mbed.org/users/MikamiUitOpen/code/F446_AD_DA/#d1da91aec62f +http://mbed.org/users/MikamiUitOpen/code/F446_AD_DA/#bbc26cf86b70
--- a/main.cpp Fri Feb 17 04:55:10 2017 +0000 +++ b/main.cpp Tue Feb 21 13:25:58 2017 +0000 @@ -10,7 +10,7 @@ // ● ボーレート: 460800 baud // ● 受信データの文字列の終了マーク: "\r" // -// 2017/02/17, 三上 直樹 +// 2017/02/21, 三上 直樹 //--------------------------------------------------------------------- #include "mbed.h" @@ -60,7 +60,7 @@ Array<int16_t> txData_(DATA_SIZE_); // 送信用データ string rxBuffer_; // 受信バッファ float levelShift_ = 20; // dB 計算の際のシフト量の初期値 -float empha_ = 0.8f; // 高域強調器の係数 +float empha_ = 1.0f; // 高域強調器の係数 __IO bool eol_; // "\r" を受信した場合に true @@ -117,7 +117,7 @@ __IO bool okGo = false; // "GO" を受信したら true while (true) { - // PC からのコマンド解析 + // PC からのコマンドの解析 if (eol_) { if (rxBuffer_.find("ENQ") != string::npos) @@ -142,7 +142,7 @@ levelShift_ = (float)(rxBuffer_[3] - ' '); // dB 計算の際のシフト量 - if (rxBuffer_[4] == 'Y') empha_ = 0.8f; // 高域強調器は有 + if (rxBuffer_[4] == 'Y') empha_ = 1.0f; // 高域強調器は有 else empha_ = 0; // 高域強調器は無 if (rxBuffer_[5] == 'F') analyzer_ = fftAnlz_; // FFT