Feb 04/2023: Motorola has already implemented support for turning its Android phones into UVC webcams! The Motorola Edge 20 is recognized as a “Motorola UVC Camera” when you set the USB mode to “Webcam” and plug it into a PC.
I hope this is what the experience will be like in Android 14 because it looks really simple! You can see another example of the Motorola Edge 20 being recognized as a UVC webcam in this thread.
Feb 02/2023: Using an Android phone as a webcam became really popular during the pandemic, but you’ve typically had to install a third-party app to do so. You may not have to do this in the future, though, as Google is adding support for turning Android devices into USB webcams!
Android is adding a new “DeviceAsWebcam” service that “turns an android device into a webcam.” Specifically, this refers to Android devices with kernel support for the standard UVC (USB video class) gadget mode.
The system property ‘ro.usb.uvc.enabled‘ will be used to toggle UVC gadget functionality on Android devices. It’s only readable by system apps, and specifically, the Settings app and USB gadget HAL will read it.
Android has supported external plug-and-play USB webcams for a while now, but support for using your phone as a UVC gadget is new, though there are plenty of third-party apps that accomplish similar functionality.
Your Android device’s kernel may need to be compiled with CONFIG_USB_CONFIGFS_F_UVC=y for this new functionality to work. This is the case on GKI kernels since android12-5.10.
If you have a device with that config set, you can enable your device’s UVC gadget functionality right now with root access and an app called USB Gadget Tool.
Do note you’ll still need an app/service to send video data from the camera for the host device to read from. I don’t know what that’ll look like in Android 14 if this feature lands at all in that release, but it’s something I’ll definitely look out for!