MrLi... 发表于 2016-9-21 17:25:03

STM32L4 FFT 自带arm_math.h编译不成功

编译提示错误:../Drivers/CMSIS/Include/core_cm4.h(129): error:#35: #error directive: "Compiler generates FPU instructions for a device without an FPU (check __FPU_PRESENT)"

程序如附件

求解,谢谢

MrLi... 发表于 2016-10-9 10:23:21

MrLi... 发表于 2016-9-22 10:59
现在我修改了程序,给FFT的输入buf单独写了个data.c(也还原论坛上有个师兄代码)编译后出现../Drivers/CMSI ...

后来我参照这个帖子修改成功,http://home.eeworld.com.cn/my/space-uid-53362-blogid-255017.html

xmshao 发表于 2016-9-22 08:17:27

本帖最后由 xmshao 于 2016-9-22 08:22 编辑

这里有相关文档可以参考。
https://www.stmcu.org.cn/document/list/index/category-757

Keil中使用STM32F4xx硬件浮点单元             

MrLi... 发表于 2016-9-22 09:14:06

xmshao 发表于 2016-9-22 08:17
这里有相关文档可以参考。
https://www.stmcu.org.cn/document/list/index/category-757



大哥,我在编译器里设置宏定义ARM_MATH_CM4后这个错误不报了
又出现这个错误:
test1\test1.axf: Error: L6218E: Undefined symbol arm_cfft_f32 (referred from main.o).
test1\test1.axf: Error: L6218E: Undefined symbol arm_cfft_sR_f32_len1024 (referred from main.o).
test1\test1.axf: Error: L6218E: Undefined symbol arm_cmplx_mag_f32 (referred from main.o).
test1\test1.axf: Error: L6218E: Undefined symbol arm_max_f32 (referred from main.o).
求解,谢谢

高二毛 发表于 2016-9-22 10:10:02

头文件加载了嘛,math库的

MrLi... 发表于 2016-9-22 10:59:58

高二毛 发表于 2016-9-22 10:10
头文件加载了嘛,math库的
现在我修改了程序,给FFT的输入buf单独写了个data.c(也还原论坛上有个师兄代码)编译后出现../Drivers/CMSIS/Include/core_cm4.h(129): error:#35: #error directive: "Compiler generates FPU instructions for a device without an FPU (check __FPU_PRESENT)"
这个是他的帖子:https://www.stmcu.org.cn/module/forum/forum.php?mod=viewthread&tid=607452&highlight=fft

仰望星期五 发表于 2020-11-23 16:02:58

我也是这情况,搞了很久也没有搞好。
页: [1]
查看完整版本: STM32L4 FFT 自带arm_math.h编译不成功