Question
float rounding Cosmic compiler
Posted on May 10, 2012 at 13:01
Dear all,
I have some strange roundings with float values: for example when I write 0.05 in eeprom (calibration parameters) it becomes 0.049999997 when I read It.0.2 becomes 0,199999988.I use Cosmic compiler, I tried to change FLT_DIG in float.h but nothing changes.If someone has a clue please help me.Many thanks in advance #floating-point---just-say-no #stm8-stm8l-float-rounding-cosmic