App Testing

After you complete developing the app, you need to test your app. The Developer Mode app provides a faster way to install, debug, or test webOS TV apps on the TV. The following introduces the concept behind the Developer Mode app which connects between the TV and the PC.

Overview_of_Dev_Mode_App.png

To use the Developer Mode app, the following should be ready in advance:

  • webOS TV connected with network
  • PC connected with network and installed with webOS TV SDK
  • LG Developer site account
    The Developer Mode app requires you to log in to the LG Developer site. If you do not have account yet, see Preparing a Login Account.
This article provides:

Preparing a Login Account

To use the Developer Mode app, you need to be a member of LG developer portal site. Please follow the below steps to create an account on LG Developer site.

If you already have an LG Developer site account, skip this section and go on to Installing Developer Mode App.

 

  1. Go to http://developer.lge.com

  2. Click Sign In at the top right corner of the screen.

  3. Select the CREATE ACCOUNT tab. The Select Country pop-up will be shown.
    Create Account.png

  4. Select your country from the drop-down menu and click CONFIRM. You will be taken to the Accept Terms & Conditions screen.

  5. Read through and accept our Terms & Conditions and Privacy Policy. Click AGREE to create your new LG Account.

  6. Enter your email address as User ID, password, and date of birth. Select whether to subscribe to our mailing list, then click CONFIRM. We will send you a verification email to your address.

  7. Click CONFIRM in the verification email to complete verification.
    Email Verification.png

  8. Once the Account Created screen appears, go to LG Developer Site (http://developer.lge.com) again.

  9. Click Sign In at the top right corner of the screen and sign in to LG Developer using your new LG Account credentials.

  10. From the My Account screen, enter additional information required and click Save.

Installing Developer Mode App

To install the Developer Mode app, follow the steps below:

  1. Turn on your webOS TV and check if your webOS TV is connected to a network.
  2. Sign in with your LG Developer site account.
  3. Go to the LG STORE.
  4. Search with "Developer Mode".
  5. Select the Developer Mode app and click the Install button.

Turning Developer Mode On

Once the Developer Mode app is installed, you can enable the Developer Mode on your TV.

  1. Run the Developer Mode app from the webOS TV Launcher.
  2. Enter your ID and password to LG Developer site. See Preparing Account.
    Login_of_Dev_Mode_App.png
     
  3. Click the Dev Mode Status button to enable the Developer Mode. TV will reboot.
    Dev_Mode_Status_On.png

Developer Mode will be disabled when:

  • The TV has been rebooted 10 times while Developer Mode is enabled (webOS TV v1.x and v2.0).

  • Developer Mode has been enabled for 10 hours (webOS TV v3.0).

  • The Developer Mode login session is terminated (webOS TV v3.0).

 

When Developer Mode is disabled, the apps installed while Developer Mode is enabled will be uninstalled and you will be taken to the log-in screen of the Developer Mode app.

Connecting TV and PC

This section describes how to connect the webOS TV and PC. Either CLI or IDE can be used for the Developer Mode app.

Connecting with CLI

Follow the instructions below to add the target TV with CLI:

  1. Run webOS TV CLI.
  2. Execute ares-setup-device script. Then, select add.

    ares-setup-device

    name deviceinfo connection profile
    -------- ------------------------ ---------- -------
    emulator developer@127.0.0.1:6622 ssh tv

    ** You can modify the device info in the above list, or add new device.
    ? Select: (Use arrow keys)
    > add
    modify
    remove

     

  3. Input the information of the target TV as below:
    You do not need to enter the password. When using Developer Mode app, password is not required.

    ** You can modify the device info in the above list, or add new device.
    ? Select: add
    ? Enter Device Name: tv2
    ? Enter Device IP address: 10.123.45.67
    ? Enter Device Port: 9922
    ? Enter ssh user: prisoner
    ? Enter description: new device
    ? Select authentification: password
    ? Enter password:
    ? Save ? Yes
    name deviceinfo connection profile
    -------- -------------------------- ---------- -------
    tv2 prisoner@10.123.45.67:9922 ssh tv
    emulator developer@127.0.0.1:6622 ssh tv

     

  4. After adding device, check the result with the command below:
    ares-setup-device -list

     

  5. Click the Key Server button in the Developer Mode app.
    Key_Server_On.png
     

  6. Get the key file from the webOS TV with the following command:
    ares-novacom --device tv2 --getkey

     

  7. There will be a command prompt to enter Passphrase. Enter the exact characters (case sensitive) as displayed on the TV screen.
    Passphrase consist of 6 characters and are shown in the bottom left side of the Developer Mode app screen.
    input passphrase [default: webos]:

     

  8. Check the connection with the TV and PC with the following command:
    ares-install --device tv2 --list

     

  9. Now, you are ready to install and launch your app on the real TV. To find out how to install and launch your app on the TV, go to Installing and launching your app using CLI.

Connecting with IDE

Follow the instructions below to add the target TV with IDE:

  1. Run webOS TV IDE.
  2. Click New Connection (New_Connection.png) from the Target Configuration screen.
  3. Enter the information of the target TV as below:

    • Set Device Type as LG Smart TV.
    • Change Device Name as you want
    • Input IP address of target TV.

    New_Target_Connection.png
     

  4. Click the Key Server button in the Developer Mode app.
    Key_Server_On.png
     

  5. Right-click the created item and select Generate Key.
    Generate_Key.png
     

  6. There will be a webOS key window to enter Passphrase. Enter the exact characters (case sensitive) as displayed on the TV screen.
    Passphrase consist of 6 characters and are shown in the bottom left side of the Developer Mode app screen.
    Passphrase.png
     

  7. Connect the TV using the right-click menu. Then you will see the apps you installed on the TV under tv > Installed. If it is your first time using the Developer Mode app, no app will be shown on the screen.
    TV_Connected.png
     
  8. Now, you are ready to install and launch your app on the real TV. To find out how to install and launch your app on the TV, go to Installing and launching your app using IDE.

Extending Developer Mode Time

When you turn on the Developer mode, Developer mode app shows how much time have left of Developer mode (Remain Session). As you see, Developer mode enables for limited time. If you want to extend the remain time, click the Extendbutton. Then, developer mode app will renew the time again.

Extend_Dev_Mode_Time.png

Even the time have run out, you can extend the time with this button before TV power off.

Clearing Cache Data of Apps

Developer mode app provides Clear Cache Data button for testing. You can clear cache data of all apps with following steps:

  1. Click the Clear Cache Data button.
    Clear_Cache_Data_On_Dev_Mode.png
     
  2. Reboot the TV.
This feature will remove cache data of all apps in your TV.
Navigation