【正文】
宜,所以我們選擇由 MCU 直接采樣。而對于單頻信號或者由多個具有最小公倍數的頻率組合的多頻信號具有周期性。 又根據采樣定理,采樣頻率 fk 必須不小于信號頻率 fm 的 2倍,即: fk=2fm。icount[n]。 dataI[i]=0。k=k+2*b) { TR=dataR[k]。 LCD_PenColor=0x1F。 p3510(Re[i+3],0,50)。 page++。 ////////////////頻域功率 //////////////////////////////////// for(i=1。} else {LCD_WriteEnglishString( ,0,38)。 if(==0) return 4。 } } } //////////////////////顯示 /////////////////// void p3510(int v,int x,int y) { int x0。,x+6,y)。 a[i+1]=temp。 if(==0) return 2。 if(Tflag) {LCD_WriteChineseString(font7,1,50,20)。 enable_timer(0)。 p3510(Re[i+2],0,38)。 p3510(Re[i+1],0,26)。 w[i]=w[i]/count[n1]。 i。} dataI[xx]=dataR[i]。 int x[11]={0}。 功率譜測量 功率譜測量主要通過對音頻信號進行離散化處理,通過 FFT 運算,求出信號各個離散頻率點的功率值,然后得到離散化的功率譜。測量周期可以在時域測量也可以在頻域測量,但是由于頻域測量周期性要求某些頻率點具有由規(guī)律的零點或接近零點出現,所以對于較為復雜的,頻率分量較多且功率分布較均勻且低信號就無法正確的分析其周期性。 關鍵詞: FFT MCU 頻譜 功率 Abstract: The audio signal analyzer is based on a 32bit MCU controller, through the AD converter for audio signal sampling, the continuous signal discrete, and then through the FFT fast Fourier transform puting, in the time domain and frequency domain of the various audio frequency signal weight and power, and other indicators for analysis and processing, and then through the highresolution LCD display signals in the spectrum. The system can accurately measure the audio signal frequency range of 20 Hz10KHz, the range of 55Vpp mVpp, resolution of 20 Hz and 100 Hz correspondent. Power measurement accuracy up to 1%, and be able to accurately measuring the periodic signal cycle is the ideal audio signal analyzer solution. Keyword: FFT MCU Spectrum Power 1 方案論證與比較 .......................................................................................................................................3 采樣方法 方案論證 ...........................................................................................................................3 處理器的選擇 方案論證 ................................................................................ 錯誤 !未定義書簽。 周期性判別與測量方 法 方案論證 ................................................................ 錯誤 !未定義書簽。 而在時域分析信號,我們可以先對信號進行處理,然后假定具有周期性,然后測出頻率,把采樣的信號進行周期均值法和定點分析法的分析后即可以判別出其周期性。 由于題目要求頻率分辨力為 100Hz和 20Hz兩個檔,這說明在進行 FFT運算前必須通過調整采樣頻率 (fK)和采樣的點數 (N),使其基波頻率 f為 100Hz和 20Hz。 float TR,TI,temp。 } for(i=0。} p=p*j。 } w[0]=w[0]/2。 print3510(Im[i+1]*mode,50,25)。 print3510(Im[i+2]*mode,50,35)。 ////////////////////等待采樣完成 /////////////////////////// while(!FFT_Flag)。LCD_WriteEnglishString( ,0,38)。 } if(==0) { delay_nms(2021000)。 temp=b[i]。 } 。 b[i+1]=temp。 } if(==0) { delay_nms(2021000)。LCD_WriteEng