Skip to content
Snippets Groups Projects
Commit 74353ceb authored by Vasileios Amoiridis's avatar Vasileios Amoiridis Committed by Jonathan Cameron
Browse files

iio: pressure: bmp280: Generalize read_*() functions


Add the coefficients for the IIO standard units and the IIO value
inside the chip_info structure.

Move the calculations for the IIO unit compatibility from inside the
read_{temp,press,humid}() functions and move them to the general
read_raw() function.

In this way, all the data for the calculation of the value are
located in the chip_info structure of the respective sensor.

Signed-off-by: default avatarVasileios Amoiridis <vassilisamir@gmail.com>
Acked-by: default avatarAdam Rizkalla <ajarizzo@gmail.com>
Link: https://patch.msgid.link/20240628171726.124852-2-vassilisamir@gmail.com


Signed-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
parent 7c7d9170
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment