getting the lenovo sl300 camera to work on linux
I recently got a Lenovo SL300 Laptop, with a built in camera and was pretty keen to get onto using the camera with Skype, but it wouldn’t work – I couldn’t get a video feed from the camera. To cut a long story short, after two days of Googling and playing around I found a solution (though I can’t remember where I found it) – here’s how!
Tested on (K)Ubuntu Hardy & Intrepid (See bottom for Jaunty fix)
By default the webcam works on all Linux kernels 2.6.25+. However, the problem is that when the kernel loads the uvcvideo module, it loads it with the wrong parameters.
To correct this first unload the uvcvideo module:
~# sudo modprobe -r uvcvideo
Then reload the module with the correct parameter:
~# sudo modprobe uvcvideo quirks=16
Exactly what quirks are, I’m not sure – all I know is that various values for the quirks parameter work (I tried up to 50) without any noticeable performance difference.
Automating the Process
Now one would expect that you would want to automate this process and that’s also really simple – all you need to do is add an option to pass the quirks parameter to your kernel when the module is loaded. Exactly how you do this might vary depending on your linux distribution.
On Ubuntu do the following:
~# cd /etc/modprobe.d
~# nano options
At the bottom add the following line:
options uvcvideo quirks=16
And that’s it! Either reload the module with modprobe -r uvcvideo or restart your computer, and you won’t have to worry about it again!
I’ve only tested this solution on the Lenovo SL300 running Kubuntu Hardy and Intrepid, but I’m pretty sure it will work with all UVC webcams which aren’t displaying a picture.
Update: Upgrading to Jaunty breaks this fix. I think the reason is that modprobe no longer makes use of the options file, but instead replaces it with a series of conf files. To get the camera working again do the following:
~# cd /etc/modprobe.d
~# sudo nano uvcvideo.conf
Once again add the following line:
options uvcvideo quirks=16
And then reload the uvcvideo module with “sudo modprobe -r uvcvideo” and then “sudo modprobe uvcvideo”
Edit: If anyone successfully used this solution on a SL400 or SL500, please let me know.










Recent Comments