January 2, 2008

r5u870

Filed under: Software, Tech — Alex @ 2:19 pm

r5u870 is a terrific little driver written by Sam Revitch that provides support for Ricoh R5U870 webcams.
The original driver itself supports the following devices:

05ca:1810 HP Pavilion Webcam - UVC
05ca:1830 Sony Visual Communication Camera VGP-VCC2 (for VAIO SZ)
05ca:1832 Sony Visual Communication Camera VGP-VCC3 (for VAIO UX)
05ca:1833 Sony Visual Communication Camera VGP-VCC2 (for VAIO AR1)
05ca:1834 Sony Visual Communication Camera VGP-VCC2 (for VAIO AR2)
05ca:1835 Sony Visual Communication Camera VGP-VCC5 (for VAIO SZ)
05ca:1836 Sony Visual Communication Camera VGP-VCC4 (for VAIO FE)
05ca:1870 HP Pavilion Webcam / HP Webcam 1000

Now, since the kernel doesn’t come with this driver, I couldn’t use my webcam on my laptop. Sucky.
After a bit of researching, I found that this appeared to be the driver I needed. So, I clicked on the link to download the driver off Sam’s website (http://lsb.blogdns.net/ry5u870/ via the Wayback Machine). Guess what? The site’s down. Damn.

After a bit of peeking around in different places, I managed to download a .deb from here and took the source from the upstream/ directory inside. Haha, now I had the source.

I installed the linux-headers-2.6.xxx package (kernel-source on OpenSUSE 10.3; they’re headers package doesn’t work AFAIK) and compiled. Success! Go-go-gadget modprobe. The module loaded OK, but the driver didn’t detect my webcam. I went back and checked the original device support list - my device wasn’t there. It was actually a VGP-VCC7 (05ca:183a), which wasn’t built into the driver. Another quick Google sent me here. Ah hah, so I needed to patch the driver so it could support my device, and extract the firmware from the original driver.

After I had applied the patch, and got the firmware going, I compiled and installed. Finally, it seemed to have worked!
I fired gstreamer-properties and tried to test the video input - it failed. After installing xawtv, I ran it and see what came up - my webcam. Apparently it doesn’t like being run through GStreamer, which sucks, ’cause that’s where Cheese is at.

So, I spent the rest of the weekend debugging, and compiling, and debugging…

At the end, I came up with this: r5u870 0.10.1. And it works! See? (please don’t ask what happened to my eye, I must’ve been blinking at the same time, or something.. =)

My ugly mug.

r5u870 0.10.1 is actually modified version of the original device driver, that has several advantages:

  • Properly implements V4L version 1 query functions. While version 1 has been obsoleted, it’s still necessary to have support for it as a number of apps still use it, including GStreamer’s v4lsrc element (v4l2src is on the way, I believe it’s in gst-plugins-bad at the moment).
  • Native support for VGP-VCC7, including supplied microcode.
  • Can compile against Linux kernels 2.6.24+. OpenSUSE 11.0 Alpha 0 uses this at the moment, I expect more distros to start using it sooner or later.

If you want to download or contribute, head over to it’s wiki page. I should probably note I’m merely the maintainer of the driver until Sam comes back from the null void, if that happens. I might attempt to get this into the current kernel tree, too.

1 Comment »

  1. Hey man, I got that TZ90 since last July, and I was waiting for someone else to do that work for me since. Hehe thanks!

    The svm does not compile, had to go back to revision 30.

    hap@freenode.

    Comment by Fabien Penso — January 16, 2008 @ 8:45 pm

RSS feed for comments on this post. TrackBack URL

Leave a comment