staging/easycap: Improve interface to the videodev module
[pandora-kernel.git] / drivers / staging / easycap / README
1
2         ***********************************************************
3         *   EasyCAP USB 2.0 Video Adapter with Audio, Model DC60  *
4         *                            and                          *
5         *             EasyCAP002 4-Channel USB 2.0 DVR            *
6         ***********************************************************
7                      Mike Thomas  <rmthomas@sciolus.org>
8
9
10
11 SUPPORTED HARDWARE
12 ------------------
13
14 This driver is intended for use with hardware having USB ID 05e1:0408.
15 Two kinds of EasyCAP have this USB ID, namely:
16
17     *  EasyCAP USB 2.0 Video Adapter with Audio, Model DC60,
18        having input cables labelled CVBS, S-VIDEO, AUDIO(L), AUDIO(R)
19
20     *  EasyCAP002 4-Channel USB 2.0 DVR, having input cables labelled
21        1, 2, 3, 4 and an unlabelled input cable for a microphone.
22
23
24 BUILD OPTIONS AND DEPENDENCIES
25 ------------------------------
26
27 Unless EASYCAP_DEBUG is defined during compilation it will not be possible
28 to select a debug level at the time of module installation.
29
30 If the parameter EASYCAP_IS_VIDEODEV_CLIENT is undefined during compilation
31 the built module is entirely independent of the videodev module, and when
32 the EasyCAP is physically plugged into a USB port the special files
33 /dev/easycap0 and /dev/easysnd1 are created as video and sound sources
34 respectively.
35
36 If the parameter EASYCAP_IS_VIDEODEV_CLIENT is defined during compilation
37 the built easycap module is configured to register with the videodev module,
38 in which case the special files created when the EasyCAP is plugged in are
39 /dev/video0 and /dev/easysnd0.
40
41 During in-tree builds the following should should be defined whenever the
42 parameter EASYCAP_IS_VIDEODEV_CLIENT is defined:
43
44 EASYCAP_NEEDS_V4L2_DEVICE_H
45 EASYCAP_NEEDS_V4L2_FOPS
46 EASYCAP_NEEDS_UNLOCKED_IOCTL
47
48 If the build is performed out-of-tree against older kernels the parameters
49 to be defined depend on the kernel version in a way which will not be
50 discussed here.
51
52
53 KNOWN RUNTIME ISSUES
54 --------------------
55
56 (1) Intentionally, this driver will not stream material which is unambiguously
57 identified by the hardware as copy-protected.  Normal video output will be
58 present for about a minute but will then freeze when this situation arises.
59
60 (2) The controls for luminance, contrast, saturation, hue and volume may not
61 always work properly.
62
63 (3) Reduced-resolution S-Video seems to suffer from moire artefacts.
64
65
66 INPUT NUMBERING
67 ---------------
68
69 For the EasyCAP with S-VIDEO input cable the driver regards a request for
70 inputs numbered 0 or 1 as referring to CVBS and a request for input
71 numbered 5 as referring to S-VIDEO.
72
73 For the EasyCAP with four CVBS inputs the driver expects to be asked for
74 any one of inputs numbered 1,2,3,4.  If input 0 is asked for, it is
75 interpreted as input 1.
76
77
78 MODULE PARAMETERS
79 -----------------
80
81 Three module parameters are defined:
82
83 debug      the easycap module is configured at diagnostic level n (0 to 9)
84 gain       audio gain level n (0 to 31, default is 16)
85 bars       0 =>  testcard bars when incoming video signal is lost
86            1 =>  testcard bars when incoming video signal is lost (default)
87
88
89 SUPPORTED TV STANDARDS AND RESOLUTIONS
90 --------------------------------------
91
92 The following TV standards are natively supported by the hardware and are
93 usable as (for example) the "norm=" parameter in the mplayer command:
94
95     PAL_BGHIN,    NTSC_N_443,
96     PAL_Nc,       NTSC_N,
97     SECAM,        NTSC_M,        NTSC_M_JP,
98     PAL_60,       NTSC_443,
99     PAL_M.
100
101 In addition, the driver offers "custom" pseudo-standards with a framerate
102 which is 20% of the usual framerate.  These pseudo-standards are named:
103
104     PAL_BGHIN_SLOW,    NTSC_N_443_SLOW,
105     PAL_Nc_SLOW,       NTSC_N_SLOW,
106     SECAM_SLOW,        NTSC_M_SLOW,        NTSC_M_JP_SLOW,
107     PAL_60_SLOW,       NTSC_443_SLOW,
108     PAL_M_SLOW.
109
110
111 The available picture sizes are:
112
113      at 25 frames per second:   720x576, 704x576, 640x480, 360x288, 320x240;
114      at 30 frames per second:   720x480, 640x480, 360x240, 320x240.
115
116
117 WHAT'S TESTED AND WHAT'S NOT
118 ----------------------------
119
120 This driver is known to work with mplayer, mencoder, tvtime, zoneminder,
121 xawtv, gstreamer and sufficiently recent versions of vlc.  An interface
122 to ffmpeg is implemented, but serious audio-video synchronization problems
123 remain.
124
125 The driver is designed to support all the TV standards accepted by the
126 hardware, but as yet it has actually been tested on only a few of these.
127
128 I have been unable to test and calibrate the S-video input myself because I
129 do not possess any equipment with S-video output.
130
131 This driver does not understand the V4L1 IOCTL commands.
132
133
134 UDEV RULES
135 ----------
136
137 In order that the special files /dev/easycap0 and /dev/easysnd1 are created
138 with conveniently relaxed permissions when the EasyCAP is plugged in, a file
139 is preferably to be provided in directory /etc/udev/rules.d with content:
140
141 ACTION!="add|change", GOTO="easycap_rules_end"
142 ATTRS{idVendor}=="05e1", ATTRS{idProduct}=="0408", \
143         MODE="0666", OWNER="root", GROUP="root"
144 LABEL="easycap_rules_end"
145
146
147 MODPROBE CONFIGURATION
148 ----------------------
149
150 The easycap module is in competition with the module snd-usb-audio for the
151 EasyCAP's audio channel, and its installation can be aided by providing a
152 file in directory /etc/modprobe.d with content:
153
154 options easycap  gain=16 bars=1
155 install easycap /sbin/rmmod snd-usb-audio; /sbin/modprobe --ignore-install easycap
156
157
158 ACKNOWLEGEMENTS AND REFERENCES
159 ------------------------------
160 This driver makes use of information contained in the Syntek Semicon DC-1125
161 Driver, presently maintained at http://sourceforge.net/projects/syntekdriver/
162 by Nicolas Vivien.  Particularly useful has been a patch to the latter driver
163 provided by Ivor Hewitt in January 2009.  The NTSC implementation is taken
164 from the work of Ben Trask.
165