Hello,
In my program I have the Following definitions:
extern void TERMIO_Init(void){cdc_init();} extern void TERMIO_PutChar(UINT8 ch){cdc_write(ch);}
The printf function works well for variables char, int, long. Using% u,% x.
But float variables does not work. to write% f, prints numbers not close to being thenumber that is stored in RAM.
What should be done so that you can print data float?
Hello
Which processor are you targeting (HC08, HC12, Coldfire v1, Coldfire v2, ...)?
For some processor the delivered library do not provide full support for printf function in order to minimize footprint.
If you are using HC08 or HC12 MCU, you can add support for floating point number in printf setting
LIBDEF_PRINTF_FLOATING to 1 in libdefs.h. This file is located in the library include folder.
After you changed that you will need to re-build the ANSI library.
CrasyCat