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
LPC_Analyzer.hpp
00001 //--------------------------------------------------------------- 00002 // Class for spectrum analysis using linear prediction (Header) 00003 // 00004 // 2017/02/11, Copyright (c) 2017 MIKAMI, Naoki 00005 //--------------------------------------------------------------- 00006 00007 #ifndef LPC_ANALYZER_HPP 00008 #define LPC_ANALYZER_HPP 00009 00010 #include "AnalyzerBase.hpp" 00011 #include "LinearPrediction.hpp" 00012 00013 namespace Mikami 00014 { 00015 class LpcAnalyzer : public AnalyzerBase 00016 { 00017 public: 00018 LpcAnalyzer(int nData, int nFft, int order); 00019 virtual ~LpcAnalyzer() {} 00020 00021 private: 00022 int order_; 00023 LinearPred lp_; 00024 00025 Array<float> an_; // predictor coefficient 00026 Array<float> xFft_; // input for FFT 00027 Array<Complex> yFft_; // output of FFT 00028 00029 virtual void Analyze(const float xn[], float yn[]); 00030 00031 // disallow copy constructor and assignment operator 00032 LpcAnalyzer(const LpcAnalyzer& ); 00033 LpcAnalyzer& operator=(const LpcAnalyzer& ); 00034 }; 00035 } 00036 #endif // LPC_ANALYZER_HPP
Generated on Mon Jul 25 2022 07:38:49 by 1.7.2