STRUCT MMA_CHIP_INFO(9)
β¨ struct mma_chip_info(9) β¨
okay so bestie, this is a page straight outta the Kernel API Manual, section 9, and it's all about struct mma_chip_info β literally the glow-up cheat sheet for chip-specific data π«Ά
π NAME π
struct mma_chip_info β chip specific data, no cap π
πΈ SYNOPSIS πΈ
struct mma_chip_info {
const char *name;
u8 chip_id;
const struct iio_chan_spec *channels;
int num_channels;
const int mma_scales[3][2];
int all_events;
int enabled_events;
};
likeβ¦ she's serving struct realness, exactly as written, don't touch a single character π₯
π Members π
nameβ the part number of the device, and it gets reported via the'name'attr. icon behavior tbh βchip_idβ the value sitting in theWHO_AM_Iregister. yes that's the real register name and yes it's iconic πchannelsβ astruct iio_chan_specthat matches whatever the device's capabilities are. vibes matched to hardware fr fr π«num_channelsβ number of channels. that's it, that's the whole job πmma_scalesβ scale factors for converting register values tom/s^2. she's got 3 modes:2g,4g,8g, and 2 integers per mode:m/s^2and microm/s^2. main character energy, three outfits, two numbers each π β¨all_eventsβ all events supported by this chip. every single one, we love a completist πenabled_eventsβ the event flags that are enabled and handled by this driver. the chosen ones π
ngl, if you're writing a driver against this, keep every field exactly as listed β the kernel does not do "close enough" π
π¦ SEE ALSO π¦
- Kernel file
./drivers/iio/accel/mma8452.cβ go read it, it's giving source of truth π
and that's the page bestie, you ate π this lil gem lives in ./drivers/iio/accel, dated October 2026, filed under struct mma_chip_info(9) β slay, periodt πβ¨
π¦ 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