Implementation of driver and collection program of USB camera Based on Embedded Linux

Source: Internet
Author: User

My embedded hardware platform: huaheng 2440 Development Board, software platform: linux.2.4.20 kernel, PC, Red Hat 9

Camera: z0c301p of xingwei, which has a large market share and is said to account for 70%

Procedure:

1. Download the driver from http://mxhaard.free.fr/and install a patch on usb-2.4.31le06.patch.

2 put the usb-2.4.31LE06.patch under/hharm2440/linux-2.4.20/driver/USB/, and then execute

Tar-xvzf usb-2.4.31LE06.patch

Patch-P1 <usb-2.4.31LE06.patch

After unzipping and patching, The spca5xx folder will appear in the USB directory, and some errors may occur. My error is in makefile and you can modify it as prompted. During the patch process, the modification method will be written to the makefile. rej and config. In. rej files, and the content in these two files will be added to the makefile and config. In files. Config. In. rej is not necessarily generated. If no result is generated, you do not need to modify config. In again.

2 compile the kernel, enter/hharm2440/linux-2.4.20, and execute make menuconfig. Select v4l item (*), spca5xx ...... the item is (M), USB for support (*), save and exit

3. Execute make Dep; Make zimage; Make modules; load the new kernel zimage, start the new kernel, and load the spca5xx. O under the spca5xx directory.

You can.

4. register the device node, mknod/dev/video0 C 81 0

5. Use the v4l API to compile the collection program. The following figure shows the collected images.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.