Galaxy Watch Emulator set up for testing companion type apps

Preparing the SAP Server Test Environment

To prepare the SAP server test environment, you must acquire the required file and install the Host Manager for the Emulator.

Setting up the SAP Server Test Environment

For setting up the SAP server test environment, you must get the following apk file:

  1. SAccessoryService_Emul.apk

    Download Application_for_Emulator that includes the needed file. Extract the file and copy them to the host.

Installing Host manager in Emulator

To install the Host manager in the Emulator, install the .apk file in the following order:

  1. SAccessoryService_Emul.apk

    After installation, reboot and run the Emulator for Samsung Accessory application in the host device. The application will display a "Disconnected" message.

    Figure 1: Running Emulator for Samsung Accessory in the mobile device

Connecting the Emulator and Host through the SAP Server

Before you attempt connecting the Emulator and Host, make sure the following prerequisites are met:

  • Android Debug Bridge (adb) is installed and environment path to adb is set.

  • Tizen SDK for Wearable is installed and running.

  • Host device should be connected to WiFi.

  • WI-FI transport type is added to "/res/xml/serviceprofile.xml" of Galaxy Watch application. To set up the connection:

  1. Connect the host device and PC using a USB connection.

  2. Open the terminal or the command prompt in Windows.

  3. Enter the command: adb -d forward tcp:8230 tcp:8230.

  4. Run the emulator for Samsung Accessory in the host device.

  5. In the SDK, run the Emulator Manager and create a new virtual machine.

  6. Run the virtual machine. If the 'Disconnected' message does not change, restart the emulator with the hardware key or the command shutdown –r now. DO NOT use the command reboot.

Note

If the above steps does not work, go to Settings > Application Manager. Find 'Samsung Accessory Service' and clear the data. Then repeat the above steps.

Figure 2: Successful connection

From now on, run your mobile app on the Android device already connected to the Galaxy Watch emulator; and your Galaxy Watch app on the Galaxy Watch emulator so that you can test companion type apps.