解决Linux下adb devices找不到设备

Ubuntu下USB连接Android手机后,使用adb devices 出现如下:
 

List of devices attached
 

解决方法:

1

$lsusb

Bus 002 Device 002: ID 8087:8000 Intel Corp. 

Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 001 Device 002: ID 8087:8008 Intel Corp. 

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

Bus 003 Device 047: ID 1782:4012 Spreadtrum Communications Inc. 

Bus 003 Device 003: ID 413c:2107 Dell Computer Corp. 

Bus 003 Device 002: ID 0000:0538  

Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

找到手机设备对应的ID,有些手机没有明显提示,可以通过插拔数据线对比出现的id号。

列表中,Bus 003 Device 047: ID 1782:4012 Spreadtrum Communications Inc. 为插入手机设备的usb使用端口,记录下来,id为1782。

2.

$sudo gedit ~/.android/adb_usb.ini,

编辑该文件,加入0x1782

0x1782

3.

$sudo service udev restart

4.

重新启动adb server
adb kill-server
adb start-server
adb devices 

 亲测有效~

猜你喜欢

转载自blog.csdn.net/qq_34149526/article/details/82782804