COMEDI_TO_PHYSICAL(3)
β¨ NAME β¨
comedi_to_physical β turns a raw sample into actual physical units using polynomials π
πΈ SYNOPSIS πΈ
#include <comedilib.h>
double comedi_to_physical(lsampl_t data,
const comedi_polynomial_t * conversion_polynomial);
π¦ DESCRIPTION π¦
okay so bestie, here's the vibe: this function takes data, which is a Comedi integer sample value (that's an lsampl_t, and it lives somewhere between 0 and maxdata), and converts it into physical units as a double. slay. β¨
The conversion_polynomial argument? You don't just make that up yourself β you get it from either comedi_get_hardcal_converter or comedi_get_softcal_converter. Those are your sources, periodt.
π real talk though: this function does no range checking on the inputdata. none. zero. nada. So if you want to catch possibly out-of-range readings, that's on you β you gotta check for values of0ormaxdatayourself. it's giving "you're the main character here". π
π RETURN VALUE π
The physical value that corresponds to the input sample value. literally just the converted number. π«Ά
π AUTHORS π
- David Schleef
<ds@schleef.org>β Author. - Frank Mori Hess
<fmhess@users.sourceforge.net>β Author. - Herman Bruyninckx
<Herman.Bruyninckx@mech.kuleuven.ac.be>β Author. - Bernd Porr
<tech@linux-usb-daq.co.uk>β Author. - Ian Abbott
<abbotti@mev.co.uk>β Author. - Γric Piel
<piel@delmic.com>β Author.
the icon lineup fr fr π₯
π COPYRIGHT π
Copyright Β© 1998-2003 David Schleef
Copyright Β© 2001-2003, 2005, 2008 Frank Mori Hess
Copyright Β© 2002-2003 Herman Bruyninckx
Copyright Β© 2012 Bernd Porr
Copyright Β© 2012 Ian Abbott
Copyright Β© 2012, 2015 Γric Piel
This document is part of Comedilib. And just so we're clear β in the context of this document, the term "source code" as defined by the license means the XML source. iykyk. π
This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, version 2.1 of the License. β¨
This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
π§ that's the whole page bestie, no notes π
Comedi Β· version stamp 03/20/2026 Β· this was COMEDI_TO_PHYSICAL(3) and she ate, ngl πππ
π¦ where this page comes from
- ubuntu resolute: libcomedi-dev 0.11.0+5-1.3build6 Β· LGPL-2.1-only
- ubuntu stonking: libcomedi-dev 0.11.0+5-1.3build6 Β· LGPL-2.1-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms