comedilib/doc/deprecated_funcref.txt
Ian Abbott aff4937e03 Added some more buffer position functions for use with mmap
Added comedi_get_buffer_read_offset(), comedi_get_buffer_write_offset(),
comedi_get_buffer_read_count(), and comedi_get_buffer_write_count().

comedi_get_buffer_read_offset() is the same as
comedi_get_buffer_offset(), which has now been documented as deprecated,
but is currently still declared in "comedilib.h" by default.  It gets
the read position within the buffer as an offset from the start of the
buffer (modulo the buffer size).

comedi_get_buffer_write_offset() gets the write position within the
buffer as an offset from the start of the buffer (modulo the buffer
size).

comedi_get_buffer_read_count() gets the number of bytes read from the
buffer, modulo UINT_MAX+1.

comedi_get_buffer_write_count() gets the number of bytes written to the
buffer, modulo UINT_MAX+1.
2016-05-13 15:14:47 +01:00

112 lines
4.2 KiB
Text

Deprecated functions
Function: comedi_dio_bitfield -- read/write multiple digital channels
Retval: int
Param: comedi_t * device
Param: unsigned int subdevice
Param: unsigned int write_mask
Param: unsigned int * bits
Status: deprecated
Description:
This function is deprecated. Use <function><link
linkend="func-ref-comedi-dio-bitfield2">comedi_dio_bitfield2</link></function>
instead. It is equivalent to using <function>comedi_dio_bitfield2</function>
with <parameter class="function">base_channel</parameter> set to
<literal>0</literal>.
Function: comedi_get_buffer_offset -- streaming buffer status (deprecated)
Status: deprecated
Description:
This function is deprecated. Use <function><link
linkend="func-ref-comedi-get-buffer-read-offset">comedi_get_buffer_read_offset</link></function>
instead. It has the same functionality as
<function>comedi_get_buffer_read_offset</function>.
Function: comedi_get_timer -- timer information (deprecated)
Retval: int
Param: comedi_t * device
Param: unsigned int subdevice
Param: double frequency
Param: unsigned int * trigvar
Param: double * actual_frequency
Status: deprecated
Description:
The function <function>comedi_get_timer</function> converts the frequency
<parameter class="function">frequency</parameter>
to a number suitable to send to the driver in a <type>comedi_trig</type>
structure. This function remains for compatibility with very
old versions of Comedi, that converted sampling rates to timer
values in the library. This conversion is now done in the kernel,
and every device has the timer type <constant>nanosec_timer</constant>, indicating
that timer values are simply a time specified in nanoseconds.
Function: comedi_sv_init -- slowly-varying inputs
Retval: int
Param: comedi_sv_t * sv
Param: comedi_t * device
Param: unsigned int subdevice
Param: unsigned int channel
Status: deprecated
Description:
The function <function>comedi_sv_init</function> initializes the slow varying Comedi
structure pointed to by <parameter class="function">sv</parameter> to use the
device <parameter class="function">device</parameter>, the analog input subdevice
<parameter class="function">subdevice</parameter>, and the channel
<parameter class="function">channel</parameter>. The slow varying Comedi
structure is used by
<function><link linkend="func-ref-comedi-sv-measure">comedi_sv_measure</link></function>
to accurately measure
an analog input by averaging over many samples. The default
number of samples is 100.
Returns:
This function returns <literal>0</literal> on success,
<literal>-1</literal> on error.
Function: comedi_sv_measure -- slowly-varying inputs
Retval: int
Param: comedi_sv_t * sv
Param: double * data
Status: deprecated
Description:
The function <function>comedi_sv_measure</function> uses the slowly varying Comedi
structure pointed to by <parameter class="function">sv</parameter>
to measure a slowly varying signal. If successful,
the result (in physical units) is stored in the location pointed
to by <parameter class="function">data</parameter>, and the number of samples
is returned. On error, <literal>-1</literal>
is returned.
Function: comedi_sv_update -- slowly-varying inputs
Retval: int
Param: comedi_sv_t * sv
Status: deprecated
Description:
The function <function>comedi_sv_update</function> updates internal parameters of
the slowly varying Comedi structure pointed to by
<parameter class="function">sv</parameter>.
Function: comedi_timed_1chan -- streaming input (deprecated)
Retval: int
Param: comedi_t * device
Param: unsigned int subdevice
Param: unsigned int channel
Param: unsigned int range
Param: unsigned int aref
Param: double frequency
Param: unsigned int num_samples
Param: double * data
Status: deprecated
Description:
Not documented.
Function: comedi_trigger -- perform streaming input/output (deprecated)
Retval: int
Param: comedi_t * device
Param: comedi_trig * trig
Status: deprecated
Description:
The function <function>comedi_trigger</function> instructs Comedi to
perform the command specified by the trigger structure pointed to by
<parameter class="function">trig</parameter>.
The return value depends on
the particular trigger being issued. If there is an
error, <literal>-1</literal> is returned.