中级会员
 
- 积分
- 494
- 金钱
- 494
- 注册时间
- 2017-10-14
- 在线时间
- 76 小时
|
50金钱
如何使用CMSIS DSP库替换STM32官方库cr4_fft_256_stm32函数使用ST官方库文件调用下面函数,可以进行整数类型计算:
cr4_fft_256_stm32(outputA,inputA,256);计算出实部虚部
PowerMag(); 自编函数计算频率点幅值
更改使用CMSIS DSP库,由于这个DSP库只能输入参数为浮点型,但是计算结果理论上不应该有问题,同样的输入参数但是实际计算出来的结果天差地别,不知道哪里出了问题,另外看网上都是进行1024点的傅里叶变换,不知道这个dsp库支不支持256点的计算
arm_rfft_fast_init_f32(&S, 256);
arm_rfft_fast_f32(&S, inputAbuf, outputAbuf, 1);
arm_cmplx_mag_f32(outputAbuf, outputA, 256);
说明一下,STM32 DSP库使用的是是stm32f103处理芯片,,CMSIS DSP使用的则是HC32L190芯片,平台不同
|
|