Re: [RFC/PATCH] iio: light: add support for TI's opt3001 ligth sensor

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

 



> > > > > +		.scan_type = {
> > > > > +			.sign = 'u',
> > > > 
> > > > .realbits / .storagebits missing?
> > > 
> > > yeah, couldn't figure this out. The HW gives me a 16-bit value where
> > > 12-bits are the mantissa and 4-bits are for the exponent. Should I call
> > > realbits 16 and storagebits 32 ?
> > 
> > so .realbits = 16 and .storagebits = 16, but there is no way to describe 
> > the mantissa/exponent thing to userspace
> > 
> > you are not using iio_triggered_buffer_setup() yet, so no need for 
> > .scan_type (yet)
> 
> ok... but then that brings up a doubt. What would I use triggered buffer
> for ? I already setup High/Low limits (thresholds) through
> .write_event_value(). Isn't that, pretty much, a triggered buffer ?

a triggered buffer reads data from the device and stores it into a buffer 
whenever the trigger goes off (you are interested to capture all samples)

events are created on certain conditions (you are not interested in all 
samples)

p.

-- 

Peter Meerwald
+43-664-2444418 (mobile)
--
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