[Interest] USB Webcams in Android?

Jason H jhihn at gmx.com
Tue Apr 10 17:09:30 CEST 2018


I'm wondering what it would take to get USB webcams working in Qt on Android. It seems that if the kernel already supports it, it will be listed as as /dev/v* device.

I'm also wondering what Qt needs to use the device? I plugged it in and it did not appear in QtMultimedia.availableCameras:  
[
  {"deviceId":"back","displayName":"Rear-facing camera","position":1,"orientation":270},
  {"deviceId":"front","displayName":"Front-facing camera","position":2,"orientation":90}
]

Additionally, it seems that many camera apps don't support USB cameras and USB camera apps don't support the built-in cameras. 
The only hint at what is going on is this line in logcat: 04-10 10:59:05.360 14692 14886 I USBMonitor: name=/dev/bus/usb/001/002,desc=86,busnum=1,devnum=2,rawDesc=[B at 6930dda


Many thanks!

Here's what my Android kernel is saying:
[ 2026.007529] PMI: smblib_vbus_regulator_enable: Enabling internal vbus regulator
[ 2026.014142] msm-dwc3 a800000.ssusb: DWC3 exited from low power mode
[ 2026.019444] xhci-hcd xhci-hcd.0.auto: xHCI Host Controller
[ 2026.019548] xhci-hcd xhci-hcd.0.auto: new USB bus registered, assigned bus number 1
[ 2026.026489] xhci-hcd xhci-hcd.0.auto: hcc params 0x0230fe65 hci version 0x110 quirks 0x00010010
[ 2026.026595] xhci-hcd xhci-hcd.0.auto: irq 732, io mem 0x0a800000
[ 2026.027069] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
[ 2026.027101] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[ 2026.027130] usb usb1: Product: xHCI Host Controller
[ 2026.027156] usb usb1: Manufacturer: Linux 4.4.88-gda039c93611c xhci-hcd
[ 2026.027182] usb usb1: SerialNumber: xhci-hcd.0.auto
[ 2026.035180] hub 1-0:1.0: USB hub found
[ 2026.036400] hub 1-0:1.0: 1 port detected
[ 2026.037148] xhci-hcd xhci-hcd.0.auto: xHCI Host Controller
[ 2026.037195] xhci-hcd xhci-hcd.0.auto: new USB bus registered, assigned bus number 2
[ 2026.037435] usb usb2: We don't know the algorithms for LPM for this host, disabling LPM.
[ 2026.037767] usb usb2: New USB device found, idVendor=1d6b, idProduct=0003
[ 2026.037798] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[ 2026.037825] usb usb2: Product: xHCI Host Controller
[ 2026.037851] usb usb2: Manufacturer: Linux 4.4.88-gda039c93611c xhci-hcd
[ 2026.037877] usb usb2: SerialNumber: xhci-hcd.0.auto
[ 2026.043081] hub 2-0:1.0: USB hub found
[ 2026.043804] hub 2-0:1.0: 1 port detected
[ 2026.342230] usb 1-1: new high-speed USB device number 2 using xhci-hcd
[ 2026.485458] usb 1-1: New USB device found, idVendor=a16f, idProduct=0304
[ 2026.485503] usb 1-1: New USB device strings: Mfr=2, Product=3, SerialNumber=0
[ 2026.485526] usb 1-1: Product: USB2.0 UVC PC Camera
[ 2026.485548] usb 1-1: Manufacturer: GenesysLogic Technology Co., Ltd.
[ 2026.545861] PMI: smblib_set_prop_use_external_vbus_output: VBUS output source: internal -> extern

walleye:/dev # ls -al v*
crw-rw---- 1 system camera 81, 128 1970-06-12 03:04 v4l-subdev0
crw-rw---- 1 system camera 81, 129 1970-06-12 03:04 v4l-subdev1
crw-rw---- 1 system camera 81, 138 1970-06-12 03:04 v4l-subdev10
crw-rw---- 1 system camera 81, 139 1970-06-12 03:04 v4l-subdev11
crw-rw---- 1 system camera 81, 140 1970-06-12 03:04 v4l-subdev12
crw-rw---- 1 system camera 81, 141 1970-06-12 03:04 v4l-subdev13
crw-rw---- 1 system camera 81, 142 1970-06-12 03:04 v4l-subdev14
crw-rw---- 1 system camera 81, 143 1970-06-12 03:04 v4l-subdev15
crw-rw---- 1 system camera 81, 144 1970-06-12 03:04 v4l-subdev16
crw-rw---- 1 system camera 81, 145 1970-06-12 03:04 v4l-subdev17
crw-rw---- 1 system camera 81, 146 1970-06-12 03:04 v4l-subdev18
crw-rw---- 1 system camera 81, 147 2018-04-10 09:47 v4l-subdev19
crw-rw---- 1 system camera 81, 130 1970-06-12 03:04 v4l-subdev2
crw-rw---- 1 system camera 81, 148 2018-04-10 09:47 v4l-subdev20
crw-rw---- 1 system camera 81, 131 1970-06-12 03:04 v4l-subdev3
crw-rw---- 1 system camera 81, 132 1970-06-12 03:04 v4l-subdev4
crw-rw---- 1 system camera 81, 133 1970-06-12 03:04 v4l-subdev5
crw-rw---- 1 system camera 81, 134 1970-06-12 03:04 v4l-subdev6
crw-rw---- 1 system camera 81, 135 1970-06-12 03:04 v4l-subdev7
crw-rw---- 1 system camera 81, 136 1970-06-12 03:04 v4l-subdev8
crw-rw---- 1 system camera 81, 137 1970-06-12 03:04 v4l-subdev9
crw------- 1 root   root   10,  95 1970-06-12 03:04 vga_arbiter
crw-rw---- 1 system camera 81,   0 1970-06-12 03:04 video0
crw-rw---- 1 system camera 81,   1 1970-06-12 03:04 video1
crw-rw---- 1 system camera 81,   2 1970-06-12 03:04 video2
crw-rw---- 1 system camera 81,   3 1970-06-12 03:04 video3
crw-rw---- 1 system camera 81,  32 1970-06-12 03:04 video32
crw-rw---- 1 system camera 81,  33 1970-06-12 03:04 video33
crw-rw---- 1 system camera 81,   4 2018-04-10 09:47 video4
crw-rw---- 1 system camera 81,   5 2018-04-10 09:47 video5
crw-rw-rw- 1 root   root   10,  47 1970-06-12 03:04 vndbinder



More information about the Interest mailing list