ad4695_set_s...e_cycle_mode(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… ad4695_set_single_cycle_mode πŸ’…

okay bestie, welcome to the ad4695_set_single_cycle_mode page from the Kernel API Manual β€” yes the header up top is all abbrev-y and dramatic (ad4695_set_s...e_cycle_mode(9)), but the actual function name is the full one and we're gonna say it with our whole chest ✨


🌸 NAME 🌸

ad4695_set_single_cycle_mode β€” literally just sets the device into single cycle mode. that's the whole vibe. πŸŽ€


πŸ¦‹ SYNOPSIS πŸ¦‹

int ad4695_set_single_cycle_mode (struct ad4695_state *st , unsigned int channel );

like. it takes your state and a channel and hands you back an int. no cap. πŸ’…


πŸ“ ARGUMENTS πŸ“

  • st β€” the AD4695 state, aka the main character struct of this whole operation πŸ‘‘
  • channel β€” the first channel to read, the one that goes first, the opener, the lead singer 🎀

⭐ DESCRIPTION ⭐

so here's the tea, straight from the datasheet β˜• to turn on single cycle mode you gotta set:

  • STD_SEQ_EN=0
  • NUM_SLOTS_AS=0
  • CYC_CTRL=1

…and yeah, that's literally Table 15 in the datasheet, iykyk πŸ“–

then, once you set SPI_MODE=1, it triggers the first conversion using the channel that's sitting in AS_SLOT0. so AS_SLOT0 is basically the first one up, main character energy fr fr πŸ”₯


🧚 CONTEXT 🧚

  • it can sleep 😴 (so don't you dare call it from somewhere spicy)
  • it must be called with iio_device_claim_direct held β€” non-negotiable bestie, that's the rule 🫢

πŸ’œ RETURN πŸ’œ

  • 0 on success β€” slay, ate, no notes ✨
  • a negative error code on failure β€” πŸ’€ happens to the best of us

🌈 SEE ALSO 🌈


ok that's the whole page bestie, go forth and enable your single cycle mode responsibly πŸ’–

and for the cute sign-off: this lil masterpiece lives in ./drivers/iio/adc, dated October 2026, and answers to ad4695_set_s...e_cycle_mode(9) πŸŽ€βœ¨πŸ¦‹

πŸ“¦ where this page comes from