mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-26 19:00:25 +00:00
![Matti Vaittinen](/assets/img/avatar_default.png)
Some light sensors can adjust both the HW-gain and integration time. There are cases where adjusting the integration time has similar impact to the scale of the reported values as gain setting has. IIO users do typically expect to handle scale by a single writable 'scale' entry. Driver should then adjust the gain/time accordingly. It however is difficult for a driver to know whether it should change gain or integration time to meet the requested scale. Usually it is preferred to have longer integration time which usually improves accuracy, but there may be use-cases where long measurement times can be an issue. Thus it can be preferable to allow also changing the integration time - but mitigate the scale impact by also changing the gain underneath. Eg, if integration time change doubles the measured values, the driver can reduce the HW-gain to half. The theory of the computations of gain-time-scale is simple. However, some people (undersigned) got that implemented wrong for more than once. Add some gain-time-scale helpers in order to not dublicate errors in all drivers needing these computations. Signed-off-by: Matti Vaittinen <mazziesaccount@gmail.com> Link: https://lore.kernel.org/r/268d418e7cffcdaa2ece6738478bbc57692c213e.1680263956.git.mazziesaccount@gmail.com Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
46 lines
1.1 KiB
Makefile
46 lines
1.1 KiB
Makefile
# SPDX-License-Identifier: GPL-2.0
|
|
#
|
|
# Makefile for the industrial I/O core.
|
|
#
|
|
|
|
obj-$(CONFIG_IIO) += industrialio.o
|
|
industrialio-y := industrialio-core.o industrialio-event.o inkern.o
|
|
industrialio-$(CONFIG_IIO_BUFFER) += industrialio-buffer.o
|
|
industrialio-$(CONFIG_IIO_TRIGGER) += industrialio-trigger.o
|
|
|
|
obj-$(CONFIG_IIO_CONFIGFS) += industrialio-configfs.o
|
|
obj-$(CONFIG_IIO_GTS_HELPER) += industrialio-gts-helper.o
|
|
obj-$(CONFIG_IIO_SW_DEVICE) += industrialio-sw-device.o
|
|
obj-$(CONFIG_IIO_SW_TRIGGER) += industrialio-sw-trigger.o
|
|
obj-$(CONFIG_IIO_TRIGGERED_EVENT) += industrialio-triggered-event.o
|
|
|
|
obj-y += accel/
|
|
obj-y += adc/
|
|
obj-y += addac/
|
|
obj-y += afe/
|
|
obj-y += amplifiers/
|
|
obj-y += buffer/
|
|
obj-y += cdc/
|
|
obj-y += chemical/
|
|
obj-y += common/
|
|
obj-y += dac/
|
|
obj-y += dummy/
|
|
obj-y += gyro/
|
|
obj-y += filter/
|
|
obj-y += frequency/
|
|
obj-y += health/
|
|
obj-y += humidity/
|
|
obj-y += imu/
|
|
obj-y += light/
|
|
obj-y += magnetometer/
|
|
obj-y += multiplexer/
|
|
obj-y += orientation/
|
|
obj-y += position/
|
|
obj-y += potentiometer/
|
|
obj-y += potentiostat/
|
|
obj-y += pressure/
|
|
obj-y += proximity/
|
|
obj-y += resolver/
|
|
obj-y += temperature/
|
|
obj-y += test/
|
|
obj-y += trigger/
|