Realtime spectrogram for DISCO-F746NG. On-board MEMS microphone is used for input sound signal. リアルタイムスペクトログラム.入力:MEMSマイク
Dependencies: F746_GUI F746_SAI_IO UIT_FFT_Real
MyClasses_Functions/AnalysisBase.cpp
- Committer:
- MikamiUitOpen
- Date:
- 2016-07-23
- Revision:
- 2:1f092ac020e1
- Parent:
- 0:9470a174c910
File content as of revision 2:1f092ac020e1:
//------------------------------------------------------- // Base abstract class for spectrum analysis // // 2016/07/23, Copyright (c) 2016 MIKAMI, Naoki //------------------------------------------------------- #include "AnalysisBase.hpp" namespace Mikami { AnalyzerBase::AnalyzerBase(int nData, int nFft, int nUse) : N_DATA_(nData), N_FFT_(nFft), fft_(nFft), wHm_(nData-1, nUse), xData_(nUse), wData_(nUse) {} void AnalyzerBase::Execute(const float xn[], float db[]) { // Differencing for (int n=0; n<N_DATA_-1; n++) xData_[n] = xn[n+1] - 0.8f*xn[n]; // Windowing wHm_.Execute(xData_, wData_); Analyze(wData_, db); } }