zoukankan      html  css  js  c++  java
  • Ubuntu下 连接Android 设备时无法识别

    问题:Linux下,连接 Android 设备进行调试运行APP时, 一般情况下无法识别

    解决方案:

    打开终端(快捷键:Ctrl+Alt+T),输入:

      sudo -s
      adb kill-server
      adb start-server
      * daemon not running. starting it now *
      * daemon started successfully *
    

    见到* *中的提示时,说明 kill start 成功

    前提条件:在Android真机中打开了debug模式

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

    List of devices attached

    ???????????? no permissions

    解决方案:

    root后查看USB设备:

    $ lsusb

    Bus 002 Device 006: ID 1ea7:0002
    Bus 002 Device 004: ID 04f2:b230 Chicony Electronics Co., Ltd
    Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
    Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 001 Device 010: ID 04e8:6860 Samsung Electronics Co., Ltd
    Bus 001 Device 003: ID 138a:003c DigitalPersona, Inc
    Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

    列表中,Bus 001 Device 010: ID 04e8:6860 Samsung Electronics Co., Ltd. 这一行为SamSung手机的usb使用端口,记录一下,id为04e8。

    $sudo vim /etc/udev/rules.d/70-android.rules

    加入以下内容:

    SUBSYSTEM=="usb", ATTRS{idVendor}=="04e8", ATTRS{idProduct}=="6860",MODE="0666"

    ID 04e8 就是idVendor ,6860就是 idProduct

    重启udev:

    $sudo chmod a+rx /etc/udev/rules.d/70-android.rules
    $sudo service udev restart

    重新启动adb server:
      拔掉usb,重新连上再执行:

    sudo adb kill-server
    adb devices

  • 相关阅读:
    如何在 Windows 7 安裝 SharePoint Server 2010
    SharePoint 2010 WSP包部署过程中究竟发生什么?
    SharePoint 2010 部署 WSP 包
    SharePoint 2010在win7 x64 安装
    在Sharepoint2010中发布VS2010开发的WebPart
    在User Profile Service中配置AD的同步连接
    Sharepoint数据库存储过程
    SharePoint对象模型性能考量
    对SharePoint 2007数据库中一些数据表的使用
    SharePoint Services 数据库表
  • 原文地址:https://www.cnblogs.com/willyan/p/2207326.html
Copyright © 2011-2022 走看看