2415030_en-US

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

2415030_en-US

2415030_en-US

S32K3 Floating point cfg

Hello Team,

In my project, i am trying to do arithmetic operation using float data, but calculation is not happening as expected.

#define macro -31.374

when i try to print in macro value using UTILS PRINTF, i am getting -32.374, similarly for other values, value get incremented by 1.

Because of this, my calculations not happening as expected.

Is there any cfg i need to do for this? 

My current target setting

nirmal_masilamani_0-1790009448678.pngnirmal_masilamani_0-1790009448678.pngnirmal_masilamani_0-1790009448678.png


Re: S32K3 Floating point cfg

Hi @nirmal_masilamani 

Could you please clarify what you mean by "UTILS PRINTF"?

How are you performing the calculations? Are the results stored in a float variable? If yes, does the variable already contain the wrong value when viewed in the debugger, or is the issue only observed when printing it?


BR, VaneB

Re: S32K3 Floating point cfg

Hello @VaneB ,

Thank you for your support, yes issue was in PRINTF function, while debugging i was able to read the proper data.


タグ(1)
評価なし
バージョン履歴
最終更新日:
水曜日
更新者: