Android 在 Eclipse 中无法检测到 Sony Xperia
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/12053720/
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
Cannot detect Sony Xperia in Eclipse
提问by Damir
I am totally new at testing apps on devices, especially the Sony Xperia. I am testing apps using the Android emulator, but I have now a Sony Xperia. First I have connected the device to the laptop via USB. But the laptop couldn't detect my phone. Is a driver necessary for Eclipse to detect the phone?
我对在设备上测试应用程序完全陌生,尤其是索尼 Xperia。我正在使用 Android 模拟器测试应用程序,但我现在拥有 Sony Xperia。首先,我通过 USB 将设备连接到笔记本电脑。但是笔记本电脑无法检测到我的手机。Eclipse 检测手机是否需要驱动程序?
回答by Michell Bak
Download the correct driver for your phone, make sure your phone has enabled USB debugging and then connect it to proceed with the install.
为您的手机下载正确的驱动程序,确保您的手机已启用 USB 调试,然后将其连接以继续安装。
Download drivers from: http://developer.sonymobile.com/downloads/drivers/
从以下位置下载驱动程序:http: //developer.sonymobile.com/downloads/drivers/
回答by Damir
Even though this question was posted long time ago, I didn't find 100% correct answer from previous replies. Most of replies are useful, but here is one final step for debugging apps on Sony Xperia devices.
My Sony Xperia T has not been visible in Eclipse even though I installed PC Companion and in mobile phone, I set developers options debugging mode!
Xperiahas very strange option:
Settings > Xperia > USB Connectivity > USB connection mode
and select Mass storage mode (MSC).
Note that the USB cable must be unplugged to change this option.
By default, Media transfer mode (MTP) was selected. If MTP is selected even little bug is shown in notification bar debugging is not possible!
尽管这个问题是很久以前发布的,但我没有从以前的回复中找到 100% 正确的答案。大多数回复都很有用,但这是在 Sony Xperia 设备上调试应用程序的最后一步。
即使我安装了 PC Companion,我的 Sony Xperia T 在 Eclipse 中仍然不可见,而在手机中,我设置了开发人员选项调试模式!
Xperia有一个很奇怪的选项:
Settings > Xperia > USB Connectivity > USB connection mode
并选择Mass storage mode (MSC)。
请注意,必须拔下 USB 电缆才能更改此选项。默认情况下,选择了媒体传输模式 (MTP)。如果选择了 MTP,即使通知栏显示小错误也无法调试!
回答by Falo
These were my steps to solve the problem:
这些是我解决问题的步骤:
On SONY XPERIA Z
在索尼 XPERIA Z 上
- Enable USB debugging (http://developer.android.com/tools/device.html#setting-up)
- Settings > Developer > USB-Debugging = Enabled
- Settings > Xperia > USB Connectivity > USB connection mode = MSC
- Settings > Xperia > USB Connectivity > Install software = Disabled (!!!)
- 启用 USB 调试(http://developer.android.com/tools/device.html#setting-up)
- 设置 > 开发人员 > USB 调试 = 已启用
- 设置 > Xperia > USB 连接 > USB 连接模式 = MSC
- 设置 > Xperia > USB 连接 > 安装软件 = 禁用 (!!!)
On Windows7
在 Windows7 上
- Google USB drivers were already installed for another device
- Download XPERIA drivers from: http://developer.sonymobile.com/downloads/drivers/
- Connect XPERIA via USB
- Device manager > Unknown device > Install driver from downloaded file
- 已为另一台设备安装了 Google USB 驱动程序
- 从以下位置下载 XPERIA 驱动程序:http: //developer.sonymobile.com/downloads/drivers/
- 通过 USB 连接 XPERIA
- 设备管理器 > 未知设备 > 从下载的文件安装驱动程序
回答by Fedor Kazakov
Don't forget to enable usb debugging in the phone setting.
不要忘记在手机设置中启用USB调试。
回答by andiDeve
solution for sony Mobile usb driver for Window 7 After googling and more time spend on this we find the solution Sony tipo & Sony M mobile are detecting by eclipse . Steps are 1.install the latest sony companion 2- go to settings>>xperia>> connectivity>>USB connectivity mode>>MTP 3- restart eclipse and run your project Android Device Chooser show your device
适用于 Window 7 的 sony Mobile usb 驱动程序的解决方案 在谷歌搜索并花费更多时间之后,我们找到了 Sony tipo 和 Sony M mobile 通过 eclipse 检测的解决方案。步骤是 1.安装最新的索尼伴侣 2-进入设置>>xperia>>连接>>USB连接模式>>MTP 3-重新启动eclipse并运行您的项目Android设备选择器显示您的设备
donot forgot to check the usb debugging
不要忘记检查USB调试
回答by VonSchnauzer
This answer is more general to not finding your device. But if you have dead ADB processes running, you might have to kill them (and start a new one) in order to pick your device.
这个答案比找不到你的设备更通用。但是如果你有死的 ADB 进程在运行,你可能必须杀死它们(并启动一个新的)才能选择你的设备。
回答by Eva Fung
For me, it works when combining Damir's & Michell Bak's answers.
对我来说,它在结合 Damir 和 Michell Bak 的答案时起作用。
First need to change device form MTPmode to MSCmode as Damirmentioned, then download and install driverto your PC as Michell Bakmentioned.
首先需要将设备从MTP模式更改为Damir提到的MSC模式,然后像Michell Bak提到的那样下载并安装驱动程序到您的 PC 。
Most new Sony device default setting USB connection mode to MTP and the setting location is different from other android devices. Besides, driver can not install automatically and need to download form official site.
大多数新的索尼设备默认设置 USB 连接模式为 MTP,设置位置与其他 android 设备不同。另外驱动不能自动安装,需要到官网下载。
回答by dreamdeveloper
Steps to debug using Sony Xperia : Settings > Xperia > USB Connectivity > USB connection modeand select Mass storage mode (MSC). The USB cable must be unplugged to change this option. By default, Media transfer mode (MTP) was selected. Untick "Install software"
使用 Sony Xperia 进行调试的步骤: 设置 > Xperia > USB 连接 > USB 连接模式,然后选择大容量存储模式 (MSC)。必须拔下 USB 电缆才能更改此选项。默认情况下,选择了媒体传输模式 (MTP)。取消“安装软件”
回答by Einar
I had same problem with my Xperia Z3+ (android 5.02) with Android studio 1.3. I installed new drivers and XPeria Companion but it didn't help. However after I enabled hotspot via USB it started to work. Don't know if all of these was needed of if it was only the last one. Anyway I did 1. Settings->More...->Internetsharing hotspot->USB-sharing to on. 2. In the pop-up accept USB debugging.
我的 Xperia Z3+ (android 5.02) 和 Android studio 1.3 有同样的问题。我安装了新的驱动程序和 XPeria Companion,但没有帮助。但是,在我通过 USB 启用热点后,它开始工作了。不知道如果只有最后一个,是否需要所有这些。无论如何,我做了 1. 设置->更多...->互联网共享热点->USB共享打开。2.在弹出的接受USB调试。
回答by FaddishWorm
Yes, eclipse needs drivers. You need to install drivers for the phone, and then restart eclipse. You then need to add the xperia through the device manager in eclipse.
是的,eclipse 需要驱动程序。您需要为手机安装驱动程序,然后重新启动eclipse。然后需要通过eclipse中的设备管理器添加xperia。
Are you running windows??
你在运行windows吗??