adis_single_conversion(9)
π NAME π
Okay so this is the adis_single_conversion(9) page from the Kernel API Manual, and bestie it performs a single sample conversion β¨
πΈ SYNOPSIS πΈ
int adis_single_conversion (struct iio_dev *indio_dev , const struct iio_chan_spec *chan , unsigned int error_mask , int *val );
π ARGUMENTS π
indio_devβ The IIO device, aka the main character of this call πchanβ The IIO channel, the one weβre converting from π¦error_maskβ Mask for the error bit; yes, itβs doing a vibe check on the raw valuevalβ Result of the conversion; it lives here after the call π«Ά
π¦ DESCRIPTION π¦
Returns IIO_VAL_INT on success, a negative error code otherwise. Thatβs the return vibe, periodt.
The function performs a single conversion on a given channel and post processes the value accordingly to the channel spec. Like, it grabs one sample and makes it make sense for that channel.
If an error_mask is given, the function will check if the mask is set in the returned raw value. If it is set, the function will perform a self-check. And if the device does not report a error bit in the channelβs raw value, set error_mask to 0. That part is important, iykyk.
π Real talk: if the device does not report a error bit in the channelβs raw value, seterror_maskto0. Donβt skip that little detail.
π SEE ALSO π
Kernel file ./drivers/iio/imu/adis.c, plus these legendary references:
__adis_write_reg(9)__adis_read_reg(9)__adis_update_bits_base(9)__adis_enable_irq(9)__adis_check_status(9)__adis_reset(9)__adis_initial_startup(9)adis_init(9)
And thatβs the whole page, bestie π«Ά source/version is ./drivers/iio/imu, dated October 2026 β slay, stay hydrated, and go read those SEE ALSOs β¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms