How to set FPU rounding mode of cortex M7 (IM.x RT) ?

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

How to set FPU rounding mode of cortex M7 (IM.x RT) ?

1,072 次查看
_ThomasLorenz_
Contributor II

Hi

The is fenv.h and  fesetround() but I suppose it is only only available in c++.

How to set the FPU mode in a C project?

 

error: 'FE_TOWARDZERO' undeclared (first use in this function)

171 | fesetround(FE_TOWARDZERO);
| ^~~~~~~~~~~~~
*.c:171:14: note: each undeclared identifier is reported only once for each function it appears in

 

Regrads

Thomas

0 项奖励
回复
1 回复

1,044 次查看
Omar_Anguiano
NXP TechSupport
NXP TechSupport

Hello
I hope you are well.

Please refer to this documentation on how to handle these functions: ARM Compiler ARM C and C++ Libraries and Floating-Point Support User Guide Version 5.05

If you have more questions do not hesitate to ask me.
Best regards,
Omar

0 项奖励
回复