MityDSP::tcSigProcTIDspSupport Class Reference
#include <SigProc/SigTIDspSupport.h>
List of all members.
Static Public Member Functions |
static void | gen_w_r2 (float *w, int N) |
static void | bit_rev (float *w, int N) |
static void | ExtractDualRealFFT (float *FFTData_Combined, float *FFTA, float *FFTB, int N, int NumBins) |
static void | compute_bitrev_index (short *index, int nx) |
static int | bitrev_index_length (int nx) |
static void | ExtractRealFFT (float *FFTData_Combined, float *FFTData, float *Twiddles, int N, int NumBins) |
static void | BuildExtractRealFFTTwiddles (float *Twiddles, int N) |
Detailed Description
The tcSigProcTIDspSupport class provides utility methods useful when using the TI provided DSP libraries.
- See also:
- tcSigProcTIDspSupport Page
Member Function Documentation
void tcSigProcTIDspSupport::gen_w_r2 |
( |
float * |
w, |
|
|
int |
N | |
|
) |
| | [static] |
This is a utility method to generate twiddle factors needed for the FFT processing libraries provided by TI.
- Parameters:
-
[out] | w | array for storing twiddle factors |
[in] | N | length of the array of data |
void tcSigProcTIDspSupport::bit_rev |
( |
float * |
x, |
|
|
int |
N | |
|
) |
| | [static] |
This is a utility method to reverse the order of a set of twiddle factors according to the instructions provided by TI for using the TI DSP libraries.
- Parameters:
-
[in,out] | x | array of data to reorder in bit-reveresed order |
[in] | N | length of the array of data |
void tcSigProcTIDspSupport::ExtractDualRealFFT |
( |
float * |
FFTData_Combined, |
|
|
float * |
FFTA, |
|
|
float * |
FFTB, |
|
|
int |
N, |
|
|
int |
NumBins = -1 | |
|
) |
| | [static] |
This routine will extract FFT spectra from the FFT results of 2 real signals that were combined as I and Q data samples prior to calling a complex FFT function. This utility is useful when only a complex FFT is available for signal processing and real input signals are presented: 2 time sets may be FFT'd using a single complex FFT call.
- Parameters:
-
[in] | FFTData_Combined | I/Q pairs of the FFT data, ordered. Length N complex numbers |
[out] | FFTA | complex I/Q results of length NumBins of the spectrum from the real samples |
[out] | FFTB | complex I/Q results of length NumBins of the spectrum from the imaginary samples |
[in] | N | size of the FFT |
[in] | NumBins | Number of I/Q samples to extract. Typically this should be no greater than N/2 as no additional information is useful in the second half of the FFT (it's the complex conjugate of the first half). This allows for faster extraction if only a sub-band is require. If < 0, all N bins will be extracted. |
- Note:
- See http://www.engineeringproductivitytools.com/stuff/T0001/PT10.HTM
void tcSigProcTIDspSupport::compute_bitrev_index |
( |
short * |
index, |
|
|
int |
nx | |
|
) |
| | [static] |
This routine calculates the index for bit reversal of an array of length nx. The length of the index table is 2^(2*ceil(k/2)) where nx = 2^k.
In other words, the length of the index table is:
- for even power of radix: sqrt(nx)
- for odd power of radix: sqrt(2*nx)
- Parameters:
-
[out] | index | indexes for use with DSPF_sp_bitrev_cplx |
[in] | nx | length of array to reverse |
- Note:
- this routine was copied from the TI DSP user's guide
int tcSigProcTIDspSupport::bitrev_index_length |
( |
int |
nx |
) |
[static] |
This routine determines the size of the table that will be generated by the compute_bitrev_index.
void tcSigProcTIDspSupport::ExtractRealFFT |
( |
float * |
FFTData_Combined, |
|
|
float * |
FFTData, |
|
|
float * |
Twiddles, |
|
|
int |
N, |
|
|
int |
NumBins = -1 | |
|
) |
| | [static] |
This routine will extract FFT spectra from the FFT results of a real signals that was input as I and Q data samples prior to calling a complex FFT function. This utility is useful when only a complex FFT is available for signal processing and a real input signal is presented. The FFT previously run is only N/2 instead of N.
- Parameters:
-
[in] | FFTData_Combined | I/Q pairs of the FFT data, ordered. Length N/2 complex numbers |
[out] | FFTData | I/Q results of length NumBins of the resulting spectrum |
[out] | Twiddles | array of N complex twiddles = -j*e(-j*2*pi*k/N) |
[in] | N | size of the desired FFT (FFT run was N/2) |
[in] | NumBins | Number of I/Q samples to extract. Typically this should be no greater than N/2 as no additional information is useful in the second half of the FFT (it's the complex conjugate of the first half). This allows for faster extraction if only a sub-band is require. If < 0, all N bins will be extracted. |
- Note:
- See http://www.engineeringproductivitytools.com/stuff/T0001/PT10.HTM
void tcSigProcTIDspSupport::BuildExtractRealFFTTwiddles |
( |
float * |
Twiddles, |
|
|
int |
N | |
|
) |
| | [static] |