Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

MatLab coefficients for a fixed point DSP

Status
Not open for further replies.

kirgizz

Member level 2
Joined
Sep 7, 2004
Messages
52
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
644
digital filters dsp fixed point

Hi, a question from a newbee in DSP here.

I have a digital filter project, in which I'm designing a low-pass filter for a fixed point DSP.
I introduced the filter data into MatLab and got the coefficients.
My problem is the data representation format.
I think the numbers must be converted in fixed point format due to implementing in DSP.
In MatLab I marked "quanitized" then a menu with methods and options such as "floor", "rounding",
"input", "output" and so on was enabled. I let it unchanged and started calculation.
The amplitude response became worse.

I don't know how to set these factors to achieve a better filter.
Can anybody help me ?
 

matlab fixed point filter export

Well my friend it looks like you want to cook high end cuisine with just beans and eggs .!! .. Listen i suggest you to read the matlab help files regarding quantizing .. Is probably one of the most important areas that need to be well understood when porting DSP algorithms to a FIZED point Processor . To explain all the different concepts floor and other will be a little too long . Matlab help files dealing with quantizing are very good .
Is worthy to devote just half an hour of reading and get a good grasp.

Cheers
 

fdatool fixpoint export

Hello kirgizz,

Yes the quantization theory and finite word length effects are very serios theory.

I would advice you to read the following book. There is chapter about your problem in it.
Theory and Application of Digital Signal Processing
Lawrence R. Rabiner, Bernard Gold

regards
elvis
 

Thanks, I understood.

My problem is a lack of time for implementing the design, that's why I asked for the advice. The explanation in MatLab help I will read of course.
I don't have the proposed book (but I'll try to find it).

regards
 

If there are any document to explain the quantization equation of all format including of the overflowmode/rounding mode??thanks.
 

Hi

the best way to design FIR taps for a fixed-point DSP is using fdatool.
Write fdatool in MATLAB prompt and design your filter according to your specifications. then in the left bottom of the fdatool window click on set quantization parameters and quantize designed coeffs to your quantization parameters such as Q15, then export them to a header file or to MATLAB worksapace for further analysis.

Regards
 

Hi kirgizz,

Matlab with FDA toolbox are very useful to design digital
filters and simulate their responses, but as always is, the
real world is different from the simulated one. In
particular in the real world you have CPUs (DSP or GPU) with
finite length registers. Matlab helps you by giving the
possibility to specify quantization parameters that helps to
fit simulation results to the real world (the HW you use).
For istance if you use a DSP with 16-bit registers, with a
40-bit MAC (Multiply and Accumulate) you should set the
quantization parameters to reflect these registers length
and your HW behaviour (if rounding is handled with wrapping
or floor and how the CPU manage the occurence of overflow in
the response calculation etc.).
In the end you should always consider on which hardware you
have to implement the filter and then try to set FDA quantizations
parameters according to it.
Good work
Bye

Mowgli
 

Mowgli

thank you for your comprehencive answer. I'll try to test the
options offered by MATLAB. I'm thinking about to change to floating point DSP
at the moment.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top