1COMEDI_COMMAND_TEST(3)         Comedi reference         COMEDI_COMMAND_TEST(3)
2
3
4

NAME

6       comedi_command_test - test streaming input/output configuration
7

SYNOPSIS

9       #include <comedilib.h>
10
11       int comedi_command_test(comedi_t * device, comedi_cmd * command);
12

DESCRIPTION

14       The function comedi_command_test tests the command structure pointed to
15       by the parameter command and returns an integer describing the testing
16       stages that were successfully passed. In addition, if elements of the
17       comedi_cmd structure are invalid, they may be modified. Source elements
18       are modified to remove invalid source triggers. Argument elements are
19       adjusted or rounded to the nearest valid value.
20

RETURN VALUE

22       The meanings of the return value are as follows:
23
24       ·   0 indicates a valid command.
25
26       ·   1 indicates that one of the ..._src members of the command
27           contained an unsupported trigger. The bits corresponding to the
28           unsupported triggers are zeroed.
29
30       ·   2 indicates that the particular combination of ..._src settings is
31           not supported by the driver, or that one of the ..._src members has
32           the bit corresponding to multiple trigger sources set at the same
33           time.
34
35       ·   3 indicates that one of the ..._arg members of the command is set
36           outside the range of allowable values. For instance, an argument
37           for a TRIG_TIMER source which exceeds the board's maximum speed.
38           The invalid ..._arg members will be adjusted to valid values.
39
40       ·   4 indicates that one of the ..._arg members required adjustment.
41           For instance, the argument of a TRIG_TIMER source may have been
42           rounded to the nearest timing period supported by the board.
43
44       ·   5 indicates that some aspect of the command's chanlist is
45           unsupported by the board. For example, some analog input boards
46           require that all channels in the chanlist use the same input range.
47
48       On failure, -1 is returned.
49

AUTHORS

51       David Schleef <ds@schleef.org>
52           Author.
53
54       Frank Mori Hess <fmhess@users.sourceforge.net>
55           Author.
56
57       Herman Bruyninckx <Herman.Bruyninckx@mech.kuleuven.ac.be>
58           Author.
59
60       Bernd Porr <tech@linux-usb-daq.co.uk>
61           Author.
62
63       Ian Abbott <abbotti@mev.co.uk>
64           Author.
65
66       Éric Piel <piel@delmic.com>
67           Author.
68
70       Copyright © 1998-2003 David Schleef
71       Copyright © 2001-2003, 2005, 2008 Frank Mori Hess
72       Copyright © 2002-2003 Herman Bruyninckx
73       Copyright © 2012 Bernd Porr
74       Copyright © 2012 Ian Abbott
75       Copyright © 2012, 2015 Éric Piel
76
77       This document is part of Comedilib. In the context of this document,
78       the term "source code" as defined by the license is interpreted as the
79       XML source.
80
81       This library is free software; you can redistribute it and/or modify it
82       under the terms of the GNU Lesser General Public License as published
83       by the Free Software Foundation, version 2.1 of the License.
84
85       This library is distributed in the hope that it will be useful, but
86       WITHOUT ANY WARRANTY; without even the implied warranty of
87       MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser
88       General Public License for more details.
89
90       You should have received a copy of the GNU Lesser General Public
91       License along with this library; if not, write to the Free Software
92       Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
93       USA.
94
95
96
97
98Comedi                            05/11/2017            COMEDI_COMMAND_TEST(3)
Impressum