[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <4BD5721C.5050909@jic23.retrosnub.co.uk>
Date: Mon, 26 Apr 2010 11:59:40 +0100
From: Jonathan Cameron <kernel@...23.retrosnub.co.uk>
To: Alan Cox <alan@...rguk.ukuu.org.uk>
CC: Greg KH <greg@...ah.com>, Alan Cox <alan@...ux.intel.com>,
linux-i2c@...r.kernel.org, linux-kernel@...r.kernel.org,
"linux-iio@...r.kernel.org" <linux-iio@...r.kernel.org>
Subject: Re: isl29020: ALS driver as misc device
On 04/15/10 12:17, Alan Cox wrote:
>> lux-> illuminance0_input (or I guess lux0_input would also work, I can change
>> the iio abi to match this as well).
>>
>> It also occurs to me that we might want to associate the calibration with the
>> particular channel? There's sure to be a dual ALS chip along at some point.
>>
>> Obviously the isl29020 would need updating as well. Everyone was happy to do
>> that when were writing the ALS subsystem, so I guess that won't have changed!
>
> I'm happy to make the 29020 comply, and I guess it wouldn't take long for
> someone to run over the others. Just let me know what the sysfs interface
> should look like.
Hi Alan,
I was hoping some others would jump in here with suggestions. Failing that, I'd
go with
illuminance0_input (in milli lux?)
(if this requires a float calculation, could go with the iio approach of having
illuminance0_raw and illuminance0_scale, where gain can be a float as it's just
a text string anyway).
illuminance0_range
illuminance0_range_available
For these range, I'd personally prefer to do it via scaling, but we can probably
be flexible here. Things will get complex if we start having ranges like 3...10 lux.
So illuminance0_calibscale (hence internal scale - obviously this will also effect
illuminance0_scale if you are going the 'raw' output and convert in userspace route).
Clearly, you would also need an illuminance0_calibscale_available interface to tell
you what discrete settings exist.
Jonathan
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists