DSP Builder for Intel® FPGAs (Advanced Blockset): Handbook

ID 683337
Date 6/20/2022
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

15.3.13. General Multitwiddle and General Twiddle (GeneralMultiTwiddle, GeneralMultVTwiddle, GeneralTwiddle, GeneralVTwiddle)

Use the GeneralTwiddle and GeneralMultTwiddle blocks to construct supersampled FFTs. The blocks have the same external interface but use different internal implementations.

The GeneralTwiddle block generates its twiddle factors using the TwiddleRom block; the GeneralMultTwiddle block uses the TwiddleMultRom block. The GeneralMultTwiddle uses approximately twice as many DSP blocks as the GeneralTwiddle block, but (for large FFTs) uses far fewer memory blocks.

Each data sample in the input stream has a unique address. The address consists of the timeslot in which it arrived tbits concatenated with the number of wires on which it arrived sbits. The sbits is forms the least significant part of the address; the tbits forms the most significant part.

Each data sample is multiplied by a twiddle factor. For an FFT, the twiddle factor is:

twiddle = exp(-2*pi*i*angle/K)

For an IFFT, the twiddle factor is:

twiddle = exp(2*pi*i*angle/K)

where K items exist in each block of data.

For each data sample, the twiddle angle is calculated as:

angle = X*Y

where X and Y depend on the position of that data sample in the input stream.

Obtain the value of X (or Y) by extracting user-specified bits from the address of the data sample, and concatenating them.

The GeneralVTwiddle block (and the memory-optimized GeneralMultVTwiddle offer variable size and include an additional size input. They both use a General Twiddle Counter rather than a Counter block.

Table 119.  Parameters for the GeneralTwiddle and GeneralMultTwiddle Block
Parameter Description
iFFT Generate twiddle factors for an FFT or an IFFT.
sbits The number of spatial address bits i.e. log2(N) where there are N wires.
xbits The vector of bit positions for X.
ybits The vector of bit positions for Y.
Input type The type of the input before the twiddle.
Twiddle type The type of the twiddle factor.
Output type The type of the output after the twiddle.
Use faithful rounding Use faithful rather than correct rounding. Only for floating-point twiddle types.
Table 120.  Parameters for the GeneralVTwiddle and GeneralMultVTwiddle Block
Parameter Description
iFFT Generate twiddle factors for an FFT or an IFFT.
Number of spatial bits The number of spatial address bits i.e. log2(N) where there are N wires.
maxsize Maximum FFT size is 2^maxsize.
Size of the parallel section

The number of radix-2 stages assigned to the parallel section in the surrounding HybridVFFT (the GeneralVTwiddle links between the serial and parallel sections of the HybridVFFT)

Input type The type of the input before the twiddle.
Twiddle type The type of the twiddle factor.
Output type The type of the output after the twiddle.
Use faithful rounding Use faithful rather than correct rounding. Only for floating-point twiddle types.
Table 121.  Port Interface for the GeneralTwiddle Block
Signal Direction Type Description
v Input Boolean. Input valid signal.
d Input Compatible with user-specified input type. Vector of N data inputs.
drop Input Unsigned integer The number of stages to drop. GeneralMultiVTwiddle only.
qv Output Boolean. Output valid signal.
q Output User-specified output type. Vector of N data outputs.
qdrop Output Unisgned integer GeneralMultiVTwiddle only.