Thursday, September 01, 2005

Logitech QuickCam Notebook Pro

Logitech QuickCam Notebook Pro. This piece of hardware worked flawlessly when I used some kernel 2.6.10 in Fedora Core 2. But, ever since I installed Fedora Core 4, it didn't work.

I explored for the reason, and found this answer,
"The linux kernel has stopped supporting philips webcam driver, as it was not released under GPL"
Just because the driver wasn't open source, it was removed from the kernel, and poor users like me were helpless.

Exploring a little more, I came to know that the driver consisted of two parts, PWC and PWCX. While PWC was open source, PWCX was not. So, there was sourcecode of PWC, which could be compiled and installed to support my hardware.

After some searching, I reached http://www.saillard.org/linux/pwc/RPMs/. Here, I found some RPMS for the kernel module for PWC driver. As my kernel was not listed, I downloaded pwc-10.0.6a-1.src.rpm.

Now, the task was simple, just compile and install.
rpm -hiv pwc*.rpm
cd /usr/src/redhat/SPECS/
rpmbuild -bb pwc.spec
cd /usr/src/redhat/RPMS/i386/
rpm -hiv kernel-modules-pwc*.rpm

It got installed correctly. Then, I plugged in the CAM, and run xawtv. But, unfortunately, the output was a blank window. I could not understand why it happened.

I tried to investigate the contents of the rpm.
$ rpm2cpio kernel-modules-pwc_2.6.12-1.1398_FC4smp-10.0.6a-1_fc4.i386.rpm | cpio -t
./lib/modules/2.6.12-1.1398_FC4smp
./lib/modules/2.6.12-1.1398_FC4smp/misc
./lib/modules/2.6.12-1.1398_FC4smp/misc/pwc.ko
$ cd /lib/modules/2.6.12-1.1398_FC4smp/
$ find . -name *pwc*
./misc/pwc.ko
./kernel/drivers/usb/media/pwc
./kernel/drivers/usb/media/pwc/pwc.ko

Then, I realized that the RPM is actually putting the driver in the misc directory of kernel modules, while its using the one in kernel/drivers/usb/media/pwc/. I just did,
$ cd /lib/modules/2.6.12-1.1398_FC4smp/
$ cp misc/pwc.ko kernel/drivers/usb/media/pwc/
Overwrite file 'pwc.ko' ? y

And now, it worked!! So anyone of you, with this hardware and a 2.6.x kernel, do what I did and be happy. Cheers.

3 Comments:

At 10:16 AM, Blogger Nirnimesh said...

Thanks for the quick steps to get this work. I remember it was a lot of pain to get it working earlier (in FC1). For convenience sake, I've prepared it's rpm (available here).

 
At 8:15 AM, Anonymous Anonymous said...

For convenience sake, I've prepared it's rpm.

Is this rpm good for 32 or 64 only?

 
At 10:33 AM, Blogger Anurag Singh Rana said...

you can follow steps I told using a src rpm. I think the rpm he built is for 64 bit only

 

Post a Comment

<< Home