⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 readme.cpia

📁 嵌入式系统设计与实例开发实验教材二源码 多线程应用程序设计 串行端口程序设计 AD接口实验 CAN总线通信实验 GPS通信实验 Linux内核移植与编译实验 IC卡读写实验 SD驱动使
💻 CPIA
字号:
This is a driver for the CPiA PPC2 driven parallel connectedCamera. For example the Creative WebcamII is CPiA driven.   ) [1]Peter Pregler, Linz 2000, published under the [2]GNU GPL---------------------------------------------------------------------------USAGE:General:========1) Make sure you have created the video devices (/dev/video*):- if you have a recent MAKEDEV do a 'cd /dev;./MAKEDEV video'- otherwise do a:cd /devmknod video0 c 81 0ln -s video0 video2) Compile the kernel (see below for the list of options to use),   configure your parport and reboot.3) If all worked well you should get messages similar   to the following (your versions may be different) on the console:V4L-Driver for Vision CPiA based cameras v0.7.4parport0: read2 timeout.parport0: Multimedia device, VLSI Vision Ltd PPC2Parallel port driver for Vision CPiA based camera  CPIA Version: 1.20 (2.0)  CPIA PnP-ID: 0553:0002:0100  VP-Version: 1.0 0100  1 camera(s) foundAs modules:===========Make sure you have selected the following kernel options (you canselect all stuff as modules):The cpia-stuff is in the section 'Character devices -> Video For Linux'.CONFIG_PARPORT=mCONFIG_PARPORT_PC=mCONFIG_PARPORT_PC_FIFO=yCONFIG_PARPORT_1284=yCONFIG_VIDEO_DEV=mCONFIG_VIDEO_CPIA=mCONFIG_VIDEO_CPIA_PP=mFor autoloading of all those modules you need to tell modutils somestuff. Add the following line to your modutils config-file(e.g. /etc/modules.conf or wherever your distribution does store thatstuff):options parport_pc io=0x378 irq=7 dma=3alias char-major-81 cpia_ppThe first line tells the dma/irq channels to use. Those _must_ matchthe settings of your BIOS. Do NOT simply use the values above.  SeeDocumentation/parport.txt for more information about this. The secondline associates the video-device file with the driver. Of cause youcan also load the modules once upon boot (usually done in /etc/modules).Linked into the kernel:=======================Make sure you have selected the following kernel options. Note thatyou cannot compile the parport-stuff as modules and the cpia-driverstatically (the other way round is okay though).The cpia-stuff is in the section 'Character devices -> Video For Linux'.CONFIG_PARPORT=yCONFIG_PARPORT_PC=yCONFIG_PARPORT_PC_FIFO=yCONFIG_PARPORT_1284=yCONFIG_VIDEO_DEV=yCONFIG_VIDEO_CPIA=yCONFIG_VIDEO_CPIA_PP=yTo use DMA/irq you will need to tell the kernel upon boot time thehardware configuration of the parport. You can give the boot-parameterat the LILO-prompt or specify it in lilo.conf. I use the followingappend-line in lilo.conf:        append="parport=0x378,7,3"See Documentation/parport.txt for more information about theconfiguration of the parport and the values given above. Do not simplyuse the values given above.---------------------------------------------------------------------------FEATURES:- mmap/read v4l-interface (but no overlay)- image formats: CIF/QCIF, SIF/QSIF, various others used by isabel;  note: all sizes except CIF/QCIF are implemented by clipping, i.e.  pixels are not uploaded from the camera- palettes: VIDEO_PALETTE_GRAY, VIDEO_PALETTE_RGB565, VIDEO_PALETTE_RGB555,  VIDEO_PALETTE_RGB24, VIDEO_PALETTE_RGB32, VIDEO_PALETTE_YUYV,  VIDEO_PALETTE_UYVY, VIDEO_PALETTE_YUV422- state information (color balance, exposure, ...) is preserved between  device opens- complete control over camera via proc-interface (_all_ camera settings are  supported), there is also a python-gtk application available for this [3]- works under SMP (but the driver is completely serialized and synchronous)  so you get no benefit from SMP, but at least it does not crash your box- might work for non-Intel architecture, let us know about this---------------------------------------------------------------------------TESTED APPLICATIONS:- a simple test application based on Xt is available at [3]- another test-application based on gqcam-0.4 (uses GTK)- gqcam-0.6 should work- xawtv-3.x (also the webcam software)- xawtv-2.46- w3cam (cgi-interface and vidcat, e.g. you may try out 'vidcat  |xv  -maxpect -root -quit +noresetroot -rmode 5 -')- vic, the MBONE video conferencing tool (version 2.8ucl4-1)- isabel 3R4beta (barely working, but AFAICT all the problems are on  their side)- camserv-0.40See [3] for pointers to v4l-applications.---------------------------------------------------------------------------KNOWN PROBLEMS:- some applications do not handle the image format correctly, you will  see strange horizontal stripes instead of a nice picture -> make sure  your application does use a supported image size or queries the driver  for the actually used size (reason behind this: the camera cannot  provide any image format, so if size NxM is requested the driver will  use a format to the closest fitting N1xM1, the application should now  query for this granted size, most applications do not).- all the todo ;)- if there is not enough light and the picture is too dark try to  adjust the SetSensorFPS setting, automatic frame rate adjustment  has its price- do not try out isabel 3R4beta (built 135), you will be disappointed---------------------------------------------------------------------------TODO:- multiple camera support (struct camera or something) - This should work,  but hasn't been tested yet.- architecture independence?- SMP-safe asynchronous mmap interface- nibble mode for old parport interfaces- streaming capture, this should give a performance gain---------------------------------------------------------------------------IMPLEMENTATION NOTES:The camera can act in two modes, streaming or grabbing. Right now apolling grab-scheme is used. Maybe interrupt driven streaming will beused for a asynchronous mmap interface in the next major release of thedriver. This might give a better frame rate.---------------------------------------------------------------------------THANKS (in no particular order):- Scott J. Bertin <sbertin@mindspring.com> for cleanups, the proc-filesystem  and much more- Henry Bruce <whb@vvl.co.uk> for providing developers information about  the CPiA chip, I wish all companies would treat Linux as seriously- Karoly Erdei <Karoly.Erdei@risc.uni-linz.ac.at> and RISC-Linz for being  my boss ;) resp. my employer and for providing me the hardware and  allow me to devote some working time to this project- Manuel J. Petit de Gabriel <mpetit@dit.upm.es> for providing help  with Isabel (http://isabel.dit.upm.es/)- Bas Huisman <bhuism@cs.utwente.nl> for writing the initial parport code- Jarl Totland <Jarl.Totland@bdc.no> for setting up the mailing list   and maintaining the web-server[3]- Chris Whiteford <Chris@informinteractive.com> for fixes related to the  1.02 firmware- special kudos to all the tester whose machines crashed and/or  will crash. :)---------------------------------------------------------------------------REFERENCES   1. http://www.risc.uni-linz.ac.at/people/ppregler      mailto:Peter_Pregler@email.com   2. see the file COPYING in the top directory of the kernel tree   3. http://webcam.sourceforge.net/

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -