Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
15 years ago

FFT Megafunction Fixed Point

I'm trying to use Altera's FFT Megafunction in Fixed Point mode but I didn't find any documentation defining how many bits it uses for decimal part. I'm using the Variable Streaming because its the only onde that gives me the ability to use 32 bits entrance.

I need to use it with 32 bits in which 26 are integer and 6 bits of decimal part.

Can anyone help me.

Thanks

2 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    I think you need to scale the input up in such a way that you have 32 bits integer and the scale it down in the output. In other words you need to do a bit casting.

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    the FFT core only has a sense of decimals when using floating point mode. fixed notation is largely an abstraction

    since the FFT is a linear operator, you should be able to imagine multiplying your 26:6 input word by 1,000,000 to force it to 32:0, a full integer. then you can divide the FFT output by 1,000,000 to rescale

    the FFT output is somewhat relative due to processing gain and any windowing. if you convert to decibels you could just subtract 20*log10(1,000,000)=60dB from each value