我正在按照以下说明为 Raspberry Pi 3 构建 Nougat AOSP 映像:https ://github.com/tab-pi/platform_manifest 。我有一个兼容 UVC 的USB 网络摄像头 (Logitech C525),我想通过Android Camera API访问它。
到目前为止,网络摄像头在UsbManager.getDeviceList()中可见,但Camera.getNumberOfCameras()返回 0。
我已经自定义了内核,以便/dev/video0
在插入网络摄像头时出现具有适当权限的显示:
$ adb shell ls -l /dev/video0
crw-rw---- 1 system camera 81, 0 2018-09-20 10:16 /dev/video0
我尝试针对我的 AOSP 树构建以下 HAL,但它们都失败了:
https://github.com/jollen/libv4l2-android:
fatal error: 'ui/CameraHardwareInterface.h' file not found
https://github.com/antmicro/android-camera-hal:
error: use of undeclared identifier 'kMaxStride'
no member named 'I422ToABGRRow_NEON' in namespace 'libyuv'
https://github.com/aosp-mirror/platform_hardware_libhardware/tree/master/modules/camera/3_4
ninja: error: 'out/target/product/rpi3/obj/STATIC_LIBRARIES/libgtest_prod_intermediates/export_includes', needed by 'out/target/product/rpi3/obj/SHARED_LIBRARIES/camera.v4l2_intermediates/import_includes', missing and no known rule to make it
简而言之,如何通过 Raspberry Pi 上的 Android Camera API 访问 USB 摄像头?