Thread (1 message) 1 message, 1 author, 2017-01-15

Re: [PATCH v4 0/2] iio: adc: Add Maxim MAX11100 driver

From: Marek Vasut <hidden>
Date: 2017-01-15 15:41:50
Also in: linux-iio, linux-renesas-soc

On 01/15/2017 03:31 PM, Jonathan Cameron wrote:
On 15/01/17 14:13, jacopo mondi wrote:
quoted
Hi Jonathan,
   thanks for review,

On 13/01/2017 10:50, Jacopo Mondi wrote:
quoted
Hello,
   sending out v4 splitting device tree bindings documentation and actual ADC
driver.
No changes in driver code since v3.

Same question for iio maintainers here:
I would like to have clarified the measure unit returned by read_raw().
Currently (value_raw * value_scale) return the ADC input value in mV.
Good.
quoted
quoted
While testing the patch I've been questioned if that should not actually
be in uV. This is easily achievable making _scale return a value in uV.
I have found no mention of this in the ABI documentation as it speaks of
generic voltage. Can we have a final word on this?
I see you have reviewed the driver without complaining for the
read_raw() measure unit, so I assume this replies to the above
question as well...
The units are specified in Documentation/ABI/testing/sysfs-bus-iio.
quoted
What:		/sys/bus/iio/devices/iio:deviceX/in_voltageY_raw
What:		/sys/bus/iio/devices/iio:deviceX/in_voltageY_supply_raw
What:		/sys/bus/iio/devices/iio:deviceX/in_voltageY_i_raw
What:		/sys/bus/iio/devices/iio:deviceX/in_voltageY_q_raw
KernelVersion:	2.6.35
Contact:	linux-iio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Description:
		Raw (unscaled no bias removal etc.) voltage measurement from
		channel Y. In special cases where the channel does not
		correspond to externally available input one of the named
		versions may be used. The number must always be specified and
		unique to allow association with event codes. Units after
		application of scale and offset are millivolts.
So millivolts.  This comes from a, perhaps ill judged, decision to match
hwmon units were we could.
Fun, regulator framework returns values in uV to add to the chaos :)


-- 
Best regards,
Marek Vasut
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help