1 / 26

The Parks-McClellan Algorithm

The Parks-McClellan Algorithm. ECE 345 Final Presentation Group 14 Justin Haldar Arun Ramani April 30 th , 2004. The Parks-McClellan algorithm.

dasan
Télécharger la présentation

The Parks-McClellan Algorithm

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. The Parks-McClellan Algorithm ECE 345 Final Presentation Group 14 Justin Haldar Arun Ramani April 30th, 2004 Justin Haldar and Arun Ramani

  2. The Parks-McClellan algorithm • The Parks-McClellan algorithm is used to design linear-phase Finite Impulse Response (FIR) digital filters that are optimal with respect to the Chebyshev Norm (minimize the maximum error). Justin Haldar and Arun Ramani

  3. Motivation • Low-pass filters are useful for many different applications in Electrical Engineering • It is useful to be able to quickly create a customized low-pass filter that can be used in a laboratory setting Justin Haldar and Arun Ramani

  4. The Project • This project allows a user to design an optimal finite impulse response (FIR) lowpass filter without having to have detailed signal processing knowledge. The user will be asked to input the passband and stopband frequencies, the desired filter length, and a desired weighting factor between the stopband and passband ripples. The Digital Signal Processor (DSP) board will then calculate the optimal filter satisfying these specifications, and will begin to filter its input based according to the optimal design. Justin Haldar and Arun Ramani

  5. The Project (continued) • In addition, we designed an analog low-pass filter to be used as a pre-filter on the ADC on the DSP. Justin Haldar and Arun Ramani

  6. User Inputs • Designed for band edges between 0 and 4 KHz • Designed for odd-length filters of order 5 to 127 • User should specify the desired Passband/Stopband ripple ratio Justin Haldar and Arun Ramani

  7. Filter Characteristics Justin Haldar and Arun Ramani

  8. DSP Specifications • Ripple ratio of designed digital filter within 5% of desired ripple ratio • Designed digital filter coefficients to be within 50% of the same digital filter designed with a MATLAB library function Justin Haldar and Arun Ramani

  9. Software Block Diagram Justin Haldar and Arun Ramani

  10. Analog Low-pass Filter Justin Haldar and Arun Ramani

  11. Analog Low-pass Filter Specifications • Passband of 4KHz • Maximum of 1 dB ripple • Stopband of 7KHz • Maximum of –20dB • 4th-order Chebyshev Design Justin Haldar and Arun Ramani

  12. Accomplishments • Designed MATLAB implementation of the Parks-McClellan Algorithm • Designed DSP implementation of the Parks-McClellan Algorithm • Designed Analog Low-pass filter • Integrated DSP and Analog filter together Justin Haldar and Arun Ramani

  13. Project Build • First designed MATLAB implementation • Iterated through various combinations of passband, stopband, ripple ratio, and filter length for more than 15,000 total tests • Our MATLAB code matched MATLAB’s library function except when MATLAB designed a filter incorrectly • We did not always converge in the same places MATLAB does because MATLAB uses a modified version of the algorithm • We also began to notice numerical effects in the interpolation process Justin Haldar and Arun Ramani

  14. Project Build (II) • Ported our MATLAB code to the DSP • DSP has 16 bit precision, while MATLAB has 32 bit precision, causing more extreme numerical effects • DSP also has helpful error messages when numerical effects cause the algorithm to fail to converge • Filter length suggestions • Transition band length suggestions Justin Haldar and Arun Ramani

  15. DSP Testing • 140 different tests on the coefficients generated by the DSP • 120 standard cases (moderate transition band lengths and moderate ripple ratios) • 20 extreme cases (very high or very low ripple ratios or very narrow transition bands) Justin Haldar and Arun Ramani

  16. DSP Testing (II) • In the standard cases where the algorithm converged correctly, there was a maximum of 3.79% ripple error and a maximum of 0.0027% error in the coefficients versus the MATLAB coefficients Justin Haldar and Arun Ramani

  17. DSP Testing (III) • In the 20 extreme cases, 17 passed correctly. Of these, the maximum ripple ratio error was 2.32% and the maximum coefficient error was 0.6436% Justin Haldar and Arun Ramani

  18. DSP Testing (IV) • The 3 cases that didn’t pass • 0Hz passband and 1Hz stopband was designed as an all-stop filter because of numerical precision effects in interpolation • The other 2 failures occurred in the extreme ripple ratio cases (106 and 10-6 passband/stopband ripple). This is because the problem is hard to represent numerically when one of the ripples is so small Justin Haldar and Arun Ramani

  19. Analog Filter Testing • Before building the circuit, we simulated designs in ADS. The design we ended up with had an 85% yield given component variation Justin Haldar and Arun Ramani

  20. Analog Filter Testing Justin Haldar and Arun Ramani

  21. Analog Filter Testing • Conducted 15 tests of built filter • Did a frequency sweep as the input of the filter using several different input amplitudes Justin Haldar and Arun Ramani

  22. Analog Filter Testing (II) Justin Haldar and Arun Ramani

  23. Overall System Testing • 16 Tests on output of overall system • Most of the cases we tried gave good results in terms of what the output signal looked like (it filtered what it was supposed to filter) • Ripple ratio error ranged from 59.64% to 3.95% • Issues arise from oscilloscope noise, DSP hardware filter, effects of ripple in Analog Filter • Noise effects skew ripple ratio greatly because the ripple is never larger than 1, and can be much smaller (i.e. 10-7), and the noise was on the order of 0.06 Volts. Thus, small perturbations in each ripple can cause large perturbations in the error Justin Haldar and Arun Ramani

  24. Performance Results • Overall system works as we intended it to • DSP has a built-in hardware filter that only passes frequencies of 500 Hz to 3.25 KHz with equiripple characteristics, while the DSP can design filters with frequencies between 0 Hz and 4 KHz • The DAC on the DSP inserts a 900 mV DC offset to the output signal Justin Haldar and Arun Ramani

  25. Recommendations • Use a different DSP • Higher numerical precision • No hardware filter • No DC offset in output • Use less-noisy wires and oscilloscopes when extreme precision is required Justin Haldar and Arun Ramani

  26. The End is Near • Questions and Comments Justin Haldar and Arun Ramani

More Related