3 ms·
Good insight! I guess I don't really understand why we can't use native types then. I don't want to keep having to write these: pub fn fir_q31( s: &mut s
by the__alchemist 1y ago
Good insight! I guess I don't really understand why we can't use native types then. I don't want to keep having to write these:
pub fn fir_q31(
s: &mut sys::arm_fir_instance_q31,
input: &[i32],
output: &mut [i32],
block_size: usize,
) {
// void arm_fir_q31 (
// const arm_fir_instance_q31 * S,
// const float32_t * pSrc,
// float32_t * pDst,
// uint32_t blockSize
// )
// Parameters
// [in] S points to an instance of the floating-point FIR filter structure
// [in] pSrc points to the block of input data
// [out] pDst points to the block of output data
// [in] blockSize number of samples to process
// Returns none
compiler_fence(Ordering::SeqCst);
unsafe {
sys::arm_fir_q31(s, input.as_ptr(), output.as_mut_ptr(), block_size as u32);
}
}