ads131m_adc_read(9)
β¨ ads131m_adc_read(9) β¨
okay so this is a page from the Kernel API Manual, bestie β section 9, ads131m_adc_read(9), and it's literally all about reading channel data and doing CRC vibes. let's get into it π
πΈ NAME πΈ
ads131m_adc_read β reads channel data, and checks the input and output CRCs. that's it, that's the whole job π
π¦ SYNOPSIS π¦
int ads131m_adc_read (struct ads131m_priv *priv , u8 channel , s32 *val
);
like, yes, the formatting is a little unhinged but we respect it π«Ά
π ARGUMENTS π
privβ the device private data structure. your lil device's whole personality lives in here.channelβ the channel number you wanna read, as au8. pick your fave.valβ a pointer where the raw 24-bit value gets stored. it's giving "you bring the bucket, i'll bring the data" πͺ£
π₯ DESCRIPTION π₯
so here's the tea β β this function sends a NULL command (with the Input CRC) to go retrieve data.
then it checks the received STATUS word for any Input CRC errors from the previous command, and after that it verifies the Output CRC of the current data frame. double check energy, no cap. it's checking in and checking out, main character behavior fr fr π
β RETURN β
0 on success, or a negative error code. that's the whole range, bestie β either slay or an error π
π SEE ALSO π
kernel file ./drivers/iio/adc/ti-ads131m02.c
and the whole friend group:
ads131m_tx_frame_unlocked(9)ads131m_rx_frame_unlocked(9)ads131m_check_status_crc_err(9)ads131m_write_reg_unlocked(9)ads131m_read_reg_unlocked(9)ads131m_rmw_reg(9)ads131m_verify_output_crc(9)ads131m_hw_reset(9)ads131m_sw_reset(9)ads131m_reset(9)ads131m_hw_init(9)ads131m_parse_clock(9)
and that's the page!! π§ source/version lives in ./drivers/iio/adc and the date stamp is October 2026 β so yeah, this manpage is literally from the future. iconic. bye bestie, go read some ADCs πππΈ
π¦ 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