使用 USB 数据线连接两部 Android 手机

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/25759365/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-20 09:42:39  来源:igfitidea点击:

Connect two Android phones with USB cable

android

提问by mmm2006

I want to connect two phones with USB cable and use ADB command like adb devices, adb shellfrom one phone, just like between PC and an Android phone. I tried with OTG supported cable which has two micro USB plugin, but it didn't work. Trying with another common cable (not OTG) with two micro USB plugin didn't work too. adb devicesalways fails with message "no device is attached at all" in both Phone A and Phone B.

我想用 USB 线连接两部手机并使用 ADB 命令,例如adb devicesadb shell从一部手机,就像在 PC 和 Android 手机之间一样。我尝试使用 OTG 支持的电缆,它有两个微型 USB 插件,但没有用。尝试使用带有两个微型 USB 插件的另一条普通电缆(不是 OTG)也不起作用。adb devices在电话 A 和电话 B 中总是失败并显示消息“根本没有连接设备”。

Anyone has experience about this? What kind of cable is needed?

任何人都有这方面的经验?需要什么样的电缆?

回答by Metehan

It is possible between some phones.

在某些手机之间是可能的。

  1. But at least one of them must have OTG support.
  2. and you need an OTG connector.(also a USB cable)
  1. 但至少其中之一必须有 OTG 支持。
  2. 并且您需要一个 OTG 连接器。(还有 USB 数据线)

Check the following link for detailed explanation:

查看以下链接以获取详细说明:

http://forum.xda-developers.com/showthread.php?t=2640456

http://forum.xda-developers.com/showthread.php?t=2640456



I'll be quoting the detailed explanation just in case the link gets broken:

我将引用详细说明,以防链接断开:

Yes if u need to transfer data between two phones like GBs of data n u u have atleast one phone that supports OTG and u been looking for pc to transfer data or been trying to use wifi share apps trust me this is a solution to npc-less transfers and EVEN U CAN BORTOW YOUR FRIENDS BATTERY CHARGE IF YOU ARE RUNNING LOW ON BATTERY!!!!!!

With just an OTG n a USB cable you CAN transfer data and battery charge between two phones!!

youl need:

A) 2 phones (atleast one with OTG support)

B)OTG connector

C)Usb cable.

D)file explorer like es file explorer

Here on il refer the phone that contains data and charge as "host" phone n to phone to be transferred as "second" phone.

If your second phone is a xperia device then go to settings ->xperia connectivity ->usb connectivity

Change the usb connectivity mode from "MTP" to "MSC"..

Steps:

1)Just connect OTG cable to host phone...

2)The second phone connect usb cable.. N the pc usb part.. Which u connect to pc...connect it to the OTG

REMEMBER3)In the second phone select ur mass storage option!!

4) use file explorer (I used Es file explorer coz its the best I used)

BINGO.. On host phone u can see the memory card of second phone as "usbdisk"...plus.. The second phone will charge battery from first phone...

Worked on

my xperia Z1 as host and micromax a65 as second phone..

my xperia Z1 as host and micromax a116 as second phone..

my xperia Z1 as host and xperia M as second phone..

my xperia M as host and xperia z1 as second phone..

Well all permutations of these phones..

是的,如果您需要在两部手机之间传输数据,例如 GB 数据,您至少有一部支持 OTG 的手机,并且您一直在寻找 pc 来传输数据或一直在尝试使用 wifi 共享应用程序相信我,这是无 npc 的解决方案如果您的电池电量不足,您甚至可以借用您朋友的电池电量!!!!!!!

只需一根 OTG na USB 电缆,您就可以在两部手机之间传输数据和电池电量!!

你需要:

A) 2 部手机(至少一部支持 OTG)

B)OTG 连接器

C) USB 电缆。

D)文件资源管理器,如es文件资源管理器

在这里,我将包含数据和充电的手机称为“主机”手机,将要传输的手机称为“第二”手机。

如果您的第二部手机是 xperia 设备,请转到设置 -> xperia 连接 -> USB 连接

将 USB 连接模式从“MTP”更改为“MSC”。

脚步:

1) 只需将 OTG 电缆连接到主机电话...

2)第二部手机连接 USB 电缆.. N 电脑 USB 部分.. 你连接到电脑...连接到 OTG

记住3) 在第二部手机中选择你的大容量存储选项!!

4)使用文件资源管理器(我使用了 Es 文件资源管理器,因为它是我用过的最好的)

宾果游戏.. 在主机手机上,您可以看到第二部手机的存储卡为“usbdisk”...加上.. 第二部手机将从第一部手机充电...

从事

我的 xperia Z1 作为主机和 micromax a65 作为第二个手机..

我的 xperia Z1 作为主机和 micromax a116 作为第二个手机..

我的 xperia Z1 作为主机,xperia M 作为第二部手机..

我的 xperia M 作为主机,xperia z1 作为第二部手机..

那么这些手机的所有排列..

回答by shiva

I never tried this. But after reading the post, i think you have to save settings in your second phone as mass storage. Then you can access this phone's memory in the host device. In the host device have you installed any file explorer like file manager or es explorer. Then i think you should be able to see this phone's memory. Thanks shiva

我从来没有试过这个。但是看完这篇文章后,我认为您必须将第二部手机中的设置保存为大容量存储。然后您可以在主机设备中访问此手机的内存。在主机设备中,您是否安装了任何文件资源管理器,如文件管理器或 es 资源管理器。那我想你应该可以看到这款手机的内存了。谢谢湿婆