diff --git a/Documentation/Doxygen/src/mainpage.md b/Documentation/Doxygen/src/mainpage.md index 3e3ae583..d7ce18e2 100644 --- a/Documentation/Doxygen/src/mainpage.md +++ b/Documentation/Doxygen/src/mainpage.md @@ -163,6 +163,21 @@ All algorithms are compared with a double precision reference and the different As consequence, the small differences that may exists between the different architecture implementations should be too small to have any practical consequences. +Also, when targetting Helium or Neon, some functions have different APIs. + +### Different API for Helium +* Biquad F32 and F16 : A different init function must be used +* FIR F32, F16, Q31, Q15 and Q7 : Coefficient array must be padded with zeros + +### Different API for Neon +* Biquad F32 initialization : An additional function must be used for initialization +* MFCC F32, F16, Q31 and Q15 : Additional temporary buffer required for the functions +* CFFT F32, F16, Q31 and Q15 : Additional temporary buffer required for the functions +* RFFT F32, F16, Q31 and Q15 : Additional temporary buffer required for the functions. Different arguments for the init function of Q31 and Q15 RFFT + +For CFFT and RFFT, a new Neon specific initialization function is available to be able to use longer FFTs. + +For CFFT, this new Neon specific initialization allows to use FFT lengths with factor of 3 and 5 in the length (but must still be a multiple of 4 length). ## License {#license} diff --git a/Include/dsp/transform_functions.h b/Include/dsp/transform_functions.h index 7fd7c195..191106dd 100755 --- a/Include/dsp/transform_functions.h +++ b/Include/dsp/transform_functions.h @@ -86,6 +86,10 @@ extern "C" * On Neon, there is another possibility. You can use arm_cfft_init_dynamic_q15. This function will allocate a buffer at runtime and compute at runtime all the tables that are required for a specific FFT size. This initialization is also supported by RFFT. * The computation to initialize all the tables can take lot of cycles * (since several cos and sin must be computed) + * + * With this new Neon specific initialization you can use longer lengths. + * With CFFT, you can also use lengths containing radix 3 and/or 5 (but + * the length must still be a multiple of 4). */ diff --git a/Ne10/CMSIS_NE10_fft_init.c b/Ne10/CMSIS_NE10_fft_init.c index 38913d31..bf588f33 100755 --- a/Ne10/CMSIS_NE10_fft_init.c +++ b/Ne10/CMSIS_NE10_fft_init.c @@ -376,6 +376,10 @@ static ne10_fft_cpx_float32_t* ne10_fft_generate_twiddles_transposed_float32 ( * memory must be released when no more used. * This function can be used with FFT lengths * longer than the ones supported on Cortex-M + * + * With this function, FFT lengths can also contain + * factor 3 and 5 (but must be multiple of 4) + * */ arm_cfft_instance_f32 *arm_cfft_init_dynamic_f32(uint32_t fftLen) { @@ -517,6 +521,9 @@ arm_cfft_instance_f32 *arm_cfft_init_dynamic_f32(uint32_t fftLen) * memory must be released when no more used. * This function can be used with FFT lengths * longer than the ones supported on Cortex-M + * + * With this function, FFT lengths can also contain + * factor 3 and 5 (but must be multiple of 4) */ arm_cfft_instance_q31 *arm_cfft_init_dynamic_q31(uint32_t fftLen) { @@ -613,6 +620,9 @@ arm_cfft_instance_q31 *arm_cfft_init_dynamic_q31(uint32_t fftLen) * memory must be released when no more used. * This function can be used with FFT lengths * longer than the ones supported on Cortex-M + * + * With this function, FFT lengths can also contain + * factor 3 and 5 (but must be multiple of 4) */ arm_cfft_instance_q15 *arm_cfft_init_dynamic_q15(uint32_t fftLen) { @@ -834,6 +844,9 @@ static ne10_fft_cpx_float16_t* ne10_fft_generate_twiddles_transposed_float16 ( * memory must be released when no more used. * This function can be used with FFT lengths * longer than the ones supported on Cortex-M + * + * With this function, FFT lengths can also contain + * factor 3 and 5 (but must be multiple of 4) */ arm_cfft_instance_f16 *arm_cfft_init_dynamic_f16(uint32_t fftLen) { @@ -962,6 +975,7 @@ arm_cfft_instance_f16 *arm_cfft_init_dynamic_f16(uint32_t fftLen) * memory must be released when no more used. * This function can be used with RFFT lengths * longer than the ones supported on Cortex-M + * */ arm_rfft_fast_instance_f16 *arm_rfft_fast_init_dynamic_f16 (uint32_t nfft) { @@ -1140,6 +1154,7 @@ arm_rfft_fast_instance_f16 *arm_rfft_fast_init_dynamic_f16 (uint32_t nfft) * memory must be released when no more used. * This function can be used with RFFT lengths * longer than the ones supported on Cortex-M + * */ arm_rfft_fast_instance_f32 *arm_rfft_fast_init_dynamic_f32 (uint32_t nfft) { @@ -1317,6 +1332,7 @@ arm_rfft_fast_instance_f32 *arm_rfft_fast_init_dynamic_f32 (uint32_t nfft) * memory must be released when no more used. * This function can be used with RFFT lengths * longer than the ones supported on Cortex-M + * */ arm_rfft_instance_q31 *arm_rfft_init_dynamic_q31(uint32_t nfft) { @@ -1428,6 +1444,7 @@ arm_rfft_fast_instance_f32 *arm_rfft_fast_init_dynamic_f32 (uint32_t nfft) * memory must be released when no more used. * This function can be used with RFFT lengths * longer than the ones supported on Cortex-M + * */ arm_rfft_instance_q15 *arm_rfft_init_dynamic_q15(uint32_t nfft) {