Edge AI Add-on API 2.2.0
Loading...
Searching...
No Matches

◆ nrf_axon_fir_24_24_24()

nrf_axon_result_e nrf_axon_fir_24_24_24 ( const int32_t * in_ptr,
const int32_t * filter_ptr,
int32_t * out_ptr,
uint16_t input_length,
uint16_t filter_length,
uint8_t rounding_bits,
nrf_axon_syncmode_blocking_e block_mode,
bool keep_reservation )

"FIR" => "Finite Impulse Response" filter. Filter coefficients are MAC'd with the input in reverse order. ie, for filter length F, output x[n] = input[n-F]*filter[F-1] + input[n-F-1]*filter[F-2]+...input[n-1]*filter[0]. The filter output starts at outptr+ filter_length. out_ptr[0..filter_length-1] are written to but should be discarded.

Parameters
in_ptrpointer to the input, 24bit integer sign-extended to 32bits.
input_lengthlength of the input (in elements). Must be a multiple of 4, maximum of 1024, and be at least 4 greater than filter_length
filter_ptrpointer to the filter coefficients, 24bit integer sign-extended to 32bits.
filter_lengthlength of the filter (in elements). Must be a at least 12, a multiple of 4 and the last coefficient must be 0. 0 pad as necessary to meet these requirements.
rounding_bitsnumber of bits to round the output by.
out_ptrpointer to the output, int24 sign-extended to 32bits. 1st valid output starts at offset filter_length. Output can overlap/overwrite input.
Returns
kAxonResultSuccess on success or a negative error code (see nrf_axon_result_e)