CSI-DSP  Version 1.0.0
CSI DSP Software Library
Functions

Functions

void csky_dsp_lib_vec_add16 (q15_t *A, q15_t *B, uint32_t N, q15_t *C)
 Q15 vector addition. More...
 
void csky_dsp_lib_vec_add32 (q31_t *A, q31_t *B, uint32_t N, q31_t *C)
 Q31 vector addition. More...
 

Description

Element-by-element addition of the Vector in the same length, the computaional process is:

    *(C+i) = *(A+i) + *(B+i),   0 <= i < N.

support for q15 and q31 format.

Function Documentation

void csky_dsp_lib_vec_add16 ( q15_t A,
q15_t B,
uint32_t  N,
q15_t C 
)
Parameters
[in]*Apoints to the input buffer a
[in]*Bpoints to the input buffer b
[in]Nnumber of samples in each vector
[out]*Cpoints to the output buffer
Returns
none

Scaling and Overflow Behavior:

The function uses saturating arithmetic. The result will be saturated, so the out put value is in the range of [0x8000, 0x7FFF].
void csky_dsp_lib_vec_add32 ( q31_t A,
q31_t B,
uint32_t  N,
q31_t C 
)
Parameters
[in]*Apoints to the input buffer a
[in]*Bpoints to the input buffer b
[in]Nnumber of samples in each vector
[out]*Cpoints to the output buffer
Returns
none

Scaling and Overflow Behavior:

The function uses saturating arithmetic. The result will be saturated, so the out put value is in the range of [0x80000000, 0x7FFFFFFF].