In the process of information signal processing, such as signal filtering, detection, prediction, etc., filters are used. Digital filters are the most widely used method in digital signal processing. Commonly used digital filters have infinite length units. There are two types of impulse response (IIR) filters and finite length unit impulse response (FIR) filters [1]. For application designers, due to the high requirements for development speed and efficiency, it is impossible to fully understand the optimization technology related to digital filters in the short term, and it takes a lot of effort to make the designed filters superior in speed, resource utilization, and performance. tend to be better. To use a debugged IP core, you need to purchase it from Altera. This article adopts an FPGA design method based on DSP Builder, taking the implementation of a low-pass 16th-order FIR filter as an example. Through the generated filter top module file and A/D module file design, in the NC of Lianxing Technology -EDA-2000C experimental box verified that the digital filter circuit designed using this method works correctly and reliably and can meet the design requirements.
1 Parameter design of FIR filter
1.1 Design requirements
The digital filter is actually a linear non-time-varying discrete system implemented using a limited precision algorithm. Its design steps are to first determine its performance indicators according to needs, design a technical indicator required for system function H(z) approximation, and finally use Limited precision algorithm implementation. The design indicators of this system are: design a 16th-order low-pass FIR filter, the sampling frequency Fs of the analog signal is 48KHz, the required cut-off frequency of the signal Fc=10.8kHz, and the input sequence is 9 bits wide (the widest bit is sign bit).
1.2 Parameter selection of FIR filter When designing a frequency-selective digital filter, it is usually hoped to have an approximately constant frequency response amplitude and to minimize the phase distortion in the passband. A linear phase with an integer slope corresponds to a simple linear phase in the time domain. The delay can reduce the phase distortion to the minimum in the frequency domain [2]. Use FDAtool, a special toolbox for filter design provided by Matlab, to simulate and design the filter to meet the required amplitude-frequency characteristics of the FIR filter. ,As shown in Figure 1.
2 DSP Builder design of digital filter
2.1 Introduction to DSP Builder
DSP Builder is a digital signal processing (DSP) development tool launched by Altera. It integrates Mathworks' Matlab and Simulink DSP development software in the Quartus II FPGA design environment [3]. For DSP Builder, it includes DSP system modeling, system-level simulation, conversion of design model to VHDL hardware description language code, RTL (Register Transfer Level, logic synthesis) level functional simulation testing, compilation adaptation, placement and routing, and timing. From real-time simulation to programming and configuration of DSP target devices, the entire development process can almost be completed in the same environment as the top-level development tool Matlab/Simulink.
2.2 Establishment of FIR filter algorithm model
According to the principle of FIR filter, FPGA can be used to implement the FIR filter circuit. The first step of the DSP Builder design process is to enter the design in Matlab/Simulink, that is, create an MDL model file in the Simulink environment of Matlab and call Altera graphically The graphics modules in DSP Builder and other Simulink libraries form a system-level or algorithm-level design block diagram (or Simulink modeling).
2.3 System-level simulation based on DSP Builder
The input signal is superimposed using two sinusoidal signals with frequencies f1=8KHz and f2=16KHz respectively. The simulation waveform is shown in Figure 2. From the simulation results of the FIR filter circuit, it can be seen that the output signal after the input signal passes through the filter is basically It becomes a sinusoidal signal with a single frequency, and the model simulation is completed.
3 Implementation of digital filter based on FPGA
3.1 Use Modelsim for functional simulation
The simulation performed in DSP Builder is of a system verification nature. It simulates the MDL file and does not simulate the generated VHDL code. In fact, the generated VHDL description is at the RTL level and is targeted at specific hardware structures. There may be differences in software understanding between the two. The converted VHDL code implementation may not be completely consistent with the situation described by the MDL model. This requires functional simulation of the generated RTL-level VHDL code.
We use Modelsim to perform functional simulation on the generated VHDL code. Set the input and output signals to be in analog form, and the simulation waveform shown in Figure 3 will appear. You can see that this is basically consistent with the simulation results in Simulink. It can be used for hardware design in the Quartus II environment [4].
3.2 Implement FIR filter in FPGA device
The digital filter implemented in FPGA processes digital signals. In practical applications, the analog signal must first be sampled and quantized using an A/D converter. Most of the traditional methods are completed by CPU or microcontroller. The disadvantages are long control cycle and slow speed. Using a synchronous sequential state machine to control A/D sampling is an effective method that is both simple and reliable and can significantly increase the sampling period.
Design the state machine as required in the Quartus II environment through VHDL language and convert it into a .bsf file; open the Quartus II project files fir.qpf and fir.vhd created by DSP Builder and convert them into the corresponding .bsf file, so that the corresponding The designed module is shown in Figure 4. These two modules are called to create a new top-level schematic file. Through timing simulation in the software environment, the device pins are specified, compiled, and finally downloaded to the EP1K10TC100-3 device in the experimental box. .
4 Conclusion
Use the signal generator to generate the required two sinusoidal signals of different frequencies, and you can see the filtered results on the oscilloscope. When you need to design different filter circuits, you can only modify the filter model file. It can be seen that when using FPGA to develop digital filters, using DSP Builder as a design tool can quickly and reliably design practical filter systems.
Previous article:Intelligent robot design for home healthcare
Next article:Control multiple three-phase inverters with a single DSP
- Popular Resources
- Popular amplifiers
- Dual Radar: A Dual 4D Radar Multimodal Dataset for Autonomous Driving
- A review of learning-based camera and lidar simulation methods for autonomous driving systems
- Basics of Machine Learning: From Getting Started to Job Hunting (Hu Huanwu)
- Simulation and Modeling of Chemical Sensors Volume 5 Electro-Optical Sensors Part 1 Photocopy
- Huawei's Strategic Department Director Gai Gang: The cumulative installed base of open source Euler operating system exceeds 10 million sets
- Analysis of the application of several common contact parts in high-voltage connectors of new energy vehicles
- Wiring harness durability test and contact voltage drop test method
- Sn-doped CuO nanostructure-based ethanol gas sensor for real-time drunk driving detection in vehicles
- Design considerations for automotive battery wiring harness
- Do you know all the various motors commonly used in automotive electronics?
- What are the functions of the Internet of Vehicles? What are the uses and benefits of the Internet of Vehicles?
- Power Inverter - A critical safety system for electric vehicles
- Analysis of the information security mechanism of AUTOSAR, the automotive embedded software framework
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- New real-time microcontroller system from Texas Instruments enables smarter processing in automotive and industrial applications
- Are there any 6-channel analog switches that you would recommend?
- How is the current transformer used?
- Sensor Basics and Common Terms
- "Power supply obstacle" + voltage stress
- About LM2611
- STM32F767 fails to drive 7-inch screen
- EEWORLD University Hall----Analog Integrated Circuit Design Yang Qingyuan (National Chung Hsing University, Taiwan)
- Strange problem in high frequency control of PMOS field effect tube
- PCB tool ruler
- [National Technology N32G430] 01 Before the troops move, the food and grass must be prepared + Unboxing