Tuesday, December 12, 2006

Fedora Core 3 Webcam

I have a server with Fedora Core 3 on it. I decided I wanted to set it up with a webcam for viewing my birdfeeder. I had an old IBM webcam that I hooked up. It popped right up on the USB port. SO the real question is how to pull the data.

I found a spiffy app from Intel referenced here.


Sure enough, it compiled on my machine. It wouldn't work with any format but ppm though, so I pulled down a copy of ImageMagick for Fedora Core 3 (as an rpm), installed it, and then added my own little 'snap' script wrapper:

/usr/local/bin/vidcat -f ppm -o /tmp/test.ppm
/usr/bin/convert /tmp/test.ppm /tmp/test.jpg
cp /tmp/test.jpg /var/www/html/pics/

I added this to my crontab, and voila, an automagically updating webcam.

No comments: