diff --git a/DSP_Lib_TestSuite/RefLibs/src/FilteringFunctions/lms.c b/DSP_Lib_TestSuite/RefLibs/src/FilteringFunctions/lms.c index 9c60a461..30435f3e 100644 --- a/DSP_Lib_TestSuite/RefLibs/src/FilteringFunctions/lms.c +++ b/DSP_Lib_TestSuite/RefLibs/src/FilteringFunctions/lms.c @@ -436,7 +436,7 @@ void ref_lms_q15( q63_t acc; /* Accumulator */ q15_t e = 0; /* error of data sample */ q15_t alpha; /* Intermediate constant for taps update */ - q31_t coef; /* Teporary variable for coefficient */ + q31_t coef; /* Temporary variable for coefficient */ q31_t acc_l, acc_h; int32_t lShift = 15 - (int32_t)S->postShift; /* Post shift */ int32_t uShift = 32 - lShift; @@ -558,7 +558,7 @@ void ref_lms_norm_q15( q15_t errorXmu, oneByEnergy; /* Temporary variables to store error and mu product and reciprocal of energy */ //q31_t errorXmu; /* Temporary variables to store error and mu product and reciprocal of energy */ q15_t postShift; /* Post shift to be applied to weight after reciprocal calculation */ - q31_t coef; /* Teporary variable for coefficient */ + q31_t coef; /* Temporary variable for coefficient */ q31_t acc_l, acc_h; int32_t lShift = 15 - (int32_t)S->postShift; /* Post shift */ int32_t uShift = 32 - lShift; diff --git a/Include/arm_math.h b/Include/arm_math.h index 1d950937..00e34039 100644 --- a/Include/arm_math.h +++ b/Include/arm_math.h @@ -2120,7 +2120,7 @@ void arm_cfft_q31( void arm_rfft_q15( const arm_rfft_instance_q15 * S, - const q15_t * pSrc, + q15_t * pSrc, q15_t * pDst); /** @@ -2145,7 +2145,7 @@ void arm_cfft_q31( void arm_rfft_q31( const arm_rfft_instance_q31 * S, - const q31_t * pSrc, + q31_t * pSrc, q31_t * pDst); /** @@ -2172,7 +2172,7 @@ void arm_cfft_q31( void arm_rfft_f32( const arm_rfft_instance_f32 * S, - const float32_t * pSrc, + float32_t * pSrc, float32_t * pDst); /** diff --git a/Source/FilteringFunctions/arm_lms_norm_q15.c b/Source/FilteringFunctions/arm_lms_norm_q15.c index 69a7bc8e..03194dbc 100644 --- a/Source/FilteringFunctions/arm_lms_norm_q15.c +++ b/Source/FilteringFunctions/arm_lms_norm_q15.c @@ -87,7 +87,7 @@ void arm_lms_norm_q15( //uint32_t shift = (uint32_t) S->postShift + 1U; /* Shift to be applied to the output */ q15_t errorXmu, oneByEnergy; /* Temporary variables to store error and mu product and reciprocal of energy */ q15_t postShift; /* Post shift to be applied to weight after reciprocal calculation */ - q31_t coef; /* Teporary variable for coefficient */ + q31_t coef; /* Temporary variable for coefficient */ q31_t acc_l, acc_h; int32_t lShift = (15 - (int32_t) S->postShift); /* Post shift */ int32_t uShift = (32 - lShift); diff --git a/Source/FilteringFunctions/arm_lms_norm_q31.c b/Source/FilteringFunctions/arm_lms_norm_q31.c index 029c071a..605dba2e 100644 --- a/Source/FilteringFunctions/arm_lms_norm_q31.c +++ b/Source/FilteringFunctions/arm_lms_norm_q31.c @@ -189,7 +189,7 @@ void arm_lms_norm_q31( px = pState; /* Initialize coeff pointer */ - pb = (pCoeffs); + pb = (q31_t*) (pCoeffs); /* Loop unrolling. Process 4 taps at a time. */ tapCnt = numTaps >> 2; diff --git a/Source/FilteringFunctions/arm_lms_q15.c b/Source/FilteringFunctions/arm_lms_q15.c index 1e2c1007..dcbd9efa 100644 --- a/Source/FilteringFunctions/arm_lms_q15.c +++ b/Source/FilteringFunctions/arm_lms_q15.c @@ -69,16 +69,16 @@ void arm_lms_q15( { q15_t *pState = S->pState; /* State pointer */ uint32_t numTaps = S->numTaps; /* Number of filter coefficients in the filter */ - const q15_t *pCoeffs = S->pCoeffs; /* Coefficient pointer */ + const q15_t *pCoeffs = S->pCoeffs; /* Coefficient pointer */ q15_t *pStateCurnt; /* Points to the current sample of the state */ q15_t mu = S->mu; /* Adaptive factor */ - const q15_t *px; /* Temporary pointer for state */ + q15_t *px; /* Temporary pointer for state */ q15_t *pb; /* Temporary pointer for coefficient buffer */ uint32_t tapCnt, blkCnt; /* Loop counters */ q63_t acc; /* Accumulator */ q15_t e = 0; /* error of data sample */ q15_t alpha; /* Intermediate constant for taps update */ - q31_t coef; /* Teporary variable for coefficient */ + q31_t coef; /* Temporary variable for coefficient */ q31_t acc_l, acc_h; int32_t lShift = (15 - (int32_t) S->postShift); /* Post shift */ int32_t uShift = (32 - lShift); @@ -105,7 +105,7 @@ void arm_lms_q15( px = pState; /* Initialize coefficient pointer */ - pb = pCoeffs; + pb = (q15_t*) pCoeffs; /* Set the accumulator to zero */ acc = 0; @@ -176,7 +176,7 @@ void arm_lms_q15( px = pState++; /* Initialize coefficient pointer */ - pb = pCoeffs; + pb = (q15_t*) pCoeffs; /* Loop unrolling. Process 4 taps at a time. */ tapCnt = numTaps >> 2U; diff --git a/Source/FilteringFunctions/arm_lms_q31.c b/Source/FilteringFunctions/arm_lms_q31.c index 325a5f3f..91944e3f 100644 --- a/Source/FilteringFunctions/arm_lms_q31.c +++ b/Source/FilteringFunctions/arm_lms_q31.c @@ -107,7 +107,7 @@ void arm_lms_q31( px = pState; /* Initialize coefficient pointer */ - pb = pCoeffs; + pb = (q31_t*) pCoeffs; /* Set the accumulator to zero */ acc = 0; @@ -171,7 +171,7 @@ void arm_lms_q31( px = pState++; /* Initialize coefficient pointer */ - pb = pCoeffs; + pb = (q31_t*) pCoeffs; /* Loop unrolling. Process 4 taps at a time. */ tapCnt = numTaps >> 2; diff --git a/Source/StatisticsFunctions/arm_var_f32.c b/Source/StatisticsFunctions/arm_var_f32.c index 112aec78..f5759300 100644 --- a/Source/StatisticsFunctions/arm_var_f32.c +++ b/Source/StatisticsFunctions/arm_var_f32.c @@ -69,7 +69,7 @@ void arm_var_f32( { float32_t fMean, fValue; uint32_t blkCnt; /* loop counter */ - float32_t * pInput = pSrc; + const float32_t *pInput = pSrc; float32_t sum = 0.0f; float32_t fSum = 0.0f; #if defined(ARM_MATH_DSP) diff --git a/Source/SupportFunctions/arm_float_to_q15.c b/Source/SupportFunctions/arm_float_to_q15.c index 44baf7c1..edfc36cd 100644 --- a/Source/SupportFunctions/arm_float_to_q15.c +++ b/Source/SupportFunctions/arm_float_to_q15.c @@ -66,7 +66,7 @@ void arm_float_to_q15( q15_t * pDst, uint32_t blockSize) { - float32_t *pIn = pSrc; /* Src pointer */ + const float32_t *pIn = pSrc; /* Src pointer */ uint32_t blkCnt; /* loop counter */ #ifdef ARM_MATH_ROUNDING diff --git a/Source/SupportFunctions/arm_float_to_q31.c b/Source/SupportFunctions/arm_float_to_q31.c index 50104528..ea12db04 100644 --- a/Source/SupportFunctions/arm_float_to_q31.c +++ b/Source/SupportFunctions/arm_float_to_q31.c @@ -70,7 +70,7 @@ void arm_float_to_q31( q31_t * pDst, uint32_t blockSize) { - float32_t *pIn = pSrc; /* Src pointer */ + const float32_t *pIn = pSrc; /* Src pointer */ uint32_t blkCnt; /* loop counter */ #ifdef ARM_MATH_ROUNDING diff --git a/Source/SupportFunctions/arm_float_to_q7.c b/Source/SupportFunctions/arm_float_to_q7.c index 0fcead5f..d1ed1e74 100644 --- a/Source/SupportFunctions/arm_float_to_q7.c +++ b/Source/SupportFunctions/arm_float_to_q7.c @@ -65,7 +65,7 @@ void arm_float_to_q7( q7_t * pDst, uint32_t blockSize) { - float32_t *pIn = pSrc; /* Src pointer */ + const float32_t *pIn = pSrc; /* Src pointer */ uint32_t blkCnt; /* loop counter */ #ifdef ARM_MATH_ROUNDING diff --git a/Source/SupportFunctions/arm_q15_to_float.c b/Source/SupportFunctions/arm_q15_to_float.c index 2cef5865..5af0cbf3 100644 --- a/Source/SupportFunctions/arm_q15_to_float.c +++ b/Source/SupportFunctions/arm_q15_to_float.c @@ -67,7 +67,7 @@ void arm_q15_to_float( float32_t * pDst, uint32_t blockSize) { - q15_t *pIn = pSrc; /* Src pointer */ + const q15_t *pIn = pSrc; /* Src pointer */ uint32_t blkCnt; /* loop counter */ diff --git a/Source/SupportFunctions/arm_q15_to_q31.c b/Source/SupportFunctions/arm_q15_to_q31.c index 9acb54c5..3ca6f4cf 100644 --- a/Source/SupportFunctions/arm_q15_to_q31.c +++ b/Source/SupportFunctions/arm_q15_to_q31.c @@ -60,7 +60,7 @@ void arm_q15_to_q31( q31_t * pDst, uint32_t blockSize) { - q15_t *pIn = pSrc; /* Src pointer */ + const q15_t *pIn = pSrc; /* Src pointer */ uint32_t blkCnt; /* loop counter */ #if defined (ARM_MATH_DSP) diff --git a/Source/SupportFunctions/arm_q15_to_q7.c b/Source/SupportFunctions/arm_q15_to_q7.c index 40477709..7ccf2ddf 100644 --- a/Source/SupportFunctions/arm_q15_to_q7.c +++ b/Source/SupportFunctions/arm_q15_to_q7.c @@ -61,7 +61,7 @@ void arm_q15_to_q7( q7_t * pDst, uint32_t blockSize) { - q15_t *pIn = pSrc; /* Src pointer */ + const q15_t *pIn = pSrc; /* Src pointer */ uint32_t blkCnt; /* loop counter */ #if defined (ARM_MATH_DSP) diff --git a/Source/SupportFunctions/arm_q31_to_float.c b/Source/SupportFunctions/arm_q31_to_float.c index 4b043386..3eb5bfbc 100644 --- a/Source/SupportFunctions/arm_q31_to_float.c +++ b/Source/SupportFunctions/arm_q31_to_float.c @@ -64,7 +64,7 @@ void arm_q31_to_float( float32_t * pDst, uint32_t blockSize) { - q31_t *pIn = pSrc; /* Src pointer */ + const q31_t *pIn = pSrc; /* Src pointer */ uint32_t blkCnt; /* loop counter */ diff --git a/Source/SupportFunctions/arm_q31_to_q15.c b/Source/SupportFunctions/arm_q31_to_q15.c index 684e102f..de937346 100644 --- a/Source/SupportFunctions/arm_q31_to_q15.c +++ b/Source/SupportFunctions/arm_q31_to_q15.c @@ -60,7 +60,7 @@ void arm_q31_to_q15( q15_t * pDst, uint32_t blockSize) { - q31_t *pIn = pSrc; /* Src pointer */ + const q31_t *pIn = pSrc; /* Src pointer */ uint32_t blkCnt; /* loop counter */ #if defined (ARM_MATH_DSP) diff --git a/Source/SupportFunctions/arm_q31_to_q7.c b/Source/SupportFunctions/arm_q31_to_q7.c index ef8dceae..46a23e2c 100644 --- a/Source/SupportFunctions/arm_q31_to_q7.c +++ b/Source/SupportFunctions/arm_q31_to_q7.c @@ -60,7 +60,7 @@ void arm_q31_to_q7( q7_t * pDst, uint32_t blockSize) { - q31_t *pIn = pSrc; /* Src pointer */ + const q31_t *pIn = pSrc; /* Src pointer */ uint32_t blkCnt; /* loop counter */ #if defined (ARM_MATH_DSP) diff --git a/Source/SupportFunctions/arm_q7_to_float.c b/Source/SupportFunctions/arm_q7_to_float.c index 93279ebc..7ba44718 100644 --- a/Source/SupportFunctions/arm_q7_to_float.c +++ b/Source/SupportFunctions/arm_q7_to_float.c @@ -64,7 +64,7 @@ void arm_q7_to_float( float32_t * pDst, uint32_t blockSize) { - q7_t *pIn = pSrc; /* Src pointer */ + const q7_t *pIn = pSrc; /* Src pointer */ uint32_t blkCnt; /* loop counter */ diff --git a/Source/SupportFunctions/arm_q7_to_q15.c b/Source/SupportFunctions/arm_q7_to_q15.c index 26b77c81..7b00bf6a 100644 --- a/Source/SupportFunctions/arm_q7_to_q15.c +++ b/Source/SupportFunctions/arm_q7_to_q15.c @@ -63,7 +63,7 @@ void arm_q7_to_q15( q15_t * pDst, uint32_t blockSize) { - q7_t *pIn = pSrc; /* Src pointer */ + const q7_t *pIn = pSrc; /* Src pointer */ uint32_t blkCnt; /* loop counter */ #if defined (ARM_MATH_DSP) diff --git a/Source/SupportFunctions/arm_q7_to_q31.c b/Source/SupportFunctions/arm_q7_to_q31.c index 230a541b..d179c4f2 100644 --- a/Source/SupportFunctions/arm_q7_to_q31.c +++ b/Source/SupportFunctions/arm_q7_to_q31.c @@ -60,7 +60,7 @@ void arm_q7_to_q31( q31_t * pDst, uint32_t blockSize) { - q7_t *pIn = pSrc; /* Src pointer */ + const q7_t *pIn = pSrc; /* Src pointer */ uint32_t blkCnt; /* loop counter */ #if defined (ARM_MATH_DSP) diff --git a/Source/TransformFunctions/arm_cfft_radix2_f32.c b/Source/TransformFunctions/arm_cfft_radix2_f32.c index e73c3085..705a36a4 100644 --- a/Source/TransformFunctions/arm_cfft_radix2_f32.c +++ b/Source/TransformFunctions/arm_cfft_radix2_f32.c @@ -45,7 +45,7 @@ extern void arm_bitreversal_f32( float32_t * pSrc, uint16_t fftSize, uint16_t bitRevFactor, - uint16_t * pBitRevTab); + const uint16_t * pBitRevTab); /** * @ingroup groupTransforms diff --git a/Source/TransformFunctions/arm_cfft_radix2_q15.c b/Source/TransformFunctions/arm_cfft_radix2_q15.c index 8880ab9c..37f3819c 100644 --- a/Source/TransformFunctions/arm_cfft_radix2_q15.c +++ b/Source/TransformFunctions/arm_cfft_radix2_q15.c @@ -31,20 +31,20 @@ void arm_radix2_butterfly_q15( q15_t * pSrc, uint32_t fftLen, - q15_t * pCoef, + const q15_t * pCoef, uint16_t twidCoefModifier); void arm_radix2_butterfly_inverse_q15( q15_t * pSrc, uint32_t fftLen, - q15_t * pCoef, + const q15_t * pCoef, uint16_t twidCoefModifier); void arm_bitreversal_q15( q15_t * pSrc, uint32_t fftLen, uint16_t bitRevFactor, - uint16_t * pBitRevTab); + const uint16_t * pBitRevTab); /** * @ingroup groupTransforms @@ -90,7 +90,7 @@ void arm_cfft_radix2_q15( void arm_radix2_butterfly_q15( q15_t * pSrc, uint32_t fftLen, - q15_t * pCoef, + const q15_t * pCoef, uint16_t twidCoefModifier) { #if defined (ARM_MATH_DSP) @@ -419,7 +419,7 @@ void arm_radix2_butterfly_q15( void arm_radix2_butterfly_inverse_q15( q15_t * pSrc, uint32_t fftLen, - q15_t * pCoef, + const q15_t * pCoef, uint16_t twidCoefModifier) { #if defined (ARM_MATH_DSP) diff --git a/Source/TransformFunctions/arm_cfft_radix2_q31.c b/Source/TransformFunctions/arm_cfft_radix2_q31.c index c9b15371..8f362608 100644 --- a/Source/TransformFunctions/arm_cfft_radix2_q31.c +++ b/Source/TransformFunctions/arm_cfft_radix2_q31.c @@ -31,20 +31,20 @@ void arm_radix2_butterfly_q31( q31_t * pSrc, uint32_t fftLen, - q31_t * pCoef, + const q31_t * pCoef, uint16_t twidCoefModifier); void arm_radix2_butterfly_inverse_q31( q31_t * pSrc, uint32_t fftLen, - q31_t * pCoef, + const q31_t * pCoef, uint16_t twidCoefModifier); void arm_bitreversal_q31( q31_t * pSrc, uint32_t fftLen, uint16_t bitRevFactor, - uint16_t * pBitRevTab); + const uint16_t * pBitRevTab); /** * @ingroup groupTransforms @@ -90,7 +90,7 @@ q31_t * pSrc) void arm_radix2_butterfly_q31( q31_t * pSrc, uint32_t fftLen, -q31_t * pCoef, +const q31_t * pCoef, uint16_t twidCoefModifier) { @@ -218,7 +218,7 @@ uint16_t twidCoefModifier) void arm_radix2_butterfly_inverse_q31( q31_t * pSrc, uint32_t fftLen, -q31_t * pCoef, +const q31_t * pCoef, uint16_t twidCoefModifier) { diff --git a/Source/TransformFunctions/arm_cfft_radix4_f32.c b/Source/TransformFunctions/arm_cfft_radix4_f32.c index d6f66aeb..dc0a9b46 100644 --- a/Source/TransformFunctions/arm_cfft_radix4_f32.c +++ b/Source/TransformFunctions/arm_cfft_radix4_f32.c @@ -32,18 +32,18 @@ extern void arm_bitreversal_f32( float32_t * pSrc, uint16_t fftSize, uint16_t bitRevFactor, -uint16_t * pBitRevTab); +const uint16_t * pBitRevTab); void arm_radix4_butterfly_f32( float32_t * pSrc, uint16_t fftLen, -float32_t * pCoef, +const float32_t * pCoef, uint16_t twidCoefModifier); void arm_radix4_butterfly_inverse_f32( float32_t * pSrc, uint16_t fftLen, -float32_t * pCoef, +const float32_t * pCoef, uint16_t twidCoefModifier, float32_t onebyfftLen); @@ -110,7 +110,7 @@ void arm_cfft_radix4_f32( void arm_radix4_butterfly_f32( float32_t * pSrc, uint16_t fftLen, -float32_t * pCoef, +const float32_t * pCoef, uint16_t twidCoefModifier) { @@ -614,7 +614,7 @@ uint16_t twidCoefModifier) void arm_radix4_butterfly_inverse_f32( float32_t * pSrc, uint16_t fftLen, -float32_t * pCoef, +const float32_t * pCoef, uint16_t twidCoefModifier, float32_t onebyfftLen) { diff --git a/Source/TransformFunctions/arm_cfft_radix4_q15.c b/Source/TransformFunctions/arm_cfft_radix4_q15.c index f3451f74..f0f257c6 100644 --- a/Source/TransformFunctions/arm_cfft_radix4_q15.c +++ b/Source/TransformFunctions/arm_cfft_radix4_q15.c @@ -33,20 +33,20 @@ void arm_radix4_butterfly_q15( q15_t * pSrc16, uint32_t fftLen, - q15_t * pCoef16, + const q15_t * pCoef16, uint32_t twidCoefModifier); void arm_radix4_butterfly_inverse_q15( q15_t * pSrc16, uint32_t fftLen, - q15_t * pCoef16, + const q15_t * pCoef16, uint32_t twidCoefModifier); void arm_bitreversal_q15( q15_t * pSrc, uint32_t fftLen, uint16_t bitRevFactor, - uint16_t * pBitRevTab); + const int16_t * pBitRevTab); /** * @ingroup groupTransforms @@ -149,7 +149,7 @@ void arm_cfft_radix4_q15( void arm_radix4_butterfly_q15( q15_t * pSrc16, uint32_t fftLen, - q15_t * pCoef16, + const q15_t * pCoef16, uint32_t twidCoefModifier) { @@ -1066,7 +1066,7 @@ void arm_radix4_butterfly_q15( void arm_radix4_butterfly_inverse_q15( q15_t * pSrc16, uint32_t fftLen, - q15_t * pCoef16, + const q15_t * pCoef16, uint32_t twidCoefModifier) { diff --git a/Source/TransformFunctions/arm_cfft_radix4_q31.c b/Source/TransformFunctions/arm_cfft_radix4_q31.c index 09706203..0bca08ca 100644 --- a/Source/TransformFunctions/arm_cfft_radix4_q31.c +++ b/Source/TransformFunctions/arm_cfft_radix4_q31.c @@ -32,20 +32,20 @@ void arm_radix4_butterfly_inverse_q31( q31_t * pSrc, uint32_t fftLen, -q31_t * pCoef, +const q31_t * pCoef, uint32_t twidCoefModifier); void arm_radix4_butterfly_q31( q31_t * pSrc, uint32_t fftLen, -q31_t * pCoef, +const q31_t * pCoef, uint32_t twidCoefModifier); void arm_bitreversal_q31( q31_t * pSrc, uint32_t fftLen, uint16_t bitRevFactor, -uint16_t * pBitRevTab); +const uint16_t * pBitRevTab); /** * @ingroup groupTransforms @@ -148,7 +148,7 @@ void arm_cfft_radix4_q31( void arm_radix4_butterfly_q31( q31_t * pSrc, uint32_t fftLen, - q31_t * pCoef, + const q31_t * pCoef, uint32_t twidCoefModifier) { uint32_t n1, n2, ia1, ia2, ia3, i0, i1, i2, i3, j, k; @@ -553,7 +553,7 @@ void arm_radix4_butterfly_q31( void arm_radix4_butterfly_inverse_q31( q31_t * pSrc, uint32_t fftLen, - q31_t * pCoef, + const q31_t * pCoef, uint32_t twidCoefModifier) { uint32_t n1, n2, ia1, ia2, ia3, i0, i1, i2, i3, j, k; diff --git a/Source/TransformFunctions/arm_dct4_f32.c b/Source/TransformFunctions/arm_dct4_f32.c index 231c79a3..922f3883 100644 --- a/Source/TransformFunctions/arm_dct4_f32.c +++ b/Source/TransformFunctions/arm_dct4_f32.c @@ -128,8 +128,8 @@ void arm_dct4_f32( float32_t * pInlineBuffer) { uint32_t i; /* Loop counter */ - float32_t *weights = S->pTwiddle; /* Pointer to the Weights table */ - float32_t *cosFact = S->pCosFactor; /* Pointer to the cos factors table */ + const float32_t *weights = S->pTwiddle; /* Pointer to the Weights table */ + const float32_t *cosFact = S->pCosFactor; /* Pointer to the cos factors table */ float32_t *pS1, *pS2, *pbuff; /* Temporary pointers for input buffer and pState buffer */ float32_t in; /* Temporary variable */ diff --git a/Source/TransformFunctions/arm_dct4_q15.c b/Source/TransformFunctions/arm_dct4_q15.c index 918f0bd2..7aebf4e1 100644 --- a/Source/TransformFunctions/arm_dct4_q15.c +++ b/Source/TransformFunctions/arm_dct4_q15.c @@ -54,8 +54,8 @@ void arm_dct4_q15( q15_t * pInlineBuffer) { uint32_t i; /* Loop counter */ - q15_t *weights = S->pTwiddle; /* Pointer to the Weights table */ - q15_t *cosFact = S->pCosFactor; /* Pointer to the cos factors table */ + const q15_t *weights = S->pTwiddle; /* Pointer to the Weights table */ + const q15_t *cosFact = S->pCosFactor; /* Pointer to the cos factors table */ q15_t *pS1, *pS2, *pbuff; /* Temporary pointers for input buffer and pState buffer */ q15_t in; /* Temporary variable */ diff --git a/Source/TransformFunctions/arm_dct4_q31.c b/Source/TransformFunctions/arm_dct4_q31.c index 05697789..3ac7c2b7 100644 --- a/Source/TransformFunctions/arm_dct4_q31.c +++ b/Source/TransformFunctions/arm_dct4_q31.c @@ -55,8 +55,8 @@ void arm_dct4_q31( q31_t * pInlineBuffer) { uint16_t i; /* Loop counter */ - q31_t *weights = S->pTwiddle; /* Pointer to the Weights table */ - q31_t *cosFact = S->pCosFactor; /* Pointer to the cos factors table */ + const q31_t *weights = S->pTwiddle; /* Pointer to the Weights table */ + const q31_t *cosFact = S->pCosFactor; /* Pointer to the cos factors table */ q31_t *pS1, *pS2, *pbuff; /* Temporary pointers for input buffer and pState buffer */ q31_t in; /* Temporary variable */ diff --git a/Source/TransformFunctions/arm_rfft_f32.c b/Source/TransformFunctions/arm_rfft_f32.c index a1bd81b1..70d784f4 100644 --- a/Source/TransformFunctions/arm_rfft_f32.c +++ b/Source/TransformFunctions/arm_rfft_f32.c @@ -35,13 +35,13 @@ extern void arm_radix4_butterfly_f32( float32_t * pSrc, uint16_t fftLen, - float32_t * pCoef, + const float32_t * pCoef, uint16_t twidCoefModifier); extern void arm_radix4_butterfly_inverse_f32( float32_t * pSrc, uint16_t fftLen, - float32_t * pCoef, + const float32_t * pCoef, uint16_t twidCoefModifier, float32_t onebyfftLen); @@ -49,21 +49,21 @@ extern void arm_bitreversal_f32( float32_t * pSrc, uint16_t fftSize, uint16_t bitRevFactor, - uint16_t * pBitRevTab); + const uint16_t * pBitRevTab); void arm_split_rfft_f32( float32_t * pSrc, uint32_t fftLen, - float32_t * pATable, - float32_t * pBTable, + const float32_t * pATable, + const float32_t * pBTable, float32_t * pDst, uint32_t modifier); void arm_split_rifft_f32( float32_t * pSrc, uint32_t fftLen, - float32_t * pATable, - float32_t * pBTable, + const float32_t * pATable, + const float32_t * pBTable, float32_t * pDst, uint32_t modifier); @@ -157,14 +157,14 @@ void arm_rfft_f32( void arm_split_rfft_f32( float32_t * pSrc, uint32_t fftLen, - float32_t * pATable, - float32_t * pBTable, + const float32_t * pATable, + const float32_t * pBTable, float32_t * pDst, uint32_t modifier) { uint32_t i; /* Loop Counter */ float32_t outR, outI; /* Temporary variables for output */ - float32_t *pCoefA, *pCoefB; /* Temporary pointers for twiddle factors */ + const float32_t *pCoefA, *pCoefB; /* Temporary pointers for twiddle factors */ float32_t CoefA1, CoefA2, CoefB1; /* Temporary variables for twiddle coefficients */ float32_t *pDst1 = &pDst[2], *pDst2 = &pDst[(4U * fftLen) - 1U]; /* temp pointers for output buffer */ float32_t *pSrc1 = &pSrc[2], *pSrc2 = &pSrc[(2U * fftLen) - 1U]; /* temp pointers for input buffer */ @@ -251,13 +251,13 @@ void arm_split_rfft_f32( void arm_split_rifft_f32( float32_t * pSrc, uint32_t fftLen, - float32_t * pATable, - float32_t * pBTable, + const float32_t * pATable, + const float32_t * pBTable, float32_t * pDst, uint32_t modifier) { float32_t outR, outI; /* Temporary variables for output */ - float32_t *pCoefA, *pCoefB; /* Temporary pointers for twiddle factors */ + const float32_t *pCoefA, *pCoefB; /* Temporary pointers for twiddle factors */ float32_t CoefA1, CoefA2, CoefB1; /* Temporary variables for twiddle coefficients */ float32_t *pSrc1 = &pSrc[0], *pSrc2 = &pSrc[(2U * fftLen) + 1U]; diff --git a/Source/TransformFunctions/arm_rfft_q15.c b/Source/TransformFunctions/arm_rfft_q15.c index f85cf302..aafe2314 100644 --- a/Source/TransformFunctions/arm_rfft_q15.c +++ b/Source/TransformFunctions/arm_rfft_q15.c @@ -35,16 +35,16 @@ void arm_split_rfft_q15( q15_t * pSrc, uint32_t fftLen, - q15_t * pATable, - q15_t * pBTable, + const q15_t * pATable, + const q15_t * pBTable, q15_t * pDst, uint32_t modifier); void arm_split_rifft_q15( q15_t * pSrc, uint32_t fftLen, - q15_t * pATable, - q15_t * pBTable, + const q15_t * pATable, + const q15_t * pBTable, q15_t * pDst, uint32_t modifier); @@ -127,14 +127,14 @@ void arm_rfft_q15( void arm_split_rfft_q15( q15_t * pSrc, uint32_t fftLen, - q15_t * pATable, - q15_t * pBTable, + const q15_t * pATable, + const q15_t * pBTable, q15_t * pDst, uint32_t modifier) { uint32_t i; /* Loop Counter */ q31_t outR, outI; /* Temporary variables for output */ - q15_t *pCoefA, *pCoefB; /* Temporary pointers for twiddle factors */ + const q15_t *pCoefA, *pCoefB; /* Temporary pointers for twiddle factors */ q15_t *pSrc1, *pSrc2; #if defined (ARM_MATH_DSP) q15_t *pD1, *pD2; @@ -282,7 +282,7 @@ void arm_split_rfft_q15( /** * @brief Core Real IFFT process * @param[in] *pSrc points to the input buffer. -* @param[in] fftLen length of FFT. +* @param[in] fftLen length of FFT. * @param[in] *pATable points to the twiddle Coef A buffer. * @param[in] *pBTable points to the twiddle Coef B buffer. * @param[out] *pDst points to the output buffer. @@ -293,14 +293,14 @@ void arm_split_rfft_q15( void arm_split_rifft_q15( q15_t * pSrc, uint32_t fftLen, - q15_t * pATable, - q15_t * pBTable, + const q15_t * pATable, + const q15_t * pBTable, q15_t * pDst, uint32_t modifier) { uint32_t i; /* Loop Counter */ q31_t outR, outI; /* Temporary variables for output */ - q15_t *pCoefA, *pCoefB; /* Temporary pointers for twiddle factors */ + const q15_t *pCoefA, *pCoefB; /* Temporary pointers for twiddle factors */ q15_t *pSrc1, *pSrc2; q15_t *pDst1 = &pDst[0]; diff --git a/Source/TransformFunctions/arm_rfft_q31.c b/Source/TransformFunctions/arm_rfft_q31.c index 5386140f..f6bd3d7d 100644 --- a/Source/TransformFunctions/arm_rfft_q31.c +++ b/Source/TransformFunctions/arm_rfft_q31.c @@ -35,16 +35,16 @@ void arm_split_rfft_q31( q31_t * pSrc, uint32_t fftLen, - q31_t * pATable, - q31_t * pBTable, + const q31_t * pATable, + const q31_t * pBTable, q31_t * pDst, uint32_t modifier); void arm_split_rifft_q31( q31_t * pSrc, uint32_t fftLen, - q31_t * pATable, - q31_t * pBTable, + const q31_t * pATable, + const q31_t * pBTable, q31_t * pDst, uint32_t modifier); @@ -125,14 +125,14 @@ void arm_rfft_q31( void arm_split_rfft_q31( q31_t * pSrc, uint32_t fftLen, - q31_t * pATable, - q31_t * pBTable, + const q31_t * pATable, + const q31_t * pBTable, q31_t * pDst, uint32_t modifier) { uint32_t i; /* Loop Counter */ q31_t outR, outI; /* Temporary variables for output */ - q31_t *pCoefA, *pCoefB; /* Temporary pointers for twiddle factors */ + const q31_t *pCoefA, *pCoefB; /* Temporary pointers for twiddle factors */ q31_t CoefA1, CoefA2, CoefB1; /* Temporary variables for twiddle coefficients */ q31_t *pOut1 = &pDst[2], *pOut2 = &pDst[(4U * fftLen) - 1U]; q31_t *pIn1 = &pSrc[2], *pIn2 = &pSrc[(2U * fftLen) - 1U]; @@ -217,13 +217,13 @@ void arm_split_rfft_q31( void arm_split_rifft_q31( q31_t * pSrc, uint32_t fftLen, - q31_t * pATable, - q31_t * pBTable, + const q31_t * pATable, + const q31_t * pBTable, q31_t * pDst, uint32_t modifier) { q31_t outR, outI; /* Temporary variables for output */ - q31_t *pCoefA, *pCoefB; /* Temporary pointers for twiddle factors */ + const q31_t *pCoefA, *pCoefB; /* Temporary pointers for twiddle factors */ q31_t CoefA1, CoefA2, CoefB1; /* Temporary variables for twiddle coefficients */ q31_t *pIn1 = &pSrc[0], *pIn2 = &pSrc[(2U * fftLen) + 1U];