Main Content

Conditions for Code Replacement of DSP System Objects with QHL

Each DSP System object™ that can be used with the Support Package for Qualcomm Hexagon processors requires specific conditions to allow code replacement with the Qualcomm Hexagon Library (QHL). You use this code replacement when generating C code from a model. The Qualcomm Hexagon Library (QHL) supports these DSP System object only when you set specific properties, as indicated in the following table:

.

 DSP System ObjectInput RequirementsParameter RequirementsEquivalent Functions in Replacement
1dsp.FIRFilter (DSP System Toolbox)
  • Real values.

  • single data type

  • Input size must be even

  • Structure: Direct Form.

  • NumeratorSource:: Property or Input port.

  • Any frame-length if filter-length > 24.

    (or)

    8 <= frame-length <=64 if 16<=filter length <=24

mw_qhdsp_fir_af
2dsp.FIRDecimator (DSP System Toolbox)
  • Real values.

  • single data type

  • Input size must be even

  • Structure: Direct Form.

  • NumeratorSource:: Property or Input port or Auto.

  • Decimation Factor: 2,3,4

  • AllowArbitraryInputLength: false

  • Decimation Factor: 2 or 3 AND FrameLength > 10 AND FilterLength >10.(or) Decimation Factor: 4 AND FilterLength < 40

mw_qhdsp_decim_af

3dsp.FFT (DSP System Toolbox)
  • Real values.

  • single data type

  • Input size must be in powers of 2

  • Real : 16,32, ….

  • Complex: 8,16,...

  • FFTImplementation: Auto

  • BitReversedOutput: false

  • FFTLength : <same as input length > (If FFTLengthSource is set to Property)

  • Real FFT

    • mw_qhdsp_fft_gen_twiddles_real_acf

    • mw_qhdsp_acf_r1dfft_af

  • Complex FFT

    • mw_qhdsp_fft_gen_twiddles_complex_acf

    • mw_qhdsp_c1dfft_acf

4dsp.IFFT (DSP System Toolbox)
  • single data type.

  • Complex input values.

  • Input size must be in powers of 2.

  • Real : 32, 64 ….

  • Complex: 16, 32...

  • FFT Length: same as input length (FFTLengthSource: is set to Property)

  • Bit reversed order: false

  • Real FFT

    • mw_qhdsp_fft_gen_twiddles_real_acf

    • mw_qhdsp_af_r1difft_acf

  • Complex FFT

    • mw_qhdsp_fft_gen_twiddles_complex_acf

    • mw_qhdsp_c1idfft_acf

5dsp.SOSFilter (DSP System Toolbox)
  • single data type.

  • Real values.

Filter structure: Direct-form II Transposed

Coefficient sources: Property / Input port

HasScaleValues: True / False

Number of sections: 2 or 3 AND "FrameLength >= 50 (or) Number of sections>= 4 AND FrameLength >= 9

mw_qhdsp_iir_af

Note

Use only column-major layout for QHL/HVX replacements. For more information, see Row-Major and Column-Major Array Layouts.

See Also

| | | | |

Related Topics