Implementation of FIR digital filter based on TMS32OVC5509 DSP

Publisher:HarmonyJoyLatest update time:2011-07-13 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

Abstract: FIR digital filters are widely used in the field of real-time digital signal processing. This paper introduces the structure, characteristics and design method of FIR digital filters, and designs FIR filters using the window function method. The filter is implemented using the powerful digital signal processing function of the TMS320VC5509 DSP chip. Experiments show that this digital filter works stably and can meet the real-time filtering processing function. Keywords: Finite Impulse Response Filter; Digital Filter: TMS320VC5509 0 Introduction In digital signal processing systems, digital filters play a very important role. Finite Impulse Response (FIR) digital filters are widely used in image signal processing, data transmission and other fields because of their system stability, fast operation speed and easy implementation. FIR filters can be implemented by computer software, or by dedicated digital filtering circuits, dedicated digital signal processors or general-purpose programmable DSP processors. Among them, the method implemented by computer software is slow and is often used for algorithm simulation and emulation; the method implemented by dedicated hardware or dedicated processors is fast, but has poor versatility and high cost; while the general-purpose programmable DSP processor can implement various digital filtering algorithms through programming, which is flexible and powerful, and is widely used in filter design. This paper mainly introduces the design and implementation of FIR digital filter based on TMS320VC5509 programmable DSP. 1 Characteristics and basic structure of FIR filter 1.1 Characteristics of FIR filter (1) The unit impulse response h(n) of the system is not zero at a finite number of n values; (2) The system function H(z) converges at |z|>0, has only zero points at |z|>0, has only zero points on the finite z plane, and all poles are at z=0 (causal system); (3) The structure is mainly non-recursive, with no feedback from output to input, but some structures (such as frequency sampling structure) also contain recursive structures with feedback. 1.2 Basic structure of FIR filter The basic structure of FIR filter is a segmented delay line, and the output of each segment is weighted and accumulated to obtain the output of the filter. Mathematically expressed as: The general structure of FIR filter can be drawn from formula (2), as shown in Figure 1:












a.JPG

c.JPG



2 Window Function Design Method of FIR Filter
Commonly used FIR filter design methods include window function design method and frequency sampling design method. The basic idea of ​​the window function method is to design a finite length filter frequency response to approximate the frequency response of the ideal filter. Let the frequency response of the ideal filter be Hd(ejw), and its unit sampling response be represented by hd(n). Hd(ejw) is usually selected as an ideal filter with piecewise constant characteristics, so hd(n) is infinitely long and non-causal, and cannot be directly used as the unit sampling response of the FIR digital filter. The window function design method is to intercept a section of hd(n) as a finite length causal sequence, and select a suitable window function for weighting as the unit sampling response of the FIR digital filter. The general steps of designing a linear phase FIR filter using the window function method are:
(1) First, the required frequency response function Hd(ejw) is given;
(2) The unit sampling response of the ideal filter
d.JPG
is calculated; (3) According to the requirements of the transition band bandwidth and the minimum attenuation of the stop band, the window function w(n) is selected and the window length N is estimated;
(4) The unit sampling response of the designed FIR filter is obtained;
d.JPG
(5) The system function of the FIR filter is calculated.
f.JPG
Usually, the entire design process can be implemented using computer programming, and several window functions can be selected for trial, so as to design a filter with good performance.

3 DSP Implementation of FIR Filter
3.1 Introduction to TMS320VC5509 TMS320VC5509 is a new generation digital signal processor launched by Texas Instruments (TI) in the United States. Its CPU structure includes a 32×16-bit instruction cache queue, two 17-bit×17-bit multiply-accumulate 16-bit arithmetic logic units (MACs), a 40-bit arithmetic logic unit (ALU), a 16-bit arithmetic logic unit (ALU), a 40-bit barrel shifter and four 40-bit adders. TMS320 VC5509 supports a variety of industrial standard serial ports, such as: multi-channel buffered serial ports (McBSPs), multimedia card/secure data serial ports (MMC/SD), USB and I2C bus interfaces. It also has on-chip peripherals such as enhanced host interface (EHPI), general I/O ports, programmable digital phase-locked loops (DPLLs), timers and multiple DMA controllers. The highly parallel structure of TMS320VC5509 and the optimized instruction set together reduce the number of clock cycles required for each operation, while the code density increases, thus providing a digital signal processing engine with small code length, low energy consumption and high performance. 3.2 Design and implementation of FIR low-pass filter The FIR low-pass filter is designed using the window function method. The design parameters are the passband edge frequency of 10kHz, the stopband edge frequency of 20kHz, the stopband attenuation of 75dB, and the sampling frequency of 50kHz. The process of designing the FIR low-pass filter with known parameters is as follows: The DSP implementation program of the FIR filter is written in C language, and the time-frequency characteristics of the filter are shown in Figure 2. The input signal superimposed with high-frequency noise is filtered using the designed FIR filter, and the waveforms and spectra before and after filtering are shown in Figure 3. By comparing the time domain waveforms, it is found that the input signal superimposed with high-frequency noise becomes smoother after passing through the FIR low-pass filter; by comparing the frequency domain waveforms, it can also be found that the useful low-frequency signal is retained, while the high-frequency noise is well filtered out.




g.JPG

j.JPG



4 Conclusion
FIR filter can ensure strict linear phase while ensuring amplitude characteristics, and is widely used in digital signal processing systems. DSP chips have powerful digital signal processing functions and rich instruction set systems. Using DSP to implement digital filtering can not only meet the requirements of system accuracy and stability, but also have the characteristics of real-time and flexibility. It has broad application prospects in the fields of voice, image processing and data transmission.

Reference address:Implementation of FIR digital filter based on TMS32OVC5509 DSP

Previous article:Design and simulation of FIR filter based on FPGA
Next article:Comprehensive solution for passive interface filtering and linear active filter design

Latest Industrial Control Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号