Float to ASCII without printf

hutchia's picture
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Type: 

Compiler/Assembler: 

Generic C routine that will output ASCII reprentation of floating point value in either fixed (123.456) or Scientific notation (1.23456E2). Precision (number of digits) can be changed.

Does not use printf, a buffer or huge amounts of stack space.

V2 - correct bug that omitted (wrong) leading zeros

Attachment(s):