The comedi module uses the comedi library to interface with various I/O cards (almost 250 as of this writing, from various manufacturers). The library (but not the module) was written by the comedi project.
In comedi, the inputs and outputs on each device (card) are grouped into subdevices. Each input or output is then referred to as a channel. All three of these (devices, subdevices and channels) are numbered, starting from 0. In addition, analogue channels can have multiple ranges and references, if the card supports these, and they can be obtained raw (as an integer) or converted to physical units (volts or milliamps).
In the mapping table, comedi addresses are specified as follows:
Each address has the form (some parts optional):
device: type subdevice.channel options
This diagram shows which parts are optional, which are mandatory, and the order in which they may be used. To make a valid address, start in the double circle labelled S, and follow the arrows until you get to E. Boxes denote actual letters and punctuation to use, ovals the various settings, as explained below. The small circles are simply junctions.
/dev/comedi" will be prepended in the latter case). The device specification may be omitted, including the colon, in which case 0 will be used.
O(so they don't get mistaken for numbers). The floating-point format used by the
Ytypes is the same as used by the DSP module.
|analog input (raw) (mnemonic: iN)||1-32||integer|
|analog output (raw) (mnemonic: oUt)||1-32||integer|
|analog input converted to physical units||32||float|
|analog output converted from physical units||32||float|
1is the same as
.1is the same as
GNDare all equivalent). Default
GROUND. Mnemonic: the value at the low end; hence underscore.
$Date: 2004/12/28 05:32:10 $