Through the previous Linux UVC&V4L2 Technology Brief Introduction (a) we understand the UVC and v4l2 simple knowledge.
Here is a description of the USB device's documentation: http://www.usb.org/developers/docs/devclass_docs/
So what do we need to do if we want to implement a UVC camera device?
I simply looked at the kernel configuration file for several CM projects, and now the V4L2 drive configuration options are open for these systems, but the config_usb_video_config option is not open, That is to say, in today's CM-supported models, the default is not to support the UVC camera.
This situation has caused great inconvenience to the developer, as a result of this. The UVC camera does not exist as a standard for an Android system.
So now the problem comes,
How can I make a device a UVC (USB video Class) device?
How can the Android system support the UVC camera device to work properly?
First, it is mentioned in the previous article that the UVC device can have a supported device list or use commands to see if the device is supported. Can we change our equipment so that it becomes a UVC camera?
Here, according to the results of the reading document, according to the conditions of the UVC device, there is a fixed architecture on the hardware. So assuming that the hardware is not a UVC device architecture, it is very difficult to convert a normal camera into a UVC camera.
Second, how can the Android system support the UVC camera?
1) First Open the V4L2 on the device
Config_video_dev=y
Config_video_v4l2_common=y
Config_video_media=y
Config_usb_video_class=y
Config_v4l_usb_drivers=y
Config_usb_video_class_input_evdev=y
2) Set/dev/video0 's permissions in/ueventd.xxxx.rc to 0666
3) This device must be a UVC-enabled camera
Before describing this part of the narrative, it is necessary to talk about how V4L2 works.
Next, the UVC driver is described.
Linux under uvc& Brief introduction of V4L2 technology (II.)