I need to access both ADB and MTP from one emulated device. May be there is some ready-made solution that can emulate android device via usb device emulating? All that I found is an android kernel gadget https://android.googlesource.com/kernel/common/+/59c75bcf603f355ff34282422e8c3f2165b9d5f2/drivers/usb/gadget/android.c It can be useful, but it's not the easiest way to do that.

  • 1
    You can not access ADB via MTP. MTP is a lightweight/limited file transfer protocol (most user would call it crippled). It is limited to one operation at the same time. ADB is an universal protocol for accessing Android devices via USB. It supports shell access, file transfer, port forwarding and so on. It is multiplexed and supports all features at the same time with multiple commands.
    – Robert
    Commented Dec 12, 2022 at 14:19
  • Yes, you're right, I messed up. I corrected the question. I am interested in emulating a device that will be able to work with two protocols via USB. Yes, it is very important that the device emulates connections over both protocols via USB.
    – DarkLex
    Commented Dec 12, 2022 at 19:28


You must log in to answer this question.

Browse other questions tagged .