Kevin's dummy Webcam driver

What is this?

dummy_camera is a Video4Linux driver that fakes a simple Webcam. It is implemented as a completely independent loadable kernel module, and does not require any kernel modifications to use. It is intended to be used to assist in testing and develping video-conferencing setups. It requires no hardware, so problems can be isolated from hardware and network configuration, etc. Like a real Webcam, dummy_camera generates low resolution images (128x128) at low frame rates (3 fps). It does not, therefore, suport the `mmap' interface to V4L drivers (see below) which may be a limitation for some clients. The driver generates a simple test pattern, as shown below (this screenshot is from the Xawtv application).

dummy_camera responds to instructions from the client to change brightness and colour, so if you tweak these on the client you should see the display change in real time.

Installation and configuration

Extract the archive and do this:
make clean
make
make install
The most important file created by this process is the loadable module itself, dummy_camera.o. make install puts this in the misc subdirectory of the modules directory. You can load the module like this:
modprobe videodev 
modprobe dummy_camera 
The dummy camera module has a depedency on the videodev module, so that must be loaded first. If you get `unresolved symbol' messages from modprobe, please contact me.

Bugs and limitation

I don't know of any obvious bugs, although there undoubtedly are some. The main limitation is that dummy_camera emulates a primitive Webcam. There is no sound support, because primitive Webcams don't have their own sound devices. There is no support for the `mmap' interface to V4L drivers, which many modern devices benefit from. The `mmap' scheme allows the client application to get direct access to the driver's buffers, which is faster than making explicit `read' operations for each frame. This is only a limitation if the software you want to test insists on using mmap: some does.

Although brightness and colour changes are supported, the other adjustable display properties are not (hue, contrast, etc). There did not seem to be much point in implementing these.

Author and legal

This kernel module was written by Kevin Boone and is (c)2002, distributed according to the GPL. You may do whatever you like with this code, provided that authorship continues to be acknowledged and source code remains available. Needless to say, there is no warranty of any kind, and you use this at your own risk. Please report bugs, etc., to kb@kevinboone.com.