comedi_nscans_left(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… comedi_nscans_left(9)

okay so bestie, this one is from the Kernel API Manual and it's literally about figuring out how many scans you have left in a COMEDI command. no cap. πŸŽ€


✨ NAME ✨

comedi_nscans_left β€” return the number of scans left in the command πŸ¦‹


🌸 SYNOPSIS 🌸

unsigned int comedi_nscans_left (struct comedi_subdevice *s , unsigned
       int nscans );

πŸ’– ARGUMENTS πŸ’–

  • s β€” COMEDI subdevice. the main character we're checking on. πŸ‘‘
  • nscans β€” the expected number of scans, or 0 for all available scans. yes, 0 is the "gimme everything" vibe. ✨

🧚 DESCRIPTION 🧚

so, if nscans is 0, it gets set to the number of scans available in the async buffer. periodt. πŸ’…

and if the async command has a stop_src of TRIG_COUNT, then nscans gets checked against the number of scans remaining to complete the command. like a little vibe check for your scan count. πŸ”₯

the return value is then either the expected number of scans or the number of scans remaining to complete the command β€” whichever is fewer. that's it, that's the whole girlie. 🫢


🌈 SEE ALSO 🌈

kernel file ./drivers/comedi/drivers.c, plus these iconic functions:


mwah πŸ’‹ this lil page is from the Kernel API Manual, sourced from ./drivers/comedi, dated October 2026 β€” comedi_nscans_left(9) out. πŸ’œπŸŒΈ

πŸ“¦ where this page comes from