Testing Your App on Galaxy Watch
Running on Device
Connect a Galaxy Watch device(Galaxy Watch S2, Galaxy Watch S3, and Galaxy Watch Fit2 only) to a Host PC via Wi-Fi. A wireless access point is needed to connect a Galaxy Watch Device to a Host PC.
Host PC Set Up
- Connect the Host PC to the Wireless Access Point via UTP cable or Wi-Fi.
Galaxy Watch Device Set Up
Turn on the Wi-Fi.
Turn on debugging mode.
Select Settings > Galaxy Watch Info > Debugging
Reboot the device.
Connect a Galaxy Watch device to the Wireless Access Point via Wi-Fi
From the Wi-Fi menu of the Galaxy Watch device, find the Wireless Access Point and connect to it.
Once connected, find the IP address that the Galaxy Watch device had received from the Access Point via DHCP. This IP address will be used during the SDB connection.
You can get this IP address by checking the information of the access point of the currently connected Galaxy Watch device.
Now you are ready to connect the SDB in the IDE or command line.
Connecting via the IDE
Open the IDE and launch the Remote Device Manager.
Once the Remote Device Manager is open, it will start to scan for devices. Alternatively, click the scan button to scan again.
After scanning, you can find the list of devices that can connect. Select the Galaxy Watch device and click ‘Connect’.
The connected device will be displayed on the Connection Explorer.
Connecting via the SDB command line
Instead of using the IDE, you can connect via the SDB in the command line as well.
Open the terminal in the Host PC and use the following connect command.
`$ sdb connect [Galaxy Watch S2 IP address]:26101 Ex) $ sdb connect 192.168.0.11:26101`
You can see the connected Galaxy Watch device by using SDB devices command.
$ sdb devices List of devices attached 192.168.0.11:26101 device SM-R730A
After connecting, you can install apps or use the shell command line.
Installing the App
Open the terminal in the Host PC and use the following install command.
`$ sdb install [path_to_wgt] Ex) $ sdb install /home/tizen/org.example.test-1.0.0-i386.wgt`
Once the connection is completed, you can use the SDB command similar to the USB connected case.
Please refer to the link below for more details regarding SDB commands.
Confirm that the SDB version is 2.2.88 or later.
$ sdb version
Try the kill-server command when a version warning message is shown.
$ sdb kill-server
Turn off Bluetooth to reduce interference with Wi-Fi.
Move away from the charging dock to reduce interference with Wi-Fi.
Bluetooth and Wi-Fi cannot be turned on at the same time on the Galaxy Watch S2 with its initial firmware.
However, the latest firmware fixes this issue. To turn on both Bluetooth and Wi-Fi at the same time, the Debugging mode is switched ON with the recent firmware (Firmware for US and Japan 3G models soon will be available).
To update the firmware, check the Galaxy Watch Software Upgrade in the Samsung Galaxy Watch application on your paired mobile device.
Running on Remote Test Lab
Using the Remote Test Lab service, you can test your application on a real device. The Remote Test Lab service enables developers to access Samsung devices through the web and to install and test applications on the devices. This is not only the most effective and easiest way to test the compatibility of an application with Samsung devices but also the best way to cut down on hardware costs for test devices. Interaction with the device is performed over the network in real time allowing you to comprehensively test your application before distributing it.
The Remote Test Lab service is available to all users of the Samsung Developers Forum:
For more details, please refer to the following link:
Galaxy Watch Emulator Set Up for Testing Companion Type Apps
Preparing the SAP Test Environment
To prepare the SAP test environment, you must acquire the required file and install the Host Manager for the Emulator.
Application for Emulator download
Setting up the SAP Server Test Environment
For setting up the SAP server test environment, you must get the following apk file:
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:
After installation, reboot and run the Emulator for Samsung Accessory application in the host device. The application will display a "Disconnected" message.
Connecting the Emulator and Host through the SAP Server
Before you attempt to connect 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:
Connect the host device and PC using a USB connection.
Open the terminal or the command prompt in Windows.
Enter the command:
adb -d forward tcp:8230 tcp:8230.
Run the emulator for Samsung Accessory in the host device.
In the SDK, run the Emulator Manager and create a new virtual machine.
Run the virtual machine. At the first boot, the device will display the screen below.
It will reboot automatically to be connected with an Android device.
(Auto-reboot is supported from Wearable Extension 1.2.0. At the previous version, the user should reboot manually at first boot.)
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.
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.
Uninstalling applications for emulator
If you want to connect the Samsung Galaxy Watch with a real device, you have to delete “Application_for_Emulator”. Go to Settings > Application Manager then uninstall Samsung Accessory Service.
Preparing the Remote AppControl Test Environment
Install Wearable Extension 1.2.0 or higher version.
Set up above SAP test environment.
Install WMSServiceProvider_Emul.apk to Android device.
How to enable Developer options
Developer can utilize additional features for app development and debugging by enabling Developer options on the Galaxy Watch device with Tizen version 126.96.36.199 or higher.
Go to Settings -> Galaxy Watch info -> About device.
Tap on Software version 5 times. Then a confirmation pop up displayed once the Developer options is enabled.
You can find the Developer options in the list of Settings menu.