STRUCT ST_SENSOR_SETTINGS(9)
π struct st_sensor_settings(9) β the Kernel API Manual, bestie edition π
okay so. this is a page straight out of the Kernel API Manual, section 9, and it's all about struct st_sensor_settings β which is, like, literally the ST-specific sensor settings struct. it's the main character of every ST sensor driver's config, no cap. π¦
β¨ NAME β¨
struct st_sensor_settings β ST specific sensor settings. that's it, that's the vibe. it's giving "one struct to hold every knob your ST sensor has." π
πΈ SYNOPSIS πΈ
here's the whole thing, character for character, because we do NOT paraphrase code in this house:
struct st_sensor_settings {
u8 wai;
u8 wai_addr;
char sensors_supported[ST_SENSORS_MAX_4WAI][ST_SENSORS_MAX_NAME];
struct iio_chan_spec *ch;
int num_ch;
struct st_sensor_odr odr;
struct st_sensor_power pw;
struct st_sensor_axis enable_axis;
struct st_sensor_fullscale fs;
struct st_sensor_bdu bdu;
struct st_sensor_das das;
struct st_sensor_data_ready_irq drdy_irq;
struct st_sensor_sim sim;
bool multi_read_bit;
unsigned int bootime;
};
likeβ¦ look at her. so organized. so structured (literally). π₯
π Members π
let's go through every single one, bestie, because every field matters:
waiβ contents of the WhoAmI register. yes it's really called that. yes it's as iconic as it sounds. πwai_addrβ the address of the WhoAmI register. gotta know where the identity crisis lives. πsensors_supportedβ list of supported sensors by struct itself. it's achararray of size[ST_SENSORS_MAX_4WAI][ST_SENSORS_MAX_NAME], so it's holding a whole roster of besties. π«Άchβ IIO channels for the sensor. this one's astruct iio_chan_spec *. πnum_chβ number of IIO channels inch. it's anint, and it's literally counting your channels for you. βodrβ output data rate register and ODR list available.struct st_sensor_odr. fast, slow, she does it all. π₯pwβ power register of the sensor.struct st_sensor_power. self-care = power management, periodt. πenable_axisβ enable one or more axis of the sensor. that'sstruct st_sensor_axis, and yes you can turn on multiple axes, she's flexible like that. πfsβ full scale register and full scale list available.struct st_sensor_fullscale. go big or go home. β¨bduβ block data update register.struct st_sensor_bdu. tiny name, important job. πdasβ Data Alignment Selection register.struct st_sensor_das. capital letters because she's fancy. πdrdy_irqβ data ready register of the sensor.struct st_sensor_data_ready_irqβ she's ready when you are. πsimβ SPI serial interface mode register of the sensor.struct st_sensor_sim. π§multi_read_bitβ use or not particular bit for [I2C/SPI] multi-read. it's abool, so it's a yes/no vibe check. π¦bootimeβ samples to discard when sensor passing from power-down to power-up. anunsigned int. like, you gotta let her wake up first, give her a minute π
ngl bootime is such a mood β "samples to discard when sensor passing from power-down to power-up" is basically me for the first 20 minutes after a nap. π
π SEE ALSO π
go read these next, fr fr β they're all in the kernel file ./include/linux/iio/common/st_sensors.h:
struct st_sensor_bdu(9)struct st_sensor_das(9)struct st_sensor_int_drdy(9)struct st_sensor_data_ready_irq(9)struct st_sensor_data(9)
and like, the whole struct family lives under struct st_sensor_settings in that header, so it's giving big friend-group energy. π«Ά
that's the whole page, bestie, you ate that. π and for the cute sign-off: this came from ./include/linux/iio/common, dated October 2026, and it's the manpage for struct st_sensor_settings(9). slay, go configure some sensors. π
β¨
π¦ 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