Enabling USB Debugging for Nexus 7 on Windows 8
While preparing for my BUILD talk that introduces Windows 8 to Android developers, I went to the nearest GameStop and brought home a brand new Nexus 7 to try it out. I enabled USB debugging before I fired up the IDE. When I tried to deploy the app to Nexus 7, to my frustration it was not being recognized by ADB. The Nexus 7 device was showing up as a USB drive with obvious name “Nexus 7”. It is good if I wanted to copy files to and from the device but my purpose is to deploy the app and test it out.
After Bing’ing for a couple of minutes I realized that I needed to install Google USB Driver (rev 7). I installed the driver from the SDK Manager.exe and rebooted the box. When I plugged Nexus 7 back in, now my USB drive disappeared and it showed up as a MTP ( Media Device). Still ADB doesn’t see Nexus 7… it was a bit frustrating not a lost cause yet.
Again, Bing to the rescue… I found a thread that was describing the process to show an Android device as a USB drive instead of an MTP device. I also found that if Nexus 7 shows up as a “camera” the ADB may pick up the device. I thought I would give it a shot; from the Settings –>Device->Storage->USB Computer Connection (from the menu), I changed the device to “Camera (PTP)” and ran “adb devices –l” at the command prompt. Voila, ADB lists the device and ADT was able to deploy the app to Nexus 7!
Here are the high level steps:
- Enable Developer Options (settings –> About Tablet –> Build Number (tap 7 times to make Developer Options available in the menu)
- Turn on Developer Options (top menu) and USB Debugging
- Install Google USB Driver (rev7)
- Configure USB Computer Connection (located in the contextual menu of settings—>Storage) to appear Nexus 7 as a camera
Happy development on Windows 8!