How to Set Up Your Testing Environment for Android Wear

By Barry Burd

The latest and greatest in the technology world is wearable devices. Like other Android devices, these will host a plethora of apps. The only thing you need is an Android Wear AVD. Here’s how you get one:

  1. In Android Studio’s main menu, choose Tools → Android → SDK Manager.

  2. Make sure that your SDK Tools is Version 23.0.0 or higher.

    If not, install an updated SDK Tools version.

  3. Make sure that your SDK is API Level 20 or higher.

    If not, install an updated SDK level.

  4. Close the SDK Manager.

    (You were probably planning to do that anyway.)

  5. In Android Studio’s main menu, choose Tools → Android → AVD Manager.

    The AVD Manager opens.

  6. In the AVD Manager window, click the Create Virtual Device button.

    The Virtual Device Configuration dialog box appears. The left side of the dialog box contains a Category list, and the middle contains a list of hardware profiles.

  7. In the Category list, select Wear.

    Doing so narrows the list of hardware profiles to the ones that are specifically for Android Wear.

  8. Select a hardware profile from the list and click Next.

    The choices probably include square and round watches and different numbers of pixels on the faces.

    It’s true. To run the emulator on your development computer, some choices might be better than others. Some AVDs consume too much memory. Other choices (such as x86 or armeabi in the next step) might be wrong for your computer’s configuration. If at first you don’t succeed, try some different choices.

    When you click Next, another Virtual Device Configuration dialog box appears. The new dialog box lists system images. Each system image is a version of Android (5.0.2, for example) along with a target processor architecture (x86 or armeabi).

  9. Select an item in the list and click Next.

    At this point, yet another Virtual Device Configuration dialog box appears. The defaults in this dialog box are okay by me.

  10. Click Finish.

After following these steps, you have an emulated device that does what an Android wearable does. You can test your Android Wear code on this emulated device.