I have a Oneplus 1 and I thopught on implementing an API where the android device acts as a virtual USB hub.

What I want to achieve is to have my Android apps to emulate various USB devices. The reason I want to do this is for example:

  1. to emulate a USB stick or a usb floppy driver or a DC/DVD drive, for booting Linux images
  2. As an hdmi capture device via a usbc-to-hdmi cable.
  3. various hardware emulation for code debugging or compartibility (eg for implementing a driver device).

The reason why I want to do this is because I want to have a portable tool for computer repairs and computer hardware analysis. The idea is for the android device via an api and a custom application to emulate a USB device therefore my computer will recognize the device not as a phone but as another one.

Is there a ready-to-use Android (linux) kernel module that will allow to emulate USB devices?

  • Android does not seem to have modules ready for this: it is pretty focussed on the end-user mass market. Kernel modules are supported, but intended for SoC or device manufacturer use. This is more a question for Stack Overflow, or a custom ROM site. Oct 27, 2023 at 18:11
  • Possibly related: Can a device pretend to be a USB keyboard? (the answers might give some insights)
    – Andrew T.
    Oct 27, 2023 at 18:13


You must log in to answer this question.

Browse other questions tagged .