Pages

Sunday, January 30, 2011

Camera capture using OpenCV

I had a Logitech C120 camera lying around and found that Angstrom had drivers for it. It was about 1:00am and I couldn't wait till I captured an image.

OpenCV is a popular library for image processing. I found this post which got me started with OpenCV. But you must also install opencv-dev to get the header files or the program will not compile.

To get OpenCV:

opkg update
opkg install task-native-sdk cpp gccmakedep
opkg install python-distutils python-compile python-compiler python-devel
opkg install ffmpeg-dev
opkg install opencv
opkg install opencv-dev
My wireless connection was not very good, so I got several package download failures with "wget returned 1". I just switched to USB Ethernet and it went smooth.

Also, if you get "But that file is already provided by package xxx" errors while installing opencv-dev, just uninstall opencv and try again from step 5. I am not sure what the problem was, but it worked the second time.

Finally, around 3:00am I captured the first images. I went to bed both satisfied and eager to get back to my desk and track a ball or something!

No comments:

Post a Comment