zoukankan      html  css  js  c++  java
  • Nexus One USB in Ubuntu 9.10

    http://alan.lamielle.net/2010/01/22/nexus-one-usb-in-ubuntu-9-10

    My shiny new Google Nexus One wasn’t connecting properly over USB to my Ubuntu 9.10 (Karmic) notebook using the Android SDK.  Here’s how I fixed it.

    After a few days of debating whether or not to buy a Nexus One, I finally gave in a bought one.  Rachael ended up getting a Droid Eris (Verizon) for Christmas, so in the course of a few weeks I gained access to two fantastic Android-powered phones.  I had been compiling a list of mobile application ideas and the fact that I now have the hardware to test on motivated me to start looking into Android development.

    After getting the Android SDK setup I needed to connect my N1 and push an application to it for testing on real hardware.  I found some Android documentation that discussed connecting up an Android device over USB.  However, after following the steps on this page, I was still seeing strange output when running adb devices:
    List of devices attached
    ????????????    no permissions

    This led to some searching which turned up a blog post.  Basically, the Google Android team hasn’t added the Vendor ID for the Nexus One.  Apparently HTC’s USB Vendor ID isn’t correct.  So, I followed these steps to fix it:

    1. Create/edit a udev rules file:
      sudo vim /etc/udev/rules.d/51-android.rules
    2. Add the following line to this file:
      SUBSYSTEM=="usb", SYSFS{idVendor}=="18D1", MODE="0666"
      (Note the vendor ID of 18D1. This was changed from the HTC vendor code of 0BB4.)
    3. Restart udev using either
      sudo reload udev
      or
      sudo service udev reload
    4. Connect your Nexus One.
    5. Run
      adb devices
      and you should see something like
      List of devices attached
      ############ device

    Hopefully Google updates the documentation to include the Vendor ID 18D1 rather than making us hunt for this number ourselves.  Enjoy!

  • 相关阅读:
    arduino入门学习实现语音控制LED灯
    c# 实现串口编程-操作LED屏幕
    腾讯地图 获取各种情况的总距离
    js播放wav文件,兼容主流浏览器,兼容多浏览器
    工厂方法模式
    依赖倒转模式
    设计模式——开放封闭原则
    设计模式——单一职责原则
    策略模式
    简单工厂模式
  • 原文地址:https://www.cnblogs.com/leino11121/p/2381928.html
Copyright © 2011-2022 走看看