LG Watch

DOWNLOAD SDK

Download SDK

LG WatchDownload SDK

Download

Supported Device : LG Watch W7

  • LGWatchSDK-r2.zipMar 20, 2020924MB 다운로드
    Developer Guide
    · Added Introduction
    · Added Setup
    · Added Development
    · Added Sample Applicaton
    · Added Added Release Note

    Sample Application
    · ObstructionSample : a sample application that judge whether the smart watch has the obstruction display or not and displays the layout accordingly.

Installing the LG Watch SDK

Download the package file and extract the LG Watch SDK package into a directory.

LG Watch SDK package includes:

  • · docs : API Reference, Developer Guide
  • · libs : API Library File (.jar)
  • · sample : Sample Application (source code included)

Development Environment

Installing Android Studio

LG Watch is based on Wear OS by Google. So, you need an Android development environment to develop LG Watch application.

See Android Developer site to set up the Android development environment on your PC.

Go to Android Developer site

Downloading LG Watch SDK Package

Download the LG Watch SDK package from LG Watch SDK and extract it into a directory.

The LG Watch SDK package is composed as below.

  • · docs: Developer guide (this document) and API Reference
  • · llibs: ObstructionHelper library providing obstruction area information
  • · samples: Sample application and source code using obstruction API

Test Environment

  • · To test developed LG Watch W7 application, a target device is necessary.

On LG Watch such as LG Watch Sport, LG Watch Style and LG Watch W7, as well as on any smart watch based on ‘Wear OS by Google’, you can run and you're your application without doing any specific configuration.

New Application Development

Creating a New Project

Create an Android application project in the following order:

  1. 1. Select ‘New Project’ from the ‘File’ menu.
  2. 2. Fill in the required fields in the ‘Create New Project’ window.

    Fill in the required fields in the ‘Create New Project’ window.

  3. 3. Uncheck ‘Phone and Tablet’ and check ‘Wear’, select ‘API 26: Android 8.0 (Oreo)’ in the 'Target Android Devices' window.

    Uncheck ‘Phone and Tablet’ and check ‘Wear’, select ‘API 26: Android 8.0 (Oreo)’ in the 'Target Android Devices' window.

  4. 4. Select the activity type and click Next.

    Select the activity type and click Next.

  5. 5. Fill in the ‘Activity name’ and the ‘Layout name’ you wish to add by default and click Finish.

    Fill in the ‘Activity name’ and the ‘Layout name’ you wish to add by default and click Finish.

Importing the Library

Import the library file provided in the LG Watch SDK package by the following steps:

  1. 1. Copy com.lge.wearable.ObstructionHelper.jar file in the libs folder of LG Watch SDK package to app > libs in the Project folder.

    Copy com.lge.wearable.ObstructionHelper.jar file in the libs folder of LG Watch SDK package to app > libs in the Project folder.

  2. 2. Add the import statement to the top of MainActivity.java file as follows.

    Add the import statement to the top of MainActivity.java file as follows.

Using the API

You can develop an application considering the obstruction area using API provided in ObstructionHelper.

For more information on API specifications, refer to docs > API Reference in the LG Watch SDK package or LG Watch API References.