AnsweredAssumed Answered

Float value printing issue in PE

Question asked by syed idris on Aug 30, 2016
Latest reply on Aug 31, 2016 by syed idris

I know this issue is already discussed in another questions, but when I follow the steps to get float value I am unable to get that.
using KDS3.1.0 + PE

chip: KL03


there is nothing special in my code I am just writing


PRINTF("\r\n %f",1.234);


and it is giving me output as: f


I got two solutions after reading previous questions.

  • SOLUTION-1: Adding symbol for float in Cross ARM C Compiler>>Preprocessor

After adding this "PRINTF_FLOAT_ENABLE" symbol when I build my code, it is showing error as follows


  • SOLUTION-2: checking for "-u_printf_float" in Cross ARM C++ Linker>>Miscellaneous

It is printing the output as 'f' only.


I am also attaching here my project file, 

why the float value is not getting printed?

Original Attachment has been moved to: