嵌入式学习小组
直播中

李森

7年用户 174经验值
私信 关注

请问如何利用NuMicro®M4系列中的DSP功能进行频谱分析?

利用NuMicro®M4系列中的DSP功能进行频谱分析?

回帖(1)

潘凌

2020-12-7 11:43:46
启用DSP功能:启用DSP功能:启用DSP功能:


  • 启用DSP功能:
  • 详细示例参见以下链接:http://www.nuvoton.com/hq/resource-download.jsp?tp_GUID=EC0120160922110158启用DSP功能:启用DSP功能:
  • 1. 在Keil中,选择目标选项,切换到C/C窗口,然后在“定义文本”字段中输入ARM_MATH_CM4=1。启用DSP功能:

启用DSP功能:
启用DSP功能:
启用DSP功能:
启用DSP功能:http://www.nuvoton.com/hq/resource-download.jsp?tp_GUID=EC0120160922110158


http://www.nuvoton.com/hq/resource-download.jsp?tp_GUID=EC0120160922110158

3. http://www.nuvoton.com/hq/resource-download.jsp?tp_GUID=EC0120160922110158Include arm_math.h to the main function. After that, the DSP library can be called in the main function.
http://www.nuvoton.com/hq/resource-download.jsp?tp_GUID=EC0120160922110158
启用DSP功能:


  • 启用DSP功能:
  • First, the even-numbers in the data format to be calculated are real numbers and the odd-numbers are imaginary numbers, e.g. 1+0.5i, 2+4i, 3+2i=>testinput={1, 0.5, 2, 4, 3, 2}, FFTsize=3.启用DSP功能:
  • Then, call the function arm_cfft_radix4_init_f32(&S, fftSize, ifftFlag, doBitReverse) to do the initial settings for Fast Fourier operation, including the number of operations, the need for fast Fourier or inverse fast Fourier transform.启用DSP功能:
  • Call the function arm_cfft_radix4_f32(&S, testinput) for fast Fourier transform operations, and the results are stored in the array testinput, where the results are complex.启用DSP功能:
  • 计算结果如下。 信号的最强频率可以在1kHz左右。启用DSP功能:
  • 启用DSP功能:

启用DSP功能:The calculation results are shown as follows. The strongest frequency of the signal can be about 1 kHz.
启用DSP功能:
启用DSP功能:http://www.nuvoton.com/hq/resource-download.jsp?tp_GUID=EC0120160922110158

启用DSP功能:
举报

更多回帖

发帖
×
20
完善资料,
赚取积分