Re: isl29020: ALS driver as misc device

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

 



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-i2c" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux GPIO]     [Linux SPI]     [Linux Hardward Monitoring]     [LM Sensors]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux