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:
Uwe Hermann 2017-05-21 16:34:41 +02:00
parent 16a1d50a63
commit 2b17aeb874
1 changed files with 1 additions and 1 deletions

View File

@ -116,7 +116,7 @@ static int parse_range(const uint8_t *buf, float *floatval, int *exponent)
/* Apply respective exponent (mode-dependent) on the value. */
*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;
}