page.title=Download and Test with a Device meta.keywords="wear-preview" page.tags="wear-preview" page.image=images/cards/card-n-downloads_2x.png @jd:body

You can run and test your app with the Android Wear 2.0 Preview in either of these ways:

If you want an environment for basic compatibility testing of your app, you can use your current APK and a supported watch or an emulator. As described below, you don't necessarily need to update your full development environment to do basic testing.

However, if you want to modify your app to target Android Wear 2.0 or use new APIs, you need to update your development environment. See Get Started with the Preview.

Set Up a Watch

You can download a system image and manually flash it to a matching watch. See the table below to download the image for your test watch.

Manually flashing a watch is useful if you need precise control over the test environment or need to reinstall frequently, such as for automated testing.

Warning: Installing a system image on a watch removes all data from the watch, so you should back up your data first.

Preview system images

The preview includes system images for testing your app. Based on your device, you can download a preview system image from one of the following tables and flash it to the corresponding device.

Caution: After you flash an image to a watch, follow the steps for setting up a phone with the beta version of the Android Wear companion app. To use a Wear 2.0 image on a watch, you must have the beta companion app on a paired phone.

To restore your device to its original state during the preview, you can flash the appropriate retail system image, below, to the device.

Preview image for LGE Watch Urbane 2nd Edition

Caution: Flashing your device will require unlocking the bootloader which may void the device's warranty--proceed at your own risk.

Type of LGE Watch Urbane 2nd Edition image Download/Checksums
Preview image for testing nemo-nve68j-factory-302a33ea.tgz
MD5: ddfccc3e050c7e2db8d657c82f7d6291
SHA-1: 302a33eac348c401fcb165bad4b9aaa40c7beb2b
Non-preview image (for after testing) nemo-mfd18l-factory-3faf6f2d.tgz
MD5: f3a0090c0e99da82ad095b5d2a9acc6d
SHA-1: 3faf6f2d7f422a17a5f6c54cf5e1d2c5622689b0

Preview image for Huawei Watch

Caution: Flashing your device will require unlocking the bootloader which shall void the device's warranty--proceed at your own risk.

Type of Huawei Watch image Download/Checksums
Preview image for testing sturgeon-nve68j-factory-6607cd31.tgz
MD5: f78ac6ba8bb84038d163cc2d7ca85040
SHA-1: 6607cd31858af1bfd50b905c68f7cf1f0b6e570e
Non-preview image (for after testing) sturgeon-m6e69f-factory-e659286a.tgz
MD5: 12ce6cb0b0e43b67ea46a886eae052ae
SHA-1: e659286aa9004f4555a476ede4e8b690f56cfefd

Flash a watch

The steps for flashing an image to a watch are similar to the steps provided for flashing to a phone. After you back up your watch data, use steps in this section to flash the image to the specific watch that matches the image (e.g., you must use an LGE Watch Urbane 2nd Edition for the corresponding image).

Warning: Installing a system image on a watch removes all data from the watch, so you should back up your data first.

Set up the watch to be flashed

On the watch, enable the Developer Options menu and ADB debugging as follows:

  1. Open the Settings menu on the watch.
  2. Scroll to the bottom of the menu. If no Developer Options item is provided, tap System and then About.
  3. Tap the build number 7 times.
  4. From the Settings menu, tap Developer Options.
  5. Enable ADB debugging.

Confirm installation of the fastboot tool

To flash a device using one of the system images, confirm that you have the fastboot tool in the platform-tools/ directory of the Android SDK. Be sure that you have the latest version of the Android SDK Platform-tools from the SDK Manager.

After you confirm that you have the fastboot tool, add the tool to your PATH environment variable so the tool can be found when you flash the watch.

Transfer the image to the watch

To download a preview image and flash it to the watch:

  1. Download and unzip the appropriate system image from a "Preview image for testing" row in a table above.
  2. Attach the watch charger to the watch and plug the USB cord (from the charger) into your computer.
  3. Use the following adb command to confirm that the watch is recognized. You may need to turn ADB debugging off and then on for the watch to be recognized: adb devices
  4. Use the following adb command to start the device in fastboot mode: adb reboot bootloader
  5. If necessary, use one of following two commands to unlock the device's bootloader. This step erases all data on the device: fastboot flashing unlock or, for some devices, fastboot oem unlock
  6. On the watch, select the option to unlock the bootloader.
  7. On your computer, navigate to the directory where you unzipped the system image in Step 1. At the top level of that directory, execute the flash-all script by typing flash-all.sh or, in the case of Windows, flash-all.bat. The following may need to precede the command: ./

Set up the watch

After the flash-all script finishes, the watch reboots. Only pair the watch with a phone (so you can begin testing the preview) by using the instructions in Set Up a Phone. Additionally, before installing an app, perform the following steps on the watch to re-secure the watch's bootloader:

  1. Open the Settings menu by long-pressing the physical button.
  2. Scroll to the bottom of the menu and tap About.
  3. Tap the build number 7 times.
  4. From the Settings menu, tap Developer Options.
  5. Enable ADB debugging.
  6. Connect the watch to your computer and tap Always allow from this computer. (You may need to turn ADB debugging off and then on, to be prompted to always allow ADB debugging from the connected computer.)
  7. Use the following adb command to start the device in fastboot mode: adb reboot bootloader
  8. Use the following command to lock the device's bootloader: fastboot flashing lock or, for some devices, fastboot oem lock
  9. On the watch, continue the boot as follows: On an LGE Watch Urbane 2nd Edition, choose Start and touch '0'. On a Huawei Watch, confirm that Reboot is chosen and long-press the physical button.

After you follow the instructions in Set Up a Phone, your watch will be ready for you to install and run your app:

  1. Open your app in Android Studio.
  2. Select your Wear app module name from the Run/Debug configuration drop-down menu (typically wear).
  3. Click the Play button.
  4. In the Select Deployment Target box, click your device.

After your app is installed on the watch, the app should run.

When testing is completed, follow the steps for removing the preview.

Remove the preview from a watch

When testing with the preview is done, unpair ("Forget") the watch from the phone and restore the watch as follows:

  1. Download and unzip the appropriate system image from a "Non-preview image" row in a table above.
  2. Manually flash the image to the watch using steps similar to those in Transfer the image to the watch, except that you flash the non-preview image to the watch.

Note: Removing a preview system image requires a full device reset and removes all user data on the device.

Set Up a Phone

On a phone, follow the instructions in this section to install the beta version of the Android Wear companion app. The beta version cannot be run on a phone at the same time as the non-beta version. Additionally, the beta version is English-only.

Caution: If you have an existing pairing of the phone to a Wear 1.x watch, installation of the beta companion app will cause a loss of that pairing.

Join the Wear 2.0 preview group

To access the beta companion app, you must join the preview group in Google Groups.

Opt in for beta testing

On the Testing Opt-in page, select Become a Tester.

Download and install the beta version of the companion app

On the Play Store on your phone, go to the Android Wear app listing. Tap Update to download and install the beta version of the app. After installation, confirm that Auto-update is selected for the app (see the "Set up automatic updates for specific apps" section of Update downloaded apps). Tap Open to start the app.

Pair the phone to the watch

After you install the beta version of the companion app on a phone, unpair ("Forget") any obsolete watch pairings, if necessary. Then you can pair the phone to a newly-imaged watch:

  1. On the phone, select your device name from the list of devices. A pairing code is displayed on the phone and on the watch. Ensure that the codes match.
  2. Tap Pair to continue the pairing process. When the watch is connected to the phone, a confirmation message is displayed. On the phone, a screen is displayed that lists the accounts on the phone.
  3. Choose a Google Account to add and sync to your watch.
  4. Confirm the screen lock and enter the password to start the copying of the account from the phone to the watch.
  5. Follow the instructions in the wizard to finish the pairing process.

You can begin testing your app with the preview.

Set Up an Emulator

To test with the Android Emulator, confirm that you have the latest version of the Android SDK Platform-tools from the SDK Manager.

After you create a virtual device as described below, follow the steps for setting up a phone with the beta version of the Android Wear companion app.

Create a new virtual device in Android Studio as follows:

  1. Open the AVD Manager by selecting Tools > Android > AVD Manager.
  2. Click Create Virtual Device.
  3. In the Category pane, select Wear and choose a hardware profile. The Android Wear 2.0 Developer Preview is only optimized for round devices currently, so we recommend not using the square or chin profiles for now. Click Next.
  4. Select a Nougat image to download. The images may be on the x86 tab instead of the Recommended tab, until installed. For example, select the image with the Release Name of Nougat, the API Level of 24, and the Target of "Android 7.0 (with Android Wear)". When the download and installation are complete, click Finish and then click Next.
  5. Verify the configuration of the Android Virtual Device (AVD) and click Finish.
  6. Start the emulator by selecting the new virtual device, clicking the Play button, and waiting until the emulator initializes and shows the Android Wear home screen.

Pair the phone with the emulator, and sync a Google Account, as follows:

  1. Follow the steps for setting up a phone with the beta version of the Android Wear companion app.
  2. On the phone, enable Developer Options and USB Debugging.
  3. Connect the phone to your computer through USB.
  4. Forward the AVD's communication port to the connected handheld device (each time the phone is connected):
    adb -d forward tcp:5601 tcp:5601
  5. On the phone, in the Android Wear app, begin the standard pairing process. For example, on the Welcome screen, tap the Set It Up button. Alternatively, if an existing watch already is paired, in the upper-left drop-down, tap Add a New Watch.
  6. On the phone, in the Android Wear app, tap the Overflow button, and then tap Pair with Emulator.
  7. Tap the Settings icon.
  8. Under Device Settings, tap Emulator.
  9. Tap Accounts and select a Google Account, and follow the steps in the wizard to sync the account with the emulator. If necessary, type the screen-lock device password, and Google Account password, to start the account sync.

You can now test an app with a virtual preview device in the Android Emulator. For more information about using virtual devices, see Create and Manage Virtual Devices.