浏览代码

Merge pull request #90 from FrankBoesing/patch-4

use float version of fcvt
teensy4-core
Paul Stoffregen 9 年前
父节点
当前提交
1e1b43ca7d
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. +1
    -1
      teensy3/nonstd.c

+ 1
- 1
teensy3/nonstd.c 查看文件

@@ -72,7 +72,7 @@ char * dtostrf(float val, int width, unsigned int precision, char *buf)
const char *s, *e;
char *p;

s = fcvt(val, precision, &decpt, &sign);
s = fcvtf(val, precision, &decpt, &sign);
if (precision == 0 && decpt == 0) {
s = (*s < '5') ? "0" : "1";
reqd = 1;

正在加载...
取消
保存