This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Why does Keil drop 'const' in 'const q7_t * pCoeffs' in CMSIS/DSP/arm_fir_init_q7 () ?

Hi,

Why does Keil drop 'const' in 'const q7_t * pCoeffs' in CMSIS/DSP/arm_fir_init_q7 () ? I want my coefficients to be 'const(expr)'.



CMSIS defines arm_fir_init_q7() like this:

void arm_fir_init_q7
(
    arm_fir_instance_q7   * S       ,
    uint16_t                             numTaps ,
    const q7_t                      * pCoeffs ,   // 'const' here, +1
    q7_t                                 * pState  ,
    uint32_t                             blockSize
)

github.com/.../arm_fir_init_q7.c



Keil declaration of arm_fir_init_q7() in arm_math.h is:

void arm_fir_init_q7
(
    arm_fir_instance_q7   * S       ,
    uint16_t                            numTaps ,
    q7_t                                * pCoeffs ,        // Where is 'const' ?
    q7_t                                * pState  ,
    uint32_t                            blockSize
)

C:\Keil_v5\ARM\CMSIS\Include\arm_math.h
I use uVision V5.33 / armClang V6.15

Thanks