LV 2020 J. Phys. Conf. Ser. 1544 012111
LV 2020 J. Phys. Conf. Ser. 1544 012111
Conference Series
Abstract. This audio signal analyzer is based on a microcontroller (MCU) and a field
programmable gate array (FPGA). It consists of a controllable gain amplifier circuit, an active
filter circuit, A / D conversion and D / A feedback circuits, and a main control circuit and
liquid crystal display module. Through AD conversion, the audio signal is sampled, the
continuous signal is discretized, and then the FFT fast Fourier transform operation is performed
to analyze and process each frequency component and power of the audio signal in the time
and frequency domain. By controlling the gain of the amplifier to expand the dynamic range of
the input signal and improve the sensitivity, it can also complete the corresponding human-
computer interaction control based on the PS2 keyboard input, while using the high-resolution
LCD to display the signal spectrum. The audio signal frequency range that this system can
accurately measure is 20Hz-10KHz, its amplitude range is 5mVpp-5Vpp, and the resolution is
divided into 20Hz and 100Hz. The measured power accuracy is as high as 1%, and the period
of the periodic signal can be accurately measured, which is the ideal solution for audio signal
analyzers.
1. Introduction
The audio signal analyzer in this system is mainly used to analyze the frequency component of the
audio signal and can be used to measure the distortion of the sinusoidal signal. The system design
requirements are as follows:
(1) Input impedance: 50Ω
(2) Input signal voltage range (peak-to-peak): 100mV ~ 5V
(3) Frequency component range of input signal: 20Hz ~ 10kHz
(4) Frequency resolution: 20Hz and 100Hz
(5) The sum of the power of each frequency component is not less than 95% of the total power
value; the absolute value of the relative error of the power measurement of each frequency component
is less than 10%; the absolute value of the relative error of the total power measurement is less than
5%.
2. System solution
The design consists of a control calculation module, a display input module, and a pre-stage signal
acquisition module. The system block diagram is shown in Figure 1.
Content from this work may be used under the terms of the Creative Commons Attribution 3.0 licence. Any further distribution
of this work must maintain attribution to the author(s) and the title of the work, journal citation and DOI.
Published under licence by IOP Publishing Ltd 1
ICSP 2020 IOP Publishing
Journal of Physics: Conference Series 1544 (2020) 012111 doi:10.1088/1742-6596/1544/1/012111
2
ICSP 2020 IOP Publishing
Journal of Physics: Conference Series 1544 (2020) 012111 doi:10.1088/1742-6596/1544/1/012111
In the process of dynamic measurement, first let the gain of the input signal = 1 pass through the
amplifier, sfter the AD sampling is performed, the sampling voltage D′ Sample
is obtained, as shown in
equation (1):
D′Sample
•
V in • G′ = 256 V Fs1 (1)
In the above formula, V Fs1
is the ADC full-scale voltage.
The FPGA compares the sampling voltage D′Sample with the reference voltage V ref (which is the
upper limit voltage close to the ADC range). If it is less than the reference voltage, it starts the counter
to start counting, and at the same time, converts the count value C ount into the DAC output voltage,
which is then converted into a gain G ′ that changes with the count value, as shown in equation (2):
G′ = C ount • V Fs 2
1024 (2)
Where V Fs 2 is the DAC full-scale output voltage.
By continuously comparing the sampling voltage with the reference voltage until the sampling
voltage is close to the reference voltage, then dividing the final sampling voltage D Sample
by the final
gain G to obtain the final actual conversion voltage D , as shown in equation (3).
out
=
DSample
D out
G (3)
N
P (k ) =
R (4)
k
f = fs (f )
Then according to N , the actual power P at each frequency is obtained, and the total
power P B at each frequency is obtained by adding the power at each frequency.
Pˆ (ω ) = rˆ(m)e
− jωm
(6)
A
m=− M
3
ICSP 2020 IOP Publishing
Journal of Physics: Conference Series 1544 (2020) 012111 doi:10.1088/1742-6596/1544/1/012111
4. Circuit design
4
ICSP 2020 IOP Publishing
Journal of Physics: Conference Series 1544 (2020) 012111 doi:10.1088/1742-6596/1544/1/012111
5. System test
Test equipment: function generator, spectrum analyzer, oscilloscope, distortion tester, multimeter
5
ICSP 2020 IOP Publishing
Journal of Physics: Conference Series 1544 (2020) 012111 doi:10.1088/1742-6596/1544/1/012111
analyzed in matlab on the order of 0.001. The results of the spectrum analyzer and the audio analyzer
are the same. There are values at the input frequency points, all others are 0.
(2) 25Hz and 110Hz sine signal analysis results in audio analyzer
Table 2. Frequency test
Applied signal Audio analyzer test Spectrum analyzer Matlab calculation
frequency results measurement results results
25 Hz 20Hz 25Hz 20Hz
110 Hz 120Hz 110 Hz 120 Hz
6. Conclusion
This audio signal analyzer uses ARM7 and FPGA as the core components. Through the FFT fast
Fourier transform operation, it analyzes and processes each frequency component and power of the
audio signal in the time and frequency domain, completed the system design requirements and passed
the test.
References
[1] Zheng, YM, Dong XZ. (2006) Programming Logic Device Development Software
QuartusII. National Defense Industry Press, Beijing.
[2] Sun ZJ, Liu XM, Ji ZX. (2009) The Design of Radix-4 FFT by FPGA. Intelligent
Information Technology Application Workshops, Beijing.
[3] Chen R, Chen H. (2006) VHDL Chip Design. Machinery Industry Press, Beijing.
[4] Zhang JT, Feng CC, Yan ZG. (2009) Design of Audio Signal Analyzer Based on DSP. Journal
of Xi'an Shiyou University, 76–83.
[5] Xiong GH, Luo SS, Wang GY. (2006) Design of Virtual Audio Signal Analyzer Based on
Sound Card. Foreign Electronic Measurement Technology, 33–40.