解决方法1:
lsusb列出设备id
sudo vim /etc/udev/rules.d/51-android.rules
SUBSYSTEM="usb", ATTRS{idVendor}=="0e8d", ATTRS{idProduct}=="2003", MODE="0666"
sudo chmod a+r /etc/udev/rules.d/51-android.rules
systemctl restart udev
adb kill-server
adb start-server
adb devices
方法2:
sudo vim /etc/udev/rules.d/51-android.rules
SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", MODE="0666"
sudo chmod a+r /etc/udev/rules.d/51-android.rules
systemctl restart udev
adb kill-server
adb start-server
adb devices
参考资料
https://developer.android.google.cn/studio/run/device.html