Debugging the app

Table of Contents

  1. Introduction
  2. Debugging Dolby Voice Hub Apps
    2.1 Developer mode
           2.1.1 Enable developer mode and devtools
    2.2 Web app development tools
           2.2.1 DevTools
           2.2.2 WebRTC internals
           2.2.3 Run the web engine with flags (switches)
    2.3 Loading issues
           2.3.1 Error message displayed on monitor
           2.3.2 Check the Dolby Conference Phone UI
           2.3.3 Check Dolby Voice Hub web UI
  3. Debugging Dolby Conference Phone Apps
    3.1 Loading issues
    3.2 Logging
    3.3 The app log level
    3.4 Other common modules for debugging
    3.5 QML warnings
    3.6 Reload the app
    3.7 Memory and CPU load

1. Introduction

The Dolby Voice Room system consists of the Dolby Voice Hub and Dolby Conference Phone. Each component uses an app: a QML app for the phone and a web app for the hub. This document describes debugging techniques for each type of app.

2. Debugging Dolby Voice Hub apps

The Dolby Voice Hub app runs in a browser environment. The browser's web app development tools are used to diagnose the app.

2.1 Developer mode

By putting your Dolby Voice Room system into the developer mode, you get access to debugging tools: DevTools and webrtc-internals. Developer mode also allows you to set custom command line switches for the Hub's web engine.

You need to request a poweruser key from Dolby to enable the developer mode. The poweruser keys are generated specifically for the device based on the serial number and they are time-bound for security reasons.

It is important to note that the poweruser key should be removed after the debugging session for the production deployments.

2.1.1 Enable developer mode and DevTools

Follow these instructions to turn on the Dolby Voice Room developer mode.

  • Get a poweruser key from Dolby

To request a poweruser key, email the Dolby Conference Hub's serial number to *DolbyVoiceDeveloperSupport@dolby.com*. The Dolby Voice Hub's serial number can be found on a label on the bottom of the hub or via the Dolby Conference Phone's interface: Settings > Status > System. Dolby will email you the poweruser key.

  • Use the poweruser key to turn on developer mode

Log in to the Dolby Voice Hub shell to apply the key and enable the developer mode. Use PuTTY or a similar SSH or telnet program to log into the shell. The login name is admin; the password is 1739.

These commands are used to control the developer mode settings:

Command Description
system poweruser <key> Set the power user key.
system poweruser devtools enable Once the key is set, enable developer mode.
system poweruser devtools disable Turn off developer mode. This removes the command line switch settings (see below).
system poweruser devtools Show whether developer mode is enabled.

The following screen capture shows an example of these commands entered in the Dolby Voice Hub shell:

$ ssh admin@10.112.102.171
Enter password: ****

+- - - - - - - - - - - - - - - - - - -+
+   Dolby Voice Room     SN:Z0186343  +
+- - - - - - - - - - - - - - - - - - -+

DolbyCli>system poweruser devtools
Developer mode is disabled.

DolbyCli>system poweruser key E256:EB67:6C18:EC6C
Your device serial ID is 186343
Power user key is set to: E256:EB67:6C18:EC6C

DolbyCli>system poweruser devtools enable
Developer mode is enabled.
DolbyCli>

DolbyCli>system poweruser devtools disable
Developer mode is disabled.
DolbyCli>

Note: Enabling or disabling developer mode causes the app to restart so that changes can take effect.

2.2 Web app development tools

To access the web app development tools, get the Dolby Voice Hub's IP address: on the Dolby Conference Phone tap on Settings > Status > System.

image

Access to the web app development tools is via the following:

Environment Access Description
Dolby Voice Hub Web UI http://DV-hub-IP-address Provides configuration interfaces to adjust the Dolby Voice Hub and attached Dolby Conference Phone settings; also provides basic diagnostic functions. The login username and password is admin/1739.
DevTools http://DV-hub-IP-address:9000/ The primary mechanism for debugging the app. Allows the developer to examine the app status, DOM, console logs, etc., and set breakpoints. The DevTools are available after the developer mode has been enabled.
WebRTC Internals http://DV-hub-IP-address:9000/webrtc-internals Allows the developer to access the WebRTC internal status and real time media statistics. Helps developers troubleshoot audio/video connectivity problems. The webrtc-internals are available after the developer mode has been enabled.

2.2.1 DevTools

The DevTools are available after the developer mode has been enabled. To access the web development tools, enter the Dolby Voice Hub's IP address (e.g., http://DV-hub-IP-address:9000/) in a browser URL field and then click on the app link.

image

The DevTools page presents console log messages as well as other diagnostic panels.



2.2.2 WebRTC Internals

The webrtc-internals are available after the developer mode has been enabled. To access the webrtc-internals, start a video conference call and then enter the Dolby Voice Hub's IP address (e.g., http://DV-hub-IP-address:9000/webrtc-internals) in a browser URL field.

image

2.2.3 Run the web engine with flags (switches)

Once developer mode has been enabled, the Hub’s web engine can be run with additional command line switches (flags) to enable features or modify default functionality. Check this reference page for a list of command line switches.

This table shows how to use the command line switches:

Command Description
devtools set-cmdline-switch <switch(es)> Sets one or more command line arguments to pass to the web engine. Causes the app to restart.
devtools clr-cmdline-switch Clears all command line switch settings. Causes the app to restart.
devtools show-cmdline-switch Shows the command-line switches that are currently set using the set-cmdline-switch command.

The following example shows how to change the user agent (--user-agent) and disable the same original policy check (--disable-web-security).

DolbyCli>system poweruser devtools
Developer mode is enabled.

DolbyCli>devtools show-cmdline-switch
Custom command line switches:

DolbyCli>devtools set-cmdline-switch "--user-agent='my user agent' --disable-web-security"

DolbyCli>devtools show-cmdline-switch
Custom command line switches:
--user-agent='my user agent' --disable-web-security

DolbyCli>devtools clr-cmdline-switch
DolbyCli>devtools show-cmdline-switch
Custom command line switches:

DolbyCli>



Note: These commands manage additional flags which will be appended to the default set of flags. The default command line switches cannot be modified or removed.

Note: When a command line switch is set or modified, the app will restart and use the new switches.

2.3 Loading issues

The first problem that may occur is when the app does not load onto the Dolby Voice Hub. There are several approaches to checking the app status.

2.3.1 Error message displayed on monitor

The monitor attached to the Dolby Voice Hub will show an error message.



2.3.2 Check the Dolby Conference Phone UI

An app loading error will cause the Dolby Conference Phone's Settings icon on the home page to display a red mark.

image

Use the Dolby Conference Phone's UI to show the app status. Tap Home > Settings > Conference apps. Two choices are shown:

  • Video hub app
  • Conference phone app

Click on one to show its status:



2.3.3 Check Dolby Voice Hub web UI

Use the Dolby Voice Hub web UI to check the app status as well as the download location fields.

The Dolby Voice Hub app URL is set in the Settings > Dolby Voice Conferencing Service > Hub Application > Application URL field:



For status information, navigate to Status > Dolby Voice Hub > Device > Application. The following shows the status associated with attempting to load an app from the badURLexample location shown above.



3. Debugging Dolby Conference Phone Apps

3.1 Loading issues

If an app fails to load onto a Dolby Conference Phone, it may be due to errors such as a signature mismatch, checksum failure, SSL errors, or other network errors. The app's name, load status, and version, can be viewed on the Dolby Conference Phone settings menu or via the Dolby Voice Hub web UI. Note that the settings menu is not available when a device is in OOBE.

If a monitor is attached to the Dolby Voice Hub, the following message may be displayed.



The Dolby Conference Phone UI will show a grayed-out Loading application icon with a frozen loading graphic and the Settings icon will have a red mark.



To inspect the app status on the Dolby Conference Phone UI, tap Home > Settings > Conference apps. Tap on the Conference phone app line. A screen like the following will be displayed.



To view the app status via the Dolby Voice Hub web UI, navigate to Status > Dolby Conference Phone > Application. The following shows the status associated with attempting to load an app from the badURLexample location shown above.



3.2 Logging

The app can use the logging API to log events. Logged events are recorded in the non-volatile memory of the Dolby Conference Phone and can be retrieved several ways. For more details on accessing the logs on the Dolby Conference Phone, refer to the Conferencing app deployment guide.

The Dolby Conference Phone SDK IDE contains a syslog server. This syslog server is automatically started when the IDE is launched. To configure the Dolby Conference Phone to send log events to the syslog server, follow these instructions:

  • Log in to the Dolby Video Hub web UI.
  • Click on Settings > Logging > Syslog Service.
  • Turn on Enable Syslog.
  • Enter the IDE virtual appliance's IP address in the Syslog Server IP Address field.

On the Dolby Conference Phone SDK IDE, click on "Applications", select "System tools", then click on "Log File Viewer" to launch the log viewer.

Once the log viewer is started, click on File, select Open, then navigate to the /var/log/dolby folder. Once the Dolby Conference Phone successfully connects to the syslog server, you will see a file name in the form of ip.messages, where the ip is the IP address of the Dolby Conference Phone. Click on this file to view its log. The information in this window is dynamically updated. The following screenshot shows the log viewer application.



3.3 The app log level

By default, the app log level is set to INFO which ignores all events that are tagged as DEBUG or DEBUG1. To capture these events, change the log level using the following instructions.

  • Log in to the Dolby Voice Hub web UI.
  • Click on Settings > Logging > Log Levels
  • Find the UI Module, and change its log level from INFO to either DEBUG or DEBUG1.

Note Activating the debug log level will usually impact the performance of the Dolby Conference Phone. A system level warning is turned on to remind the user that the debug log level setting may affect the phone's performance.

3.4 Other common modules for debugging

To debug Dolby Voice conference call-related issues, set the SIP Module log level to DEBUG.

To debug configuration-related issues, set the CFG Module log level to DEBUG.

3.5 QML warnings

A bug in the app will often trigger a QML warning. All QML warnings are logged by the Dolby Conference Phone. Optionally, the Dolby Conference Phone can also display a pop-up notification as the result of a QML error. This feature can be enabled by setting the configuration parameter Dvms.DeveloperMode.Enabled to true. To toggle the developer mode parameter, follow these instructions:

  • Log into the Dolby Voice Hub web UI.
  • Click on Settings > Dolby Voice Conferencing Service >Developer Mode
  • Turn on Enable developer mode.

Once enabled, when the Dolby Conference Phone encounters a QML error, it will display a screen like the following.



3.6 Reload the app

If the app enters a bad state, press and hold the mute button for 10 seconds to force the Dolby Conference Phone to reload the app. The Dolby Conference Phone will unload the app, download the app from the app deployment server, and then load it into memory.

3.7 Memory and CPU load

The Dolby Conference Phone constantly tracks the memory and CPU usage. To find out how the app affects the memory and CPU usage, follow these instructions:

  • Log into the Dolby Video Hub web UI.
  • Click on Status > Dolby Conference Phone > Resources

A web page like the following will be displayed.