zephyr/include
Vlad Dogaru d1c7c7b7ef Introduce new sensor API
Sensor drivers expose one or more channels, corresponding to each
individual quantity they can measure.  Such quantities may be different
altogether (e.g. temperature and pressure) or different axes for the
same unit (e.g. three axes of acceleration).  Before reading channels, a
driver must be explicitly instructed to obtain a sample from the device.
This helps accommodate sensors which can only read all channels at once,
and also helps ensure coherence of measurements and optimize I2C/SPI
traffic.

Channels can be read as floating point values or struct sensor_value.
The latter consists of a pair of integers and a type field which
dictates how to interpret said integers.  The most common type is INT
(where the second value is ignored) or INT_PLUS_MICRO, which means the
second value should be multiplied by 1.0e-6 and added to the first.

A sensor driver may support one or more triggers, corresponding to
interrupts or timers.  Registering for a trigger involves supplying the
driver with a callback which is called when a condition is reached.
Examples of trigger types are: data ready, timer expiration, any-motion,
near/far.

Finally, sensors support attributes such as sample frequency,
measurement accuracy or threshold values for triggers.  However, runtime
configuration is discouraged, in the interest of keeping code simple.

Origin: Original
Change-Id: Id290fe544b6f7eccc4b109f3912fca1692e55623
Signed-off-by: Vlad Dogaru <vlad.dogaru@intel.com>
2016-03-15 18:59:47 +00:00
..
arch arch: arm: move nmi to common location 2016-03-12 03:20:36 +00:00
bluetooth Bluetooth: Add support for outgoing BR/EDR connections 2016-03-14 11:37:11 +00:00
display c++: Add extern "C" { } block to header files 2016-02-05 20:25:22 -05:00
drivers arm: K64 SPI module driver 2016-03-09 15:50:16 +00:00
microkernel debug: add debug tracing support for task initialization 2016-03-11 22:13:30 +00:00
misc debug: add debug tracing support for task initialization 2016-03-11 22:13:30 +00:00
net net: User must provide storage for local IP address 2016-03-14 11:05:52 +00:00
toolchain include: Remove UNALIGNED_READ & UNALIGNED_WRITE 2016-03-04 20:11:57 +00:00
adc.h struct packing 2016-02-10 16:21:26 +00:00
aio_comparator.h c++: Add extern "C" { } block to header files 2016-02-05 20:25:22 -05:00
atomic.h Change BSD-3 licenses to Apache 2 2016-02-05 20:24:29 -05:00
cache.h cache: add implementation for cache-less systems 2016-02-05 20:25:24 -05:00
clock_control.h clock: add Quark SE clock control 2016-02-05 20:24:48 -05:00
device.h docs: doxygen: group driver APIs 2016-02-16 06:16:47 +00:00
flash.h flash: Use off_t for offset parameters 2016-03-11 01:09:56 +00:00
gpio.h gpio: clarify API doc 2016-02-18 18:25:50 +00:00
i2c.h i2c: clarify API doc 2016-02-18 17:54:03 +00:00
init.h init: add SYS_INIT() 2016-02-05 20:25:25 -05:00
ipm.h ipm: correct prototype for ipm_send 2016-03-09 06:31:02 +00:00
irq_offload.h doc: Fix misuse of @file doxygen tag 2016-02-11 20:11:03 +00:00
irq.h irq: formalize external zephyr interrupt API 2016-02-26 15:53:22 +00:00
kernel_version.h c++: Add extern "C" { } block to header files 2016-02-05 20:25:22 -05:00
linker-defs.h init: Add protection against incorrect levels or priorities 2016-02-05 20:24:54 -05:00
linker-tool-gcc.h Fixed file description and applied doxygen style 2016-02-05 20:24:58 -05:00
linker-tool.h Fixed file description and applied doxygen style 2016-02-05 20:24:58 -05:00
microkernel.h c++: Add extern "C" { } block to header files 2016-02-05 20:25:22 -05:00
nanokernel.h debug: adds object tracing capability to nano stack 2016-03-11 22:12:26 +00:00
pinmux.h pinmux: Expand the pin function/mode parameter size 2016-03-09 06:39:16 +00:00
pwm.h pwm: add 'set_phase' API 2016-03-09 15:46:58 +00:00
rtc.h c++: Add extern "C" { } block to header files 2016-02-05 20:25:22 -05:00
section_tags.h ARM: ARC: put sw_isr_table in ROM by default 2016-02-05 20:25:21 -05:00
sections.h ARM: ARC: put sw_isr_table in ROM by default 2016-02-05 20:25:21 -05:00
sensor.h Introduce new sensor API 2016-03-15 18:59:47 +00:00
shared_irq.h c++: Add extern "C" { } block to header files 2016-02-05 20:25:22 -05:00
spi.h arm: K64 SPI module driver 2016-03-09 15:50:16 +00:00
sw_isr_table.h irq: fix declared _sw_isr_table size on ARC 2016-02-05 20:25:25 -05:00
sys_clock.h c++: Add extern "C" { } block to header files 2016-02-05 20:25:22 -05:00
sys_io.h sys_io: don't allow negative bit offsets 2016-03-04 16:26:21 +00:00
toolchain.h Fixed file description and applied doxygen style 2016-02-05 20:24:58 -05:00
uart.h uart: add ISR callback mechanism for UART drivers 2016-03-05 13:37:57 +00:00
watchdog.h c++: Add extern "C" { } block to header files 2016-02-05 20:25:22 -05:00
zephyr.h sysgen: generate sysgen.h instead of zephyr.h 2016-02-05 20:24:35 -05:00