It seems like I have lost the ability to use printf with floating point values (I could have sworn it was working before). I read in other posts that compiler optimizations causes printf to only support integers by default.
In the output, any floating point values are replaced by the character 'f'.
float pi = 3.14; printf("pi = %f", pi);
results in the output:
pi = f
In Toolchain -> ARM/GNU Linker -> General:
- Use size optimized library (--specs=nano.specs) is not selected.
In Toolchain -> ARM/GNU C Compiler -> Symbols:
- "printf=iprintf" is present
- "scanf=iscanf" is present
What are the correct options to enable floats? There are multiple forum posts here with different recommendations. It would seem this should be a common issue with an Atmel App Note standard solution.