ut71x: Fix float printing issue in a debug message.
Old: ut71x: Applying exponent -12, new value is 0.000000. P1: 1.500 nF AUTO P1: 1.500 nF AUTO New: ut71x: Applying exponent -12, new value is 1.5e-09. P1: 1.500 nF AUTO P1: 1.500 nF AUTO This fixes bug #700.
This commit is contained in:
parent
16a1d50a63
commit
2b17aeb874
|
@ -116,7 +116,7 @@ static int parse_range(const uint8_t *buf, float *floatval, int *exponent)
|
||||||
|
|
||||||
/* Apply respective exponent (mode-dependent) on the value. */
|
/* Apply respective exponent (mode-dependent) on the value. */
|
||||||
*floatval *= powf(10, *exponent);
|
*floatval *= powf(10, *exponent);
|
||||||
sr_dbg("Applying exponent %d, new value is %f.", *exponent, *floatval);
|
sr_dbg("Applying exponent %d, new value is %g.", *exponent, *floatval);
|
||||||
|
|
||||||
return SR_OK;
|
return SR_OK;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue