nuttx/Documentation/components/drivers/special
Justin Hammond 769862ac6a sensors/tmp112: Add a uORB interface.
The TMP112 driver was character mode only, and carried the warning that
says so: a read returns a bare float, at a size the driver chose, and
nothing but code written for this one part can make sense of it.

Add the sensor framework version beside it, in the shape the tree
already uses for a part that has both.  The old driver is untouched and
still builds by default; the new one replaces it when
SENSORS_TMP112_UORB is set, and the part then appears as a temperature
topic that the common sensor tools can read without knowing what a
TMP112 is.

It reads on the low priority work queue at whatever interval the caller
asks for.  The part converts continuously out of reset, so nothing is
configured and the temperature register always holds the last completed
conversion: a reading is one bus transaction with nothing to wait for.
Reading faster than the part converts repeats a value, which costs bus
traffic and nothing else, so the interval is taken as given: the upper
half treats a lower half that hands back a longer interval than it was
given as a failed request, so clamping here would refuse a fast caller
rather than serve it slowly.

get_info reports what the part is and what its readings mean, so a
consumer need not know it is talking to a TMP112 to know the range and
the resolution.

It also sign extends the reading.  The register holds twelve bits, and
the character mode driver treats them as unsigned, so anything below
freezing comes back as a large positive temperature; the part is
specified down to -40C.  Fixing that in the old driver would change what
existing callers see, so it is fixed here, where there are no callers
yet to surprise.

This driver also covers the TMP102, which differs in accuracy rather
than in its registers: only the two both parts have are touched.

Documented under the sensors section, beside the other parts with a page
of their own, and listed among the uORB drivers.

Assisted-by: Claude:claude-opus-5
Signed-off-by: Justin Hammond <justin@dynam.ac>
2026-08-18 10:35:28 -03:00
..
image docs/syslog: add syslog configuration options documentation 2026-02-27 08:09:31 -03:00
mtd Documentation: add pages for supported MTD devices 2025-12-31 11:37:49 +08:00
net net/vlan: add some macro for vlan 2025-12-27 11:36:39 +08:00
pci drivers/net: add IGB network card support 2025-07-08 10:02:15 +02:00
power drivers/power: Describe the regulators through procfs. 2026-08-18 17:28:02 +08:00
rpmsg Documentation/rpmsg: add rpmsg dump documentation 2026-01-30 07:50:11 -03:00
rptun Documents/rptun: add the new rptun framework documents 2026-01-19 14:18:27 +08:00
sensors sensors/tmp112: Add a uORB interface. 2026-08-18 10:35:28 -03:00
vhost Documentation/vhost: add Vhost framework documentation 2026-02-04 02:32:02 +08:00
virtio Documentation/virtio: add VirtIO framework documentation 2026-01-28 13:09:19 -03:00
wireless Documentation: Add documentation for RN2XX3 driver 2025-03-06 06:10:19 -03:00
audio.rst docs/audio_tone: Add documentation about the audio tone driver 2026-07-13 09:42:26 +08:00
clk.rst Documentation: add dummy pages for missing filesystems and drivers 2023-10-27 13:21:40 -03:00
devfreq.rst sim/thermal: Exercise the devfreq cooling path. 2026-08-18 09:46:47 -03:00
devicetree.rst Documentation: add dummy pages for missing filesystems and drivers 2023-10-27 13:21:40 -03:00
devmem.rst driver/mem:add Mem Driver. 2024-08-28 13:59:04 +08:00
dma.rst Documentation: add dummy pages for missing filesystems and drivers 2023-10-27 13:21:40 -03:00
framebuffer.rst
i2c.rst Documentation: Add I2C bit-bang IO expander driver documentation 2026-01-01 17:08:47 +08:00
i3c.rst drivers/i3c: update i3c driver documentation 2024-09-24 23:36:50 +08:00
index.rst Documentation: add devfreq framework documentation 2026-08-08 15:23:54 -03:00
ioexpander.rst documentation: mention PIO4IOE IO Expander 2026-07-28 10:18:01 +08:00
lcd.rst !arch/stm32: move stm32l1 and finalize the directory split 2026-06-24 14:54:44 -03:00
mmcsd.rst drivers/mmcsd: Switch SD cards into high speed. 2026-08-18 09:38:45 +08:00
pinctrl.rst driver/pinctl: add pinctrl framework 2024-09-17 02:25:47 +08:00
pipes.rst Documentation: add dummy pages for missing filesystems and drivers 2023-10-27 13:21:40 -03:00
ptp.rst Documentation: Add PTP clock driver framework documentation 2025-12-30 10:22:09 -03:00
regmap.rst
reset.rst Documentation: add dummy pages for missing filesystems and drivers 2023-10-27 13:21:40 -03:00
rwbuffer.rst
sdio.rst drivers/mmcsd: Switch SD cards into high speed. 2026-08-18 09:38:45 +08:00
segger.rst style: Fix "the the" typo across the codebase. 2026-03-23 11:07:49 +01:00
sensors.rst sensors/tmp112: Add a uORB interface. 2026-08-18 10:35:28 -03:00
spi.rst
syslog.rst include/debug.h: Move to include/nuttx/debug.h 2026-04-07 07:50:06 -03:00
sysview.png Documentation: add segger sysview heap trace example 2024-10-07 17:34:59 +08:00
usbdev.rst !arch/stm32: move stm32l1 and finalize the directory split 2026-06-24 14:54:44 -03:00
usbhost.rst !arch/stm32: move stm32l1 and finalize the directory split 2026-06-24 14:54:44 -03:00
usbmisc.rst Documentation: add dummy pages for missing filesystems and drivers 2023-10-27 13:21:40 -03:00
usbmonitor.rst style: fix typos 2025-04-30 13:45:46 +08:00
usbmonitor_wireshark_linux_example_adb.pcapng Documentation: Add usage of Wireshark for USB monitor 2025-01-22 15:17:38 +08:00
usbmonitor_wireshark_linux_example_adb.png Documentation: Add usage of Wireshark for USB monitor 2025-01-22 15:17:38 +08:00
usrsock.rst Documentation: add dummy pages for missing filesystems and drivers 2023-10-27 13:21:40 -03:00
uvc.rst drivers/usbdev: add UVC gadget class driver 2026-03-29 12:35:22 -03:00
video.rst Documentation: add dummy pages for missing filesystems and drivers 2023-10-27 13:21:40 -03:00
wireless.rst Documentation: Add documentation for RN2XX3 driver 2025-03-06 06:10:19 -03:00