OV2640 (i.MX31)

Aus BECOM Systems Support
Zur Navigation springen Zur Suche springen

Hardware Connection

Connect the Video-In Module to the Development Board. Then, connect the camera to the Adapter Board.

Kernel Configuration

To enable the camera, enter the kernel configuration, change to Device Drivers -> .... !!TODO!! and disable the TVP5150 chip (N). Then build the driver for the ov2640camera as a module (M). Compile the kernel and reboot the target.

Testing the camera

To test the camera, make sure a display is connected and working. Open a session on the target and enter the following commands:

modprobe mxc_v4l2_in
modprobe ov2640_camera
/unit_tests/mxc_v4l2_test/mxc_v4l2_overlay.out -ow 320 -oh 240

You should now see the camera image on the display. Depending on the orientation of the display, you might want to rotate the image by using -r (1-4) parameter, e.g.

/unit_tests/mxc_v4l2_test/mxc_v4l2_overlay.out -ow 320 -oh 240 -r 4

You can use the other tests in /unit_tests/mxc_v4l2_test/ to capture a video in raw format (YUV) or capture still images. Alternatively, you can look the the MPEG4Encoder Section to capture video from the camera and directly store it in a compressed mpeg4 format. Anyway, it is recommended to test the camera using the overlay mode first.