简体   繁体   English

Chrome的远程调试(USB调试)不适用于运行android 4.3的三星Galaxy S3

[英]Chrome's remote debugging (USB debugging) not working for Samsung Galaxy S3 running android 4.3

Ever since I upgraded my Samsung Galaxy S3 to android 4.3 (from 4.1.2) I am unable to use Chrome's remote debugging for android (more details here ). 自从我将Samsung Galaxy S3升级到android 4.3(从4.1.2开始)以来,我无法使用Chrome的远程调试android( 此处有更多详细信息)。

I have the developer options and USB debugging enabled on my phone, and this worked perfectly fine on android 4.1.2. 我在手机上启用了开发人员选项和USB调试功能,这在android 4.1.2上运行得非常好。 Now, when I connect my phone to my PC, it simply connects as a media storage device and is not discovered as a USB device by chrome. 现在,当我将手机连接到PC时,它只是作为媒体存储设备连接,而不是通过chrome发现的USB设备。

I am ruling out any problems with chrome as I could USB debug with a Google Nexus4, also, looking at some other thread (here and elsewhere) it seems to be a problem with Samsung's 4.3 upgrade. 我正在排除使用Chrome的任何问题,因为我可以使用谷歌Nexus4进行USB调试,同时,看看其他线程(这里和其他地方)它似乎是三星4.3升级的问题。

Any pointers to get this working? 有任何指示让这个工作?

My devices stopped working as Chrome de-activated the now depracated ADB plugin as it's built in dev-tools now. 我的设备停止工作,因为Chrome已经取消激活现在已经被删除的ADB插件,因为它现在已经在dev-tools中内置了。

I downloaded the SDK and followed the instructions at Chrome Developers . 我下载了SDK并按照Chrome开发者的说明进行操作。 How ever I found the instructions served by Alphonso out not to be sufficient and I did it this way on Windows 8: 我怎么才发现Alphonso提供的指令不够,我在Windows 8上这样做了:


  1. Download Android SDK here ("SDK Tools Only" section) and unzip the content. 在此处下载Android SDK (“仅限SDK工具”部分)并解压缩内容。
  2. Run SDK Manager.exe and install Android SDK platform tools 运行SDK Manager.exe并安装Android SDK平台工具
  3. Open up the Command prompt (simply by pressing the windows button and type in cmd.exe) 打开命令提示符 (只需按下Windows按钮并输入cmd.exe)
  4. Enter the path with ex: cd c:/downloads/sdk/platform-tools 输入ex: cd c:/ downloads / sdk / platform-tools的路径
  5. Open ADB by typing in adb.exe 键入adb.exe打开ADB
  6. Run the following command by typing it and pressing enter: adb devices 通过键入并按Enter: adb devices运行以下命令
  7. Check if you get the prompt on your device, if you still can't see your phone in Inspect Devices run the following commands one by one (excluding the ") " adb kill-server " " adb start-server " " adb devices " 检查您的设备是否收到提示,如果您仍然无法在Inspect Devices中看到您的手机,请逐个运行以下命令(不包括“)” adb kill-server “” adb start-server “” adb devices

I had major problems and managed to get it working with these steps. 我遇到了重大问题,并设法让它使用这些步骤。 If you still have problems, google the guide Remote Debugging on Android with Chrome and check for the part about drivers. 如果您仍有问题,请使用Chrome浏览Android上的远程调试指南并检查有关驱动程序的部分。 I had problems with my Samsung Galaxy Nexus that needed special drivers to be compatiable with ADB. 我的三星Galaxy Nexus有问题,需要特殊的驱动程序才能与ADB兼容。


Update 更新

If you are using Windows 10 and couldn't find the link to download Android SDK ; 如果您使用的是Windows 10,但找不到下载Android SDK的链接; you may skip #1 and #2. 你可以跳过#1和#2。 All you need is activate " Android Debug Bridge ". 您只需激活“ Android Debug Bridge ”即可。 Go straight to #3 - #7 after download and execute " platform-tools "( https://developer.android.com/studio/releases/platform-tools.html ) 下载后直接进入#3 - #7并执行“ platform-tools ”( https://developer.android.com/studio/releases/platform-tools.html

Having attempted to follow Valros.nu's answer, i discovered that the sdk download is now bundeled with androind studio, in an 840MB exe installer. 试图按照Valros.nu的回答,我发现sdk下载现在与一个840MB的exe安装程序中的androind工作室一起使用。

As all you need for this particular program is the adb program, you can get this in a standalone installer from the xda guys: 因为这个特定程序所需要的只是adb程序,你可以从xda人员的独立安装程序中获得:

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

Note that you do not need to type adb.exe , simply type adb devices into the command prompt that is launched after install. 请注意,您无需键入adb.exe ,只需在安装后启动的命令提示符中键入adb devices即可。

Also, i had to unplug and replug in my samsung s4 to get the remote debugging prompt to appear on the phone 此外,我不得不拔掉并重新插入我的samsung s4以获得远程调试提示出现在手机上

After looking around a little longer I came across this . 看了一会儿后,我发现了这个 Apparently, there isn't a solution to this issue yet, but there is a workaround - going back to the legacy workflow . 显然,目前还没有这个问题的解决方案,但有一个解决方法 - 回到遗留工作流程

The legacy workflow did work for me, and the only additional thing I had to do was to go to the platform-tools folder from android SDK download, open a command window here and run command "adb devices". 传统的工作流程对我有用,我唯一需要做的就是从android SDK下载转到platform-tools文件夹,在这里打开一个命令窗口并运行命令“adb devices”。 This caused the computer RSA key fingerprint panel to pop on my mobile screen, and after granting permission, the device showed up under Chrome's Inspect page. 这导致计算机RSA密钥指纹面板在我的移动屏幕上弹出,并且在授予许可后,该设备显示在Chrome的Inspect页面下。

Turns out that it was not an issue caused by mobile OS upgrade but by Chrome (I was thrown off by the fact that it worked on my Nexus4 somehow). 事实证明,这不是由移动操作系统升级引起的问题,而是由Chrome引起的(因为它以某种方式在我的Nexus4上运行而被抛弃)。 In the older versions of Chrome there was't a need to download the 500 odd mb Android SDK, as it supported an ADB plugin. 在早期版本的Chrome中,无需下载500多分贝的Android SDK,因为它支持ADB插件。 But with latest version of Chrome, I guess, going legacy is the only way to go. 但是对于最新版本的Chrome,我想,遗留下来是唯一的出路。

I have Samsung Galaxy S3 and it was not showing in the "Remote devices" tab nor in chrome://inspect. 我有三星Galaxy S3,它没有显示在“远程设备”选项卡中,也没有显示在chrome:// inspect中。 The device did show in Windows's Device Manager as GT-I9300, though. 不过,该设备确实在Windows的设备管理器中显示为GT-I9300。 What worked for me was: 对我有用的是:

  1. Plug the mobile phone to the front USB port 将手机插入前置USB端口
  2. On my phone, click the notification about successful connection 在我的手机上,单击有关成功连接的通知
  3. Make sure the connection type is Camera (PTP) 确保连接类型为Camera(PTP)
  4. On my Windows machine, download installer from https://github.com/koush/UniversalAdbDriver 在我的Windows计算机上,从https://github.com/koush/UniversalAdbDriver下载安装程序
  5. Run it :) 运行 :)
  6. Open cmd.exe 打开cmd.exe
  7. cd "C:\\Program Files (x86)\\ClockworkMod\\Universal Adb Driver"
  8. adb devices
  9. Open Chrome in both mobile phone and Windows machine 在手机和Windows机器上打开Chrome
  10. On Windows's machine navigate to chrome://inspect - there, after a while you should see the target phone :) 在Windows的机器上导航到chrome:// inspect - 在那之后,你会看到目标手机:)

I'm not sure if it affected the whole flow somehow, but at some point I've installed, and later uninstalled the drivers from Samsung: http://www.samsung.com/us/support/downloads/ > Mobile > Phones > Galaxy S > S III > Unlocked > http://www.samsung.com/us/support/owners/product/galaxy-s-iii-unlocked#downloads 我不确定它是否会以某种方式影响整个流程,但在某些时候我已安装,后来从三星卸载了驱动程序: http//www.samsung.com/us/support/downloads/ > Mobile> Phones > Galaxy S> S III>解锁> http://www.samsung.com/us/support/owners/product/galaxy-s-ii​​i-unlocked#downloads

对我来说,解决方案是下载Android SDK并启动启动adb守护程序的adb devices

I know this is an older question, but I thought I would also post my solution: 我知道这是一个较老的问题,但我想我也会发布我的解决方案:

  • Update your Chrome on your phone and on your PC. 在手机和PC上更新Chrome。
  • Even if it says you have the latest driver for your device inside Device Manager, you may need an alternative. 即使它说您在设备管理器中拥有最新的设备驱动程序,也可能需要替代方案。 Google latest Samsung drivers and try updating your drivers. 谷歌最新三星驱动程序,并尝试更新您的驱动

For me, the menu item Inspect Devices wasn't available (not shown at all). 对我来说,菜单项Inspect Devices不可用(根本没有显示)。 But, simply browsing to chrome://inspect/#devices showed me my device and I was able to use the port forward etc. I have no idea why the menu item is not displayed. 但是,只需浏览chrome:// inspect /#devices向我展示了我的设备,我就可以使用端口转发等。我不知道为什么菜单项没有显示。

Phone: Android Galaxy S4 电话:Android Galaxy S4

OS: Mac OS X 操作系统:Mac OS X.

I had success after using ade.exe as explained above, plus using the latest version of Chrome Canary . 我使用了如上所述的ade.exe,并使用最新版本的Chrome Canary后取得了成功。 Apparently your desktop version of Chrome has to be higher than the version running on your Android device. 显然,您的桌面版Chrome必须高于Android设备上运行的版本。

In case it helps anyone I will post what worked for me. 万一它可以帮助任何人,我会发布对我有用的东西。

I had to plug my S3 into a direct USB port of my PC for it to prompt me to accept the RSA signature. 我不得不将我的S3插入PC的直接USB端口,以便它提示我接受RSA签名。 I had my S3 plugged into a hub before then. 在此之前我将S3插入集线器。

Now the S3 is detected when using both the direct USB port of the PC and via the hub. 现在,当使用PC的直接USB端口和集线器时,都会检测到S3。

NOTE - You may need to also run adb devices from the command line to get your S3 to re-request permission. - 您可能还需要从命令行运行adb devices以使S3重新请求权限。

D:\apps\android-sdk-windows\platform-tools>adb devices
List of devices attached
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
9283759342847566        unauthorized

...accept signature on phone... ......接受电话签名......

D:\apps\android-sdk-windows\platform-tools>adb devices
List of devices attached
9283759342847566        device

Those who updated their device to Android 4.2 Jelly Bean or higher or having a 4.2 JB or higher android powered device, will not found the Developers Options in Settings menu. 那些将他们的设备更新到Android 4.2 Jelly Bean或更高版本或拥有4.2 JB或更高版本的Android设备的用户将无法在“设置”菜单中找到“开发人员选项”。 The Developers Options hide by default on 4.2 jelly bean and later android versions. 开发人员选项默认隐藏在4.2 jelly bean和更高版本的android版本中。 Follow the below steps to Unhide Developers Options. 按照以下步骤取消隐藏开发人员选项。

  1. Go to Settings>>About (On most Android Smartphone and tablet) OR 转到设置>>关于(在大多数Android智能手机和平板电脑上)或

Go to Settings>> More/General tab>> About (On Samsung Galaxy S3, Galaxy S4, Galaxy Note 8.0, Galaxy Tab 3 and other galaxy Smartphone and tablet having Android 4.2/4.3 Jelly Bean) OR 转到设置>>更多/常规选项卡>>关于(在三星Galaxy S3,Galaxy S4,Galaxy Note 8.0,Galaxy Tab 3和其他具有Android 4.2 / 4.3 Jelly Bean的Galaxy智能手机和平板电脑上)或

Go to Settings>> General>> About (On Samsung Galaxy Note 2, Galaxy Note 3 and some other Galaxy devices having Android 4.3 Jelly Bean or 4.4 KitKat) OR 转到设置>>常规>>关于(在三星Galaxy Note 2,Galaxy Note 3和其他一些具有Android 4.3 Jelly Bean或4.4 KitKat的Galaxy设备上)或

Go to Settings> About> Software Information> More (On HTC One or other HTC devices having Android 4.2 Jelly Bean or higher) 2. Now Scroll onto Build Number and tap it 7 times repeatedly. 转到设置>关于>软件信息>更多(在HTC One或其他具有Android 4.2 Jelly Bean或更高版本的HTC设备上)2。现在滚动到Build Number并重复点击7次。 A message will appear saying that u are now a developer. 将显示一条消息,说您现在是开发人员。

  1. Just return to the previous menu to see developer option. 只需返回上一个菜单即可查看开发者选项。

Credit to www.androidofficer.com 感谢www.androidofficer.com

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM