README: warn about channel output during testing.
[pycomedi.git] / README
1 This package provides an object-oriented interface to the Comedi_
2 drivers.  The standard Python interface bundled with Comedilib is a
3 simple SWIG clone of the C interface.  In pycomedi, we convert the
4 functions into class methods (see `pycomedi.classes`), so you don't
5 have to worry about dragging around opaque types like `comedi_t *`
6 device pointers.  We also bundle related constants together in
7 `_Enums` and `_Flags` (see `pycomedi.constants`), to make handling
8 common operations like flag manipulations simpler.  Finally, there are
9 a number of utility classes (see `pycomedi.utility`) to make common
10 tasks like creating instructions or reading hardware-timed analog
11 input easier.
12
13
14 Installation
15 ============
16
17 Packages
18 --------
19
20 Gentoo
21 ~~~~~~
22
23 I've packaged pycomedi for Gentoo.  You need layman_ and my `wtk
24 overlay`_.  Install with::
25
26     # emerge -av app-portage/layman
27     # layman --add wtk
28     # emerge -av dev-python/pycomedi
29
30
31 Dependencies
32 ------------
33
34 If you're installing by hand or packaging pycomedi for another
35 distribution, you'll need the following dependencies:
36
37 =======  ===================  ================  ==========================
38 Package  Purpose              Debian_           Gentoo_
39 =======  ===================  ================  ==========================
40 NumPy_   ?                    python-numpy      dev-python/numpy
41 SciPy_   testing              python-scipy      sci-libs/scipy
42 Comedi_  Comedilib interface  python-comedilib  sci-libs/comedilib [#clb]_
43 nose_    testing              python-nose       dev-python/nose
44 Cython_  Comedilib interface  cython            dev-python/cython
45 =======  ===================  ================  ==========================
46
47 .. [#clb] In the `wtk overlay`_.
48
49
50 Installing by hand
51 ------------------
52
53 Pycomedi is available as a Git_ repository::
54
55     $ git clone git://tremily.us/pycomedi.git
56
57
58 See the homepage_ for details.  To install the checkout, run the
59 standard::
60
61     $ python setup.py install
62
63
64 Usage
65 =====
66
67 See the examples in the `doc` directory.
68
69
70 Testing
71 =======
72
73 Run integration tests with::
74
75     $ nosetests --with-doctest --doctest-extension=txt doc
76
77 The analog integration tests read from analog input channels 0 through
78 3, and write to analog output channels 0 and 1, so you'll need a board
79 with that many channels.  You should also make sure that the analog
80 output channels aren't plugged into anything sensetive, since the
81 tests sweep their output around over a reasonable chunk of the channel
82 range.  Some of the internal unit tests also write, so it's safest to
83 just disconnect all digital lines and analog outputs before running
84 the tests.
85
86 Run both integration tests and internal unit tests with::
87
88     $ ./test.sh
89
90
91 Licence
92 =======
93
94 This project is distributed under the `GNU General Public License
95 Version 2`_ or greater.
96
97
98 Author
99 ======
100
101 W. Trevor King
102 wking@tremily.us
103
104
105 .. _Comedi: http://www.comedi.org/
106 .. _layman: http://layman.sourceforge.net/
107 .. _wtk overlay: http://blog.tremily.us/posts/Gentoo_overlay/
108 .. _science overlay: http://overlays.gentoo.org/proj/science/wiki/en
109 .. _Debian: http://www.debian.org/
110 .. _Gentoo: http://www.gentoo.org/
111 .. _NumPy: http://numpy.scipy.org/
112 .. _SciPy: http://www.scipy.org/
113 .. _nose: http://somethingaboutorange.com/mrl/projects/nose/
114 .. _Cython: http://www.cython.org/
115 .. _Git: http://git-scm.com/
116 .. _homepage: http://blog.tremily.us/posts/pycomedi/
117 .. _GNU General Public License Version 2:
118      http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt