HOWTO: Serval Performance (SERP2) webcam

I spent a little time this evening working on getting the built-in webcam of my Serval Performance (SERP2) to function under Ubuntu Hardy (8.04).

I found a driver for the webcam here: https://groups.google.com/group/microdia.

Instructions on downloading and building the driver follow. For more thorough instructions, I’d recommend looking at Testing the Microdia driver.

Since we’ll be compiling a kernel driver, you’ll need to install the kernel source files:

$ sudo apt-get install kernel-package linux-source build-essential

Next you’ll need to install git so we can download the driver’s source code:

$ sudo apt-get install git-core gitk git-gui git-doc curl

Now we’ll download the webcam driver:

$ git clone http://repo.or.cz/r/microdia.git

Let’s compile the kernel module (webcam driver):

$ cd microdia
$ make

Load our new kernel driver:

$ sudo insmod ./microdia.ko

Check to see that the driver loaded successfully:

$ dmesg

You should see something like this at the bottom of the output:

[107348.616179] microdia: Microdia USB2.0 webcam driver startup
[107348.616563] microdia: Microdia USB2.0 Webcam - Product ID 624F.
[107348.616570] microdia: Release: 0100
[107348.616574] microdia: Number of interfaces : 1
[107348.623570] microdia: Microdia USB2.0 Camera is now controlling video device /dev/video0
[107348.623950] usbcore: registered new interface driver usb_microdia_driver

Now we can test the driver with VLC:

$ sudo apt-get install vlc
$ vlc

Once VLC is running, select File > Open Capture Device… Set the “Video device name” to /dev/video0 (or whatever appears in the dmesg output above). Click OK. You should see a window displaying the webcam video.

The biggest hurdle that I see is that you’d have to recompile the driver each time the kernel is upgraded. Hopefully System76 may be coaxed into packaging it up as a System76 driver that can be updated as new kernels are released, and so that users don’t have to compile kernel drivers themselves (’cause let’s face it, no one should have to learn to do that!).

Please note that I didn’t write the driver; I just discovered it this evening and got it running. Also, using insmod ./microdia.ko only loads the driver until you reboot your machine. The driver won’t be loaded automatically unless you take further steps (see the link above). I haven’t played with the webcam too much yet; I just tested it with VLC.

If you run into any problems, see the Microdia kernel driver site for more details.