1 .\" $NetBSD: bktr.4,v 1.16 2005/12/06 23:45:48 wiz Exp $
3 .\" Copyright (c) 2000, 2001, 2002, 2003, 2004, 2005 Thomas Klausner
4 .\" All rights reserved.
6 .\" Redistribution and use in source and binary forms, with or without
7 .\" modification, are permitted provided that the following conditions
9 .\" 1. Redistributions of source code must retain the above copyright
10 .\" notice, this list of conditions and the following disclaimer.
11 .\" 2. The name of the author may not be used to endorse or promote products
12 .\" derived from this software without specific prior written permission.
14 .\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
15 .\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
16 .\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
17 .\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
18 .\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
19 .\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
20 .\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
21 .\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
22 .\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
23 .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
24 .\" POSSIBILITY OF SUCH DAMAGE.
31 .Nd Brooktree 848 compatible TV card driver
33 .Cd "bktr* at pci? dev ? function ?"
38 .Cd options BKTR_OVERRIDE_CARD=n
39 .Cd options BKTR_OVERRIDE_TUNER=n
40 .Cd options BKTR_OVERRIDE_DBX=n
41 .Cd options BKTR_OVERRIDE_MSP=n
42 .Cd options BKTR_SYSTEM_DEFAULT=n
43 .Cd options BKTR_USE_PLL
44 .Cd options BKTR_GPIO_ACCESS
45 .Cd options BKTR_NO_MSP_RESET
46 .\" The following options have no effect:
47 .\" .Cd options BKTR_430_FX_MODE
48 .\" .Cd options BKTR_SIS_VIA_MODE
50 This driver supports video capture (frame grabber) and TV tuner cards
61 Supported cards include most cards by
69 and some other companies, especially all cards based on the
78 A notable exception are the
83 The following kernel configuration options are available:
85 .It Cd options BKTR_OVERRIDE_CARD=n
86 If the card is not recognized correctly by the auto-detection routine,
87 it can be overridden by setting this option to the appropriate
89 The following values are allowed:
90 .Bl -tag -width 2n -compact
92 Pinnacle Systems (Miro) TV,
98 Intel Smart Video III and Videologic Captivator PCI,
108 I/O DATA GV-BCTV2/PCI,
110 Animation Technologies FlyVideo,
116 Video Highway Xtreme,
118 Askey/Dynalink Magic TView,
120 Leadtek WinFast TV 2000/VC100,
127 .It Cd options BKTR_OVERRIDE_TUNER=n
128 If the TV tuner is not recognized correctly by the auto-detection
129 routine, it can be overridden by setting this option to the
132 .Bl -tag -width 2n -compact
150 Philips FR1236 NTSC FM,
152 Philips FR1216 PAL FM,
154 Philips FR1236 SECAM FM,
161 .It Cd options BKTR_OVERRIDE_DBX=n
162 To override detection of the BTSC (dbx) chip, set this to
167 .It Cd options BKTR_OVERRIDE_MSP=n
168 To override detection of the MSP 34xx chip, set this to
173 .It Cd options BKTR_SYSTEM_DEFAULT=n
174 If this option is set to
176 default to PAL, else to NTSC.
177 .It Cd options BKTR_USE_PLL
178 Default to PLL instead of XTAL.
179 .It Cd options BKTR_GPIO_ACCESS
182 for direct GPIO access.
183 .It Cd options BKTR_NO_MSP_RESET
185 This option is handy if you initialize the MSP audio in another
186 operating system first and then do a soft reboot.
187 .\" The following options have no effect:
188 .\" .It Cd options BKTR_430_FX_MODE
189 .\" .It Cd options BKTR_SIS_VIA_MODE
191 .Sh VIDEO CAPTURE INTERFACE
192 The video capture interface to
194 is accessed through the
199 commands are supported on the Brooktree848 video capture interface:
201 .It Dv METEORSFMT Fa "unsigned long *"
202 This command sets the video format, also sometimes referred to as the
204 The supported formats are:
206 .Bl -tag -compact -width 28n
207 .It Dv METEOR_FMT_NTSC
209 .It Dv METEOR_FMT_PAL
211 .It Dv METEOR_FMT_SECAM
213 .It Dv METEOR_FMT_AUTOMODE
216 .It Dv METEORGFMT Fa "unsigned long *"
217 This command retrieves the current video format to the
220 .It Dv METEORSETGEO Fa "struct meteor_geomet *"
221 This command sets the video properties that affect the bit size of
226 struct meteor_geomet {
227 u_short rows; /* height in pixels*/
228 u_short columns; /* width in pixels */
236 field is the number of frames to buffer.
237 Currently only 1 frame is supported for most operations.
241 field is a bit-field describing the output pixel format
242 type and which video fields to capture.
243 The following are supported pixel format types:
245 .Bl -tag -compact -width 28n
246 .It Dv METEOR_GEO_RGB16
248 .It Dv METEOR_GEO_RGB24
249 24-bit RGB in 32 bits
250 .It Dv METEOR_GEO_YUV_PACKED
252 .It Dv METEOR_GEO_YUV_PLANAR
254 .It Dv METEOR_GEO_YUV_UNSIGNED
256 .It Dv METEOR_GEO_YUV_422
257 .It Dv METEOR_GEO_YUV_12
258 .It Dv METEOR_GEO_YUV_9
261 The following are supported field capture modes:
263 .Bl -tag -compact -width 28n
264 .It Dv METEOR_GEO_ODD_ONLY
266 .It Dv METEOR_GEO_EVEN_ONLY
270 By default, frames will consist of both the odd and even fields.
271 .It Dv METEORGSUPPIXFMT Fa "struct meteor_pixfmt *"
272 This command is used interactively to fetch descriptions of supported
273 output pixel formats into the
277 struct meteor_pixfmt {
280 u_int Bpp; /* bytes per pixel */
281 u_long masks[3]; /* YUV bit masks */
282 unsigned swap_bytes :1;
283 unsigned swap_shorts:1;
287 To query all the supported formats, start with an index field of 0 and
288 continue with successive encodings (1, 2, ...) until the command returns
290 .It Dv METEORSACTPIXFMT Fa "int *"
291 This command sets the active pixel format.
294 argument is the index of the pixel format as returned by
295 .Dv METEORGSUPPIXFMT .
296 .It Dv METEORGACTPIXFMT Fa "int *"
297 This command fetches the active pixel format index into the
300 .It Dv METEORSINPUT Fa "unsigned long *"
301 This command sets the input port of the Brooktree848 device.
302 The following are supported input ports:
304 .Bl -tag -compact -width 28n
305 .It Dv METEOR_INPUT_DEV0
307 .It Dv METEOR_INPUT_DEV1
309 .It Dv METEOR_INPUT_DEV2
311 .It Dv METEOR_INPUT_DEV3
313 .It Dv METEOR_INPUT_DEV_RGB
315 .It Dv METEOR_INPUT_DEV_SVIDEO
319 Not all devices built with Brooktree848 chips support the
320 full list of input ports.
321 .It Dv METEORGINPUT Fa "unsigned long *"
322 This command retrieves the current input port to the
325 .It Dv METEORSFPS Fa "unsigned short *"
326 This command sets the number of frames to grab each second.
327 Valid frame rates are integers from 0 to 30.
328 .It Dv METEORGFPS Fa "unsigned short *"
329 This command fetches the number of frames to grab each second into the
332 .It Dv METEORCAPTUR Fa "int *"
333 This command controls capturing of video data.
334 The following are valid arguments:
336 .Bl -tag -compact -width 28n
337 .It Dv METEOR_CAP_SINGLE
339 .It Dv METEOR_CAP_CONTINOUS
341 .It Dv METEOR_CAP_STOP_CONT
342 stop continuous capture
344 .It Dv METEORSSIGNAL Fa "unsigned int *"
345 This command controls the signal emission properties of
349 argument is a valid signal, then that signal will be emitted
350 when either a frame or field capture has completed.
351 To select between frame or field signalling, the following arguments
354 .Bl -tag -compact -width 28n
355 .It Dv METEOR_SIG_FRAME
357 .It Dv METEOR_SIG_FIELD
361 By default, signals will be generated for every frame.
362 Generation of signals is terminated with the
363 .Dv METEOR_SIG_MODE_MASK
367 Most cards supported by this driver feature a hardware television tuner
369 The tuner interface to
371 is accessed through the
376 commands are supported on the tuner interface:
378 .It Dv TVTUNER_SETTYPE Fa "unsigned int *"
379 This command sets the tuner's TV channel set, also sometimes called the TV
381 This setting is used to calculate the proper tuning frequencies.
382 The desired channel set must be selected before attempting to set the tuner
383 channel or frequency.
384 The following is a list of valid channel sets:
386 .Bl -tag -compact -width 28n
387 .It Dv CHNLSET_NABCST
388 North America broadcast
389 .It Dv CHNLSET_CABLEIRC
390 North America IRC cable
391 .It Dv CHNLSET_CABLEHRC
392 North America HRC cable
393 .It Dv CHNLSET_WEUROPE
395 .It Dv CHNLSET_JPNBCST
397 .It Dv CHNLSET_JPNCABLE
401 .It Dv CHNLSET_AUSTRALIA
403 .It Dv CHNLSET_FRANCE
406 .It Dv TVTUNER_GETTYPE Fa "unsigned int *"
407 This command fetches the tuner's current channel set to the
410 .It Dv TVTUNER_SETCHNL Fa "unsigned int *"
411 This command sets the tuner's frequency to a specified channel in the
413 .It Dv TVTUNER_GETCHNL Fa "unsigned int *"
414 This command fetches the last selected channel.
415 Note that it is not necessarily the current channel.
416 In particular, changing the tuner's frequency by a command other than
418 will not update this setting, and it defaults to 0 on driver
420 .It Dv TVTUNER_SETFREQ Fa "unsigned int *"
421 This command sets the tuner's frequency to 1/16th the value of the
424 Note that the current channelset is used to determine frequency
425 offsets when this command is executed.
426 .It Dv TVTUNER_GETFREQ Fa "unsigned int *"
427 This command fetches the tuner's current frequency to the
430 Note that this value is 16 times the actual tuner frequency, in MHz.
431 .It Dv BT848_SAUDIO Fa "int *"
432 This command controls the audio input port and mute state.
433 The following is a list of valid arguments:
435 .Bl -tag -compact -width 18n
447 .It Dv BT848_GAUDIO Fa "int *"
448 This command fetches the audio input and mute state bits to the
453 .Bl -tag -width /dev/tuner* -compact
456 driver interface device
459 tuner interface device
461 teletext interface device
467 .Pa pkgsrc/audio/xmradio ,
468 .Pa pkgsrc/multimedia/ffmpeg ,
469 .Pa pkgsrc/multimedia/fxtv
480 driver was originally written by Amancio Hasty for
482 and is now maintained by Roger Hardiman.
484 porting was done by Bernd Ernesti, Berndt Josef Wulf, Matthias
485 Scheler, and Thomas Klausner.