Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why must I reset ADB so frequently in Eclipse in order to connect to an Android device?

When developing an Android project in Eclipse, I frequently find that the android device is offline. When I reset the Android Debug Bridge (adb) the problem is resolved--albeit temporarily. There are many answers on SE that suggest resetting ADB to resolve similar problems, but I haven't found an answer to the underlying cause:

  • What is happening that requires ADB to be reset so frequently?

UPDATE: Here's some detail about my configuration to the extent it's relevant (per @Berdon's request):

  • Development environment is running Windows 8.
  • Eclipse JDT (3.8.1), Eclipse Platform (4.2.1), Eclipse RCP (4.2.1), ADT (21.0.1.201212060302).
  • Connecting to Android Devices using a USB cable with no USB hub between them.
  • The Android devices in question include primarily a Nexus 7 tablet and an HTC Thunderbolt, although I've seen it occur with other devices as well.
like image 780
Cameron Fredman Avatar asked Nov 04 '22 03:11

Cameron Fredman


1 Answers

I have seen similar problems when I'm working with Eclipse as well. But I believe it's a problem with Windows, not Android nor Eclipse.

I'll test this one once I'm back home:

  1. Go to Control Panel -> System -> Device Manager
  2. Open the Universal Serial Bus Controllers
  3. Right Click all Root Hubs
  4. In the Power Management tab de-select the box "Allow the computer to turn off this device to save power"

I'm on a Windows 7 computer, so you'll have to access the Control Panel via Windows+x.

like image 200
DigCamara Avatar answered Nov 10 '22 19:11

DigCamara