adb不会检测到,但无法识别我的设备

时间:2013-07-07 18:41:29

标签: android adb ubuntu-12.04 udev

我正在尝试使用adb将eclipse连接到我的设备,这样我就可以调试我在其上写的应用程序。无论我做什么似乎都让它显示设备的序列号。

ADB检测到我的手机,但它只显示在列表中:

List of devices attached 
????????????    device

我为它添加了udev规则 我的你的udev规则是这样的:

SUBSYSTEM=="usb", ATTRS{idVendor}=="0bb4", MODE="0666"

SUBSYSTEM=="usb", ATTRS{idVendor}=="0502", MODE="0666"

SUBSYSTEM=="usb", ATTRS{idVendor}=="12d1", MODE="0666"

SUBSYSTEM=="usb", ATTRS{idVendor}=="1004", MODE="0666"

SUBSYSTEM=="usb", ATTRS{idVendor}=="22b8", MODE="0666"

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

SUBSYSTEM=="usb", ATTRS{idVendor}=="0fce", MODE="0666"

SUBSYSTEM=="usb", ATTRS{idVendor}=="0489", MODE="0666"

SUBSYSTEM=="usb", ATTRS{idVendor}=="18d1", SYMLINK+="android_adb", MODE="0666"

SUBSYSTEM=="usb", ATTRS{idVendor}=="04e8", MODE="0666", GROUP="plugdev"

#Acer
SUBSYSTEM=="usb", SYSFS{idVendor}=="0502", MODE="0666"
#Dell
SUBSYSTEM=="usb", SYSFS{idVendor}=="413c", MODE="0666"
#Foxconn
SUBSYSTEM=="usb", SYSFS{idVendor}=="0489", MODE="0666"
#Garmin-Asus
SUBSYSTEM=="usb", SYSFS{idVendor}=="091E", MODE="0666"
#Google
SUBSYSTEM=="usb", SYSFS{idVendor}=="18d1", MODE="0666"
#HTC
SUBSYSTEM=="usb", SYSFS{idVendor}=="0bb4", MODE="0666"
#Huawei
SUBSYSTEM=="usb", SYSFS{idVendor}=="12d1", MODE="0666"
#Kyocera
SUBSYSTEM=="usb", SYSFS{idVendor}=="0482", MODE="0666"
#LG
SUBSYSTEM=="usb", SYSFS{idVendor}=="1004", MODE="0666"
#Motorola
SUBSYSTEM=="usb", SYSFS{idVendor}=="22b8", MODE="0666"
#Nvidia
SUBSYSTEM=="usb", SYSFS{idVendor}=="0955", MODE="0666"
#Pantech
SUBSYSTEM=="usb", SYSFS{idVendor}=="10A9", MODE="0666"
#Samsung
SUBSYSTEM=="usb", SYSFS{idVendor}=="04e8", MODE="0666"
#Sharp
SUBSYSTEM=="usb", SYSFS{idVendor}=="04dd", MODE="0666"
#Sony Ericsson
SUBSYSTEM=="usb", SYSFS{idVendor}=="0fce", MODE="0666"
#ZTE
SUBSYSTEM=="usb", SYSFS{idVendor}=="19D2", MODE="0666"

我的操作系统是Ubuntu 12.04 32位

和设备是Metro Pcs华为Ascend(M860)

此时我已经重新启动了adb,udev和我的系统。

sudo的输出找-L / sys / bus / usb / devices -maxdepth 2 -path“* / modalias”-printf“%h \ t”-exec cat {} \; | tee / dev / stderr | awk -F:'/ icFFisc42ip01 $ / {print $ 1}'| xargs -i cat {} / serial

/sys/bus/usb/devices/1-0:1.0    usb:v1D6Bp0002d0302dc09dsc00dp00ic09isc00ip00
/sys/bus/usb/devices/2-0:1.0    usb:v1D6Bp0002d0302dc09dsc00dp00ic09isc00ip00
/sys/bus/usb/devices/3-0:1.0    usb:v1D6Bp0001d0302dc09dsc00dp00ic09isc00ip00
/sys/bus/usb/devices/4-0:1.0    usb:v1D6Bp0001d0302dc09dsc00dp00ic09isc00ip00
/sys/bus/usb/devices/5-0:1.0    usb:v1D6Bp0001d0302dc09dsc00dp00ic09isc00ip00
/sys/bus/usb/devices/6-0:1.0    usb:v1D6Bp0001d0302dc09dsc00dp00ic09isc00ip00
/sys/bus/usb/devices/7-0:1.0    usb:v1D6Bp0001d0302dc09dsc00dp00ic09isc00ip00
/sys/bus/usb/devices/1-2:1.0    usb:v064EpA101d0100dcEFdsc02dp01ic0Eisc01ip00
/sys/bus/usb/devices/1-2:1.1    usb:v064EpA101d0100dcEFdsc02dp01ic0Eisc02ip00
/sys/bus/usb/devices/2-4:1.0    usb:v12D1p1502d0100dc00dsc00dp00icFFiscFFipFF
/sys/bus/usb/devices/2-4:1.1    usb:v12D1p1502d0100dc00dsc00dp00icFFiscFFipFF
/sys/bus/usb/devices/2-4:1.2    usb:v12D1p1502d0100dc00dsc00dp00ic08isc06ip50
/sys/bus/usb/devices/6-1:1.0    usb:v05ACp1002d0122dc09dsc00dp00ic09isc00ip00
/sys/bus/usb/devices/6-1.1:1.0  usb:v05ACp0204d0122dc00dsc00dp00ic03isc01ip01
/sys/bus/usb/devices/6-1.1:1.1  usb:v05ACp0204d0122dc00dsc00dp00ic03isc00ip00
/sys/bus/usb/devices/2-4:1.3    usb:v12D1p1502d0100dc00dsc00dp00icFFisc42ip01
/sys/bus/usb/devices/2-4:1.4    usb:v12D1p1502d0100dc00dsc00dp00icFFiscFFipFF
/sys/bus/usb/devices/2-4:1.5    usb:v12D1p1502d0100dc00dsc00dp00icFFiscFFipFF

这是以下的输出:     adb shell getprop


[ro.secure]: [0]
[ro.allow.mock.location]: [1]
[ro.debuggable]: [1]
[persist.service.adb.enable]: [1]
[ro.factorytest]: [0]
[ro.serialno]: []
[ro.bootmode]: [unknown]
[ro.baseband]: [unknown]
[ro.carrier]: [unknown]
[ro.bootloader]: [unknown]
[ro.hardware]: [qcom]
[ro.revision]: [0]
[ro.build.id]: [GRJ90]
[ro.build.display.id]: [09132011]
[ro.build.version.incremental]: [121341]
[ro.build.version.sdk]: [10]
[ro.build.version.codename]: [REL]
[ro.build.version.release]: [2.3.5]
[ro.build.date]: [Tue Sep 13 10:47:29 EDT 2011]
[ro.build.date.utc]: [0]
[ro.build.type]: [user]
[ro.build.user]: [playfulgod]    
[ro.build.host]: [The-Monster]
[ro.build.tags]: [test-keys]
[ro.product.model]: [M860]
[ro.product.brand]: [Huawei]
[ro.product.name]: [sojus]
[ro.product.device]: [ascend]
[ro.product.board]: [M860]
[ro.product.cpu.abi]: [armeabi-v6j]
[ro.product.cpu.abi2]: [armeabi]
[ro.product.manufacturer]: [Huawei]
[ro.product.locale.language]: [en]
[ro.product.locale.region]: [US]
[ro.wifi.channels]: []
[ro.board.platform]: [msm7k]
[ro.build.product]: [ascend]
[ro.build.description]: [soju-user 2.3.5 GRJ90 121341 release-keys]
[ro.build.fingerprint]: [google/soju/crespo:2.3.5/GRJ90/121341:user/release-keys]
[rild.libpath]: [/system/lib/libril-qc-1.so]
[rild.libargs]: [-d /dev/smd0]
[DEVICE_PROVISIONED]: [1]
[mobiledata.interfaces]: [rmnet0,rmnet1,rmnet2]
[ro.tether.denied]: [false]
[sys.checkfs.fat]: [false]
[ro.media.dec.jpeg.memcap]: [20000000]
[ro.confg.hw_appsbootversion]: [M860V100R001C177B617_APPSBOOT]
[ro.confg.hw_appversion]: [M860V100R001C177B617_KERNEL]
[ro.confg.hw_appfsversion]: [M860V100R001C177B617_SYSIMG]
[wifi.interface]: [eth0]
[wifi.supplicant_scan_interval]: [120]
[ro.sf.lcd_density]: [160]
[ro.com.android.dataroaming]: [false]
[ro.telephony.default_network]: [4]
[ro.opengles.version]: [65537]
[dalvik.vm.execution-mode]: [int:jit]
[dalvik.vm.heapsize]: [24m]
[persist.sys.use_dithering]: [1]
[persist.sys.purgeable_assets]: [1]
[ro.compcache.default]: [18]
[dalvik.vm.dexopt-data-only]: [1]
[keyguard.no_require_sim]: [true]
[ro.com.google.clientidbase]: [android-huawei-us]
[ro.com.google.locationfeatures]: [1]
[ro.cdma.home.operator.numeric]: [31016]
[ro.config.cdma_subscription]: [1]
[ro.cdma.voicemail.number]: [mine]
[ro.setupwizard.enable_bypass]: [1]
[ro.config.play.bootsound]: [1]
[ro.rommanager.developerid]: [cyanogenmod]
[ro.url.legal]: [http://www.google.com/intl/%s/mobile/android/basic/phone-legal.html]
[ro.url.legal.android_privacy]: [http://www.google.com/intl/%s/mobile/android/basic/privacy.html]
[ro.com.android.wifi-watchlist]: [GoogleGuest]
[ro.setupwizard.enterprise_mode]: [1]
[ro.com.android.dateformat]: [MM-dd-yyyy]
[ro.config.ringtone]: [Playa.ogg]
[ro.config.notification_sound]: [regulus.ogg]
[ro.config.alarm_alert]: [Alarm_Beep_03.ogg]
[ro.modversion]: [CM7.2-ascend-09132011]
[ro.setupwizard.mode]: [OPTIONAL]
[net.bt.name]: [Android]
[net.change]: [net.dnschange]
[dalvik.vm.stack-trace-file]: [/data/anr/traces.txt]
[persist.sys.localevar]: []
[persist.sys.country]: [US]
[persist.sys.themePackageName]: [com.tmobile.theme.Androidian]
[persist.sys.timezone]: [America/Bahia_Banderas]
[persist.sys.language]: [en]
[persist.sys.themeId]: [Androidian]
[persist.service.compcache]: [18]
[ro.FOREGROUND_APP_ADJ]: [0]
[ro.VISIBLE_APP_ADJ]: [1]
[ro.PERCEPTIBLE_APP_ADJ]: [2]
[ro.HEAVY_WEIGHT_APP_ADJ]: [3]
[ro.SECONDARY_SERVER_ADJ]: [4]
[ro.BACKUP_APP_ADJ]: [5]
[ro.HOME_APP_ADJ]: [6]
[ro.HIDDEN_APP_MIN_ADJ]: [7]
[ro.EMPTY_APP_ADJ]: [15]
[ro.FOREGROUND_APP_MEM]: [2048]
[ro.VISIBLE_APP_MEM]: [3072]
[ro.PERCEPTIBLE_APP_MEM]: [4096]
[ro.HEAVY_WEIGHT_APP_MEM]: [4096]
[ro.SECONDARY_SERVER_MEM]: [6144]
[ro.BACKUP_APP_MEM]: [6144]
[ro.HOME_APP_MEM]: [6144]
[ro.HIDDEN_APP_MEM]: [7168]
[ro.EMPTY_APP_MEM]: [8192]
[net.tcp.buffersize.default]: [4096,87380,110208,4096,16384,110208]
[net.tcp.buffersize.wifi]: [4095,87380,110208,4096,16384,110208]
[net.tcp.buffersize.umts]: [4094,87380,110208,4096,16384,110208]
[net.tcp.buffersize.edge]: [4093,26280,35040,4096,16384,35040]
[net.tcp.buffersize.gprs]: [4092,8760,11680,4096,8760,11680]
[init.svc.servicemanager]: [running]
[init.svc.vold]: [running]
[init.svc.netd]: [running]
[init.svc.debuggerd]: [running]
[init.svc.ril-daemon]: [running]
[init.svc.zygote]: [running]
[init.svc.media]: [running]
[init.svc.dbus]: [running]
[init.svc.installd]: [running]
[init.svc.keystore]: [running]
[init.svc.dhcp-service]: [stopped]
[init.svc.qmuxd]: [running]
[init.svc.oem_rpc_svc]: [running]
[init.svc.akmd]: [running]
[init.svc.compcache]: [stopped]
[a2sd.swap]: [0]
[a2sd.swappart]: [none]
[cm.filesystem.ready]: [1]
[dc.filesystem.ready]: [1]
[cm.e2fsck.errors]: [8]
[init.svc.console]: [running]
[init.svc.adbd]: [running]
[ro.ril.ecclist]: [*911,#911,911,]
[init.svc.bootanim]: [stopped]
[init.svc.bootsound]: [stopped]
[hw.keyboards.65536.devname]: [kp_test_input]
[hw.keyboards.65538.devname]: [7k_handset]
[hw.keyboards.65540.devname]: [surf_keypad]
[net.hostname]: [android-83d9d11868e2f99]
[dev.bootcomplete]: [1]
[gsm.version.ril-impl]: [Qualcomm RIL 1.0]
[sys.boot_completed]: [1]
[gsm.sim.state]: [UNKNOWN]
[gsm.current.phone-type]: [2]
[gsm.sim.operator.alpha]: []
[gsm.sim.operator.numeric]: [31016]
[gsm.sim.operator.iso-country]: [us]
[gsm.operator.alpha]: []
[gsm.operator.numeric]: []
[gsm.operator.iso-country]: []
[gsm.operator.isroaming]: [false]
[gsm.version.baseband]: [22201010]
[ro.runtime.firstboot]: [1373125077964]
[sys.cpufreq.restored]: [false]
[sys.settings_secure_version]: [16]
[sys.settings_system_version]: [102]
[wlan.driver.status]: [ok]
[init.svc.wpa_supplicant]: [running]
[net.dnschange]: [43]
[init.svc.dhcpcd_eth0]: [running]
[dhcp.eth0.result]: []
[dhcp.eth0.pid]: [13968]
[dhcp.eth0.reason]: [PREINIT]
[dhcp.eth0.dns1]: []
[dhcp.eth0.dns2]: []
[dhcp.eth0.dns3]: []
[dhcp.eth0.dns4]: []
[dhcp.eth0.ipaddress]: [192.168.2.182]
[dhcp.eth0.gateway]: [192.168.2.1]
[dhcp.eth0.mask]: [255.255.255.0]
[dhcp.eth0.leasetime]: [14400]
[dhcp.eth0.server]: [192.168.2.1]
[net.dns1]: [192.168.2.1]
[init.svc.iprenew_eth0]: [stopped]
[net.eth0.dns1]: [192.168.2.1]
[net.eth0.dns2]: []
[net.eth0.gw]: [192.168.2.1]

2 个答案:

答案 0 :(得分:1)

对我有用的一件事是用root权限重启服务器:

adb kill-server
sudo adb start-server

答案 1 :(得分:1)

请改为使用Universal udev rule for all Android devices

ACTION=="add", SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ENV{ID_USB_INTERFACES}=="*:ff420?:*", MODE="0666"

不要忘记重新加载规则:

udevadm control --reload-rules