Re: [PATCH] iio: adc: nau7802: Expose possible gains in sysfs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, May 18, 2016 at 6:16 PM, Quentin Schulz
<quentin.schulz@xxxxxxxxxxxxxxxxxx> wrote:
> The Nuvoton NAU7802 ADC is able to adjust its gain but prior knowledge of
> its possible values was required to adjust it. Users had to guess the
> possible gain values based on the ADC datasheet or on this driver's code.
>
> This exposes the possible values in the in_voltage_scale_available file of
> each nau7802 ADC device. The gain is set for the whole ADC and is therefore
> not configurable by channel. Thus, there exists only one
> in_voltage_scale_available file for each nau7802 ADC device even if it has
> two separate channels.
>
> Signed-off-by: Quentin Schulz <quentin.schulz@xxxxxxxxxxxxxxxxxx>
> ---
>
> There exists two files to set the gain: in_voltageX_scale_available and
> in_voltage-voltage_scale_available. What are the differences between those
> two? What are the use cases for each? Which one should I have used?

First is for single channels while the latter is for differential channels.
In this case it's correct to use in in_voltageX_scale_available as you did.

thanks,
Daniel.
--
To unsubscribe from this list: send the line "unsubscribe linux-iio" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux