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

◆ nrf_axon_l2norm_16_32()

nrf_axon_result_e nrf_axon_l2norm_16_32 ( const int16_t * x_ptr,
int32_t * out_ptr,
uint16_t length,
uint8_t rounding_bits,
nrf_axon_syncmode_blocking_e block_mode,
bool keep_reservation )

#include <include/drivers/axon/nrf_axon_dsp_intrinsics.h>

"l2norm" => sums the square of the elements in vector X

Parameters
x_ptrx vector input. 16bit integers packed.
out_ptroutput scalar. 32bit integer rounded by rounding_bits.
lengthNumber of elements in the vectors (data samples). Must be a multiple of 4, at least 8, and no greater than 1024.
rounding_bitsNumber of bits to round the output by. 0 => no rounding, maximum of 31.
block_moderecommnended to be set to NRF_AXON_SYNC_MODE_BLOCKING_POLLING.
keep_reservationset to true if there are subsequent axon operations to execute immediately on completion. true prevents axon from be taken by another user and/or being powered off. Set to false if axon will not be used immediately after to free axon for other users and/or power down if idle.
Returns
kAxonResultSuccess on success or a negative error code (see nrf_axon_result_e)