- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic to the Top
- Bookmark
- Subscribe
- Printer Friendly Page
pre-emphas is filter
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-03-2012 04:46 AM
Hi every one. I wrote a code for pre-emphasis filter (FIR with two coefficients). Regarding to theory frequencies below 400Hz must be with out changing. But my filter is will change the amplitude of input signal when it is below 400Hz. I attached my code for your information. I really appreciate if someone can help me.
Regards
Arash
Re: pre-emphas is filter
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-03-2012 11:32 PM
Have you plotted the frequency response of your filter, say in matlab, to see what you're supposed to be seeing and how it relates to your hardware?
Re: pre-emphas is filter
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-03-2012 11:52 PM
Hi, Arash.
How is your project going?
What makes you think this filter is what you need? How do you calculate the coefficients of this filter?
Vitaly.
Re: pre-emphas is filter
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-04-2012 01:06 AM
Hi Vitaly.
My project is well and I only need to fix this filter, Then every thing goes fine and I can finish it. Base on the following attachment which is 50/75us pre-emphasis filter I tried to implement it. First of all, I read a lot through internet and many references and most of them are agree that pre-emphasis filter is first order FIR filter with coefficient of [ 1 , 0.975] or near to this. Then I create first order FIR filter in Matlab and generate VHDL code from FDATOOL. Then I replaced above coefficients with what matlab made for it`s filter. After I programmed my FPGA it shows the frequencies more than 400Hz are same in amplitude. So, I tried try and error technique to find out these coefficient. Do you think my way is wrong? Please guide me to have a very good pre-emphasis filter regarding to the attached file.
Regards
Arash
Re: pre-emphas is filter
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-04-2012 04:17 AM
arash-rezaee wrote:
First of all, I read a lot through internet and many references and most of them are agree that pre-emphasis filter is first order FIR filter with coefficient of [ 1 , 0.975] or near to this.
Perhaps, it can be roughly approximated by such FIR filter with two coefficients [1, -0.9]. But at what sampling frequency?
Originally (in analog implementation) pre-emphasis filter is simple RC first-order high-pass filter with timing constant RC = 50 us (or corner frequency = 1/(2*pi*RC)).
There are many ways to design digital filter with frequency response close to the analog prototype. But the coefficients of digital filter depend on the corner frequency (or timing constant) and the sampling frequency together.
So, first of all, try to model this filter in Matlab, look at the frequency response in FDATool and tweak the coefficients to achieve desired approximation.
Vitaly.
Re: pre-emphas is filter
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-04-2012 04:37 AM
Vitaly wrote:
There are many ways to design digital filter with frequency response close to the analog prototype. But the coefficients of digital filter depend on the corner frequency (or timing constant) and the sampling frequency together.
--------------------------------------------------
can you explain a little more? how to compute coefficient whit help of corner frequency ( or timing constant)?
my sampling frequency is 95KHz. I just know with FDAtool we can set the cutoff frequency and passpand frequency. is it the way to change the coefficient of the filter designed in matlab?
Sorry I didn`t mentioned about sampling frequency
sampling frequency = 95KHz
Clock = 12.160MHz
Regards
Arash
Re: pre-emphas is filter
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-04-2012 10:27 PM
Arash, if you have analog prototype of filter, it can be translated into digital filter (IIR) by using one of the following methods:
1) bilinear transformation from s-plane to z-plane (http://en.wikipedia.org/wiki/Bilinear_transform),
2) sampling of impulse response (http://en.wikipedia.org/wiki/Impulse_invariance).
Also you can try to design FIR filter with frequency response close to the frequency response of original analog filter.
As to pre-emphasis filter, there is a paper which should help you:
http://wwwjontio.zapto.org/hda1/preempiir.pdf
Just don't forget to use your sampling rate in calculations of the coefficients.
Vitaly.
Re: pre-emphas is filter
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
03-15-2012 02:18 AM
I have done this filter as an IIR with good results, contact me if you need feedback.
Regards
Re: pre-emphas is filter
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
04-15-2012 06:49 AM
Hi
thanks a lot. I don`t know how to contact you. please let me know how can I contqact you. I don`t know I can put my email address here or not. But this is my email address ara2631@yahoo.com .
Regards
Arash
Re: pre-emphas is filter
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
06-19-2012 06:44 AM
Dear Vitaly
I have read the paper you mentioned " http://wwwjontio.zapto.org/hda1/preempiir.pdf ".
Now I have three coefficients for nominator(2) and decimated(1).
I have two question. Once my coefficients are 5.30986,-4.79461,0.48475.
1. How can I quantize them for FPGA.
2. What is the best way to implement IIR filter in FPGA? Is it good to design one first order IIR filter in Matlab and then change it`s coefficients with mine? Or other way?
Please help me.
Regards
Arash











