diff --git a/adi/ad7606.py b/adi/ad7606.py index 376a1bfc7..a19043627 100644 --- a/adi/ad7606.py +++ b/adi/ad7606.py @@ -129,6 +129,12 @@ def to_volts(self, index, val): """Converts raw value to SI""" _scale = self.channel[index].scale + if isinstance(val, int): + return val * _scale + + if isinstance(val, list): + return [x * _scale for x in val] + # ADC7606C-18 will return int32 samples from the driver if isinstance(val, np.int32): return val * _scale