DSPRelated.com
Forums

code working on simulator but not on device?

Started by megha daga May 1, 2006
Hy i am a student an i"m working at a project with a
dsk5416. I am trying to design an iir filter using
fdatool from matlab but i can't use those filter
coeffincints because they have a diffrent structure.
the dsplib functios usualy use biquads sections.
i tried to use iir5 function from dsplib ...
can anybody help me? is there any way to export or to
convert parameters from matlab in order to use them
whith dsplib functions or is thhere any other program
that i can use to design the filter with a proper
parameter structure?

_________________________
Hi
I understand your problem is matlab gives u in float and u need in fixed for dsk. Well there is a function for float to Q15 convert. Q15 is nothing but representation of signed int. You can read abt it in one of the documnets spru518. The function is described in the same doc.
megha

john doe wrote: Hy i am a student an i"m working at a project with a
dsk5416. I am trying to design an iir filter using
fdatool from matlab but i can't use those filter
coeffincints because they have a diffrent structure.
the dsplib functios usualy use biquads sections.
i tried to use iir5 function from dsplib ...
can anybody help me? is there any way to export or to
convert parameters from matlab in order to use them
whith dsplib functions or is thhere any other program
that i can use to design the filter with a proper
parameter structure?

_________________________
Zadrig-

> Hy i am a student an i"m working at a project with a
> dsk5416. I am trying to design an iir filter using
> fdatool from matlab but i can't use those filter
> coeffincints because they have a diffrent structure.
> the dsplib functios usualy use biquads sections.
> i tried to use iir5 function from dsplib ...
> can anybody help me? is there any way to export or to
> convert parameters from matlab in order to use them
> whith dsplib functions or is thhere any other program
> that i can use to design the filter with a proper
> parameter structure?

Suggest to try this MATLAB function:

[bcas,acas,g] = tocas(b,a)

which converts direct-form to a series of biquad (2nd order) filter
sections. This is often known as "biquad cascade" form.

Then, as Megha pointed out, you will need to make the floating-point
coefficients into Q-n format for efficient implementation on C54x
processor.

-Jeff