Moved comedi_to_phys and comedi_from_phys back to the main
[comedilib.git] / doc / deprecated_funcref.txt
1 Deprecated functions
2 Function: comedi_dio_bitfield -- read/write multiple digital channels
3 Retval: int
4 Param: comedi_t * device
5 Param: unsigned int subdevice
6 Param: unsigned int write_mask
7 Param: unsigned int * bits
8 Status: deprecated
9 Description:
10  This function is deprecated.  Use <function><link
11  linkend="func-ref-comedi-dio-bitfield2">comedi_dio_bitfield2</link></function>
12  instead.  It is equivalent to using <function>comedi_dio_bitfield2</function>
13  with <parameter class="function">base_channel</parameter> set to
14  <literal>0</literal>.
15
16 Function: comedi_get_timer -- timer information (deprecated)
17 Retval: int
18 Param: comedi_t * device
19 Param: unsigned int subdevice
20 Param: double frequency
21 Param: unsigned int * trigvar
22 Param: double * actual_frequency
23 Status: deprecated
24 Description:
25  The function <function>comedi_get_timer</function> converts the frequency
26  <parameter class="function">frequency</parameter>
27  to a number suitable to send to the driver in a <type>comedi_trig</type>
28  structure.  This function remains for compatibility with very
29  old versions of Comedi, that converted sampling rates to timer
30  values in the library.  This conversion is now done in the kernel,
31  and every device has the timer type <constant>nanosec_timer</constant>, indicating
32  that timer values are simply a time specified in nanoseconds.
33
34 Function: comedi_set_global_oor_behavior -- out-of-range behavior
35 Retval: int
36 Param: enum comedi_oor_behavior behavior
37 Status: deprecated
38 Description:
39  This function changes the Comedilib out-of-range behavior.
40  This currently affects the behavior of <function>comedi_to_phys</function> when
41  converting endpoint sample values, that is, sample values
42  equal to <literal>0</literal> or <parameter
43  class="function">maxdata</parameter>.  If the out-of-range behavior is set to
44  <constant>COMEDI_OOR_NAN</constant>, endpoint values are converted to
45  <constant>NAN</constant>.  If the
46  out-of-range behavior is set to <constant>COMEDI_OOR_NUMBER</constant>, the endpoint
47  values are converted similarly to other values.
48
49  The previous out-of-range behavior is returned.
50
51 Function: comedi_sv_init -- slowly-varying inputs
52 Retval: int
53 Param: comedi_sv_t * sv
54 Param: comedi_t * device
55 Param: unsigned int subdevice
56 Param: unsigned int channel
57 Status: deprecated
58 Description:
59  The function <function>comedi_sv_init</function> initializes the slow varying Comedi
60  structure pointed to by <parameter class="function">sv</parameter> to use the
61  device <parameter class="function">device</parameter>, the analog input subdevice
62  <parameter class="function">subdevice</parameter>, and the channel
63  <parameter class="function">channel</parameter>.  The slow varying Comedi
64  structure is used by
65  <function><link linkend="func-ref-comedi-sv-measure">comedi_sv_measure</link></function>
66  to accurately measure
67  an analog input by averaging over many samples.  The default
68  number of samples is 100.
69 Returns:
70  This function returns <literal>0</literal> on success,
71  <literal>-1</literal> on error.
72
73 Function: comedi_sv_measure -- slowly-varying inputs
74 Retval: int
75 Param: comedi_sv_t * sv
76 Param: double * data
77 Status: deprecated
78 Description:
79  The function <function>comedi_sv_measure</function> uses the slowly varying Comedi
80  structure pointed to by <parameter class="function">sv</parameter>
81  to measure a slowly varying signal.  If successful,
82  the result (in physical units) is stored in the location pointed
83  to by <parameter class="function">data</parameter>, and the number of samples
84  is returned.  On error, <literal>-1</literal>
85  is returned.
86
87 Function: comedi_sv_update -- slowly-varying inputs
88 Retval: int
89 Param: comedi_sv_t * sv
90 Status: deprecated
91 Description:
92  The function <function>comedi_sv_update</function> updates internal parameters of
93  the slowly varying Comedi structure pointed to by
94  <parameter class="function">sv</parameter>.
95
96 Function: comedi_timed_1chan -- streaming input (deprecated)
97 Retval: int
98 Param: comedi_t * device
99 Param: unsigned int subdevice
100 Param: unsigned int channel
101 Param: unsigned int range
102 Param: unsigned int aref
103 Param: double frequency
104 Param: unsigned int num_samples
105 Param: double * data
106 Status: deprecated
107 Description:
108  Not documented.
109
110 Function: comedi_trigger -- perform streaming input/output (deprecated)
111 Retval: int
112 Param: comedi_t * device
113 Param: comedi_trig * trig
114 Status: deprecated
115 Description:
116  The function <function>comedi_trigger</function> instructs Comedi to
117  perform the command specified by the trigger structure pointed to by
118  <parameter class="function">trig</parameter>.
119  The return value depends on
120  the particular trigger being issued.  If there is an
121  error, <literal>-1</literal> is returned.