Developer Tool Options
The Developer Tools Menu provides a number of options that provide real-time metrics and other information about your app. This information can assist you in troubleshooting, development, and testing.
- Invoke the Developer Tools Menu
- System X-Ray
- Advanced Options
- Record & Share
- Developer Options
- Network Proxy
- Launch Network Advisor
- See Also
Invoke the Developer Tools Menu
You can invoke the Developer Tools menu in several ways:
- Remote Control: On the directional pad, press and hold the center and down together (simultaneously) for 5 seconds; then release the buttons and press the remote's menu button.
- Amazon Game Controller: Press and hold A and Y buttons together (simultaneously) for 5 seconds; then release the buttons and press the controller's menu button.
- If ADB is enabled on the Fire TV and a computer is connected, you can run the following command to invoke the dialog box:
adb shell am start com.amazon.ssm/com.amazon.ssm.ControlPanel
The following screenshot shows the options on the Developer Tools menu:
System X-Ray gathers instantaneous system metrics and displays on top of the screen as an overlay. When toggled on, the overlay will always be visible on the screen.
The System X-Ray overlay contains details about the following:
For deep-dive into System X-Ray, see System X-Ray.
Advanced Options enables multimedia information to appear when Android MediaCodec APIs are in use. When you switch this option on and then play media, an additional display (titled "MUL" for Multimedia (audio and video) and "AUD" for Audio Focus) appears on the right.
Information displayed in the Multimedia panel is divided into three sections: Audio, Video, and Audio Focus.
|Codec||Audio codec format|
|Hardware Accelerated||If audio playback is hardware accelerated|
|Input Bitrate||Audio input bitrate|
|Secure||If secure or not|
|Codec||Video Codec Format|
|Hardware Accelerated||If video playback is hardware accelerated|
|Input Bitrate||Video Input Bitrate|
|Secure||If video secure or not|
|Frames Dropped||Frame drop count|
|Frame Rate||Playback frame rate|
|Package||Package name of the audio playback|
|Gain||Audio focus gain implication|
|Loss||Audio focus loss implication|
|F/U/C||Flag / Usage / Content|
Audio Focus values are shortened as following:
Snapshot provides a way for users to gather instantaneous all metrics information through
adb command. Whenever you input the following command, metric information will display in the command line.
adb shell dumpsys activity service com.amazon.ssm/.OverlayService
System X-Ray must be running for this command to function.
Here's a sample output:
SERVICE com.amazon.ssm/.OverlayService 3dde6680 pid=10820 Client: [com.amazon.ssm.timestamp]: [2017-02-07 15:11:53] [com.amazon.ssm.display.resolution]:  [com.amazon.ssm.display.refreshrate]:  [com.amazon.ssm.display.hdcpversion]: [1.0] [com.amazon.ssm.cpu.core0]:  [com.amazon.ssm.cpu.core1]:  [com.amazon.ssm.cpu.core2]:  [com.amazon.ssm.cpu.core3]:  [com.amazon.ssm.memory.appname]: [tv.twitch.android.viewer] [com.amazon.ssm.memory.appmemory]: [56.8 MB] [com.amazon.ssm.memory.activememory]: [1.3 GB] [com.amazon.ssm.memory.availablememory]: [231.3 MB] [com.amazon.ssm.network.rssi]: [-56] [com.amazon.ssm.network.systemdownloadspeed]: [2.2 Mbps] [com.amazon.ssm.network.appdownloadspeed]: [2.1 Mbps]
Record & Share
Record & Share stores instantaneous metrics about CPU, memory, network, and multimedia into a database as historical data. Although the same information is displayed graphically in real-time through the System X-Ray overlay, Record & Share takes this information and stores it into a history that you can dump to the command line.
To use Record & Share, first toggle the Record & Share setting in the Developer Tools Menu to On. You're then prompted to select the Record Settings:
These properties control the following:
- Interval: The time between two recordings: 2 seconds, 4 seconds, 8 seconds, 16 seconds, or 32 seconds.
- Duration: How long the data gets stored in the database: 1 hour, 2 hours, 4 hours, 8 hours, or 16 hours.
The default (2s interval, 1 hr duration) means that every 2 seconds, statistics will be recorded and stored in the database. The recording will be stored in the database for a total of 1 hour.
After playing media to gather some recorded information, you can dump all historical metrics to the command line using the following::
adb shell dumpsys activity service com.amazon.ssm/.OverlayService -all
The response includes the following information:
Here's an example of the display on the command line:
CPU Timestamp cpu0 cpu1 cpu2 cpu3 2016-10-31 11:40:22 19 16 13 18 MEMORY Timestamp Total_Memory Available_Memory Active_Memory Foreground_App_Memory Foreground_App_PackageName 2016-10-31 11:40:23 919.3 MB 156.3 MB 731.8 MB 31.3 MB com.amazon.ssm NETWORK Timestamp RSSI Download_Speed Foreground_App_Download_Speed Foreground_App_PackageName 2016-10-31 11:40:21 -41 14.4 kbps 0 bps com.amazon.ssm 2016-10-31 11:40:23 -41 14.0 kbps 0 bps com.amazon.ssm
If you're interested in only part of the metrics, you can add different options in the command. For example, to dump memory and network historical metrics to command line:
adb shell dumpsys activity service com.amazon.ssm/.OverlayService -memory -network
The following table shows all available options:
(no option passed)
|dump snapshot information|
||dump snapshot information|
||dump all information from database|
||dump memory information from database|
||dump CPU information from database|
||dump network information from database|
||dump multimedia information from database|
To check available options, pass the
adb shell dumpsys activity service com.amazon.ssm/.OverlayService -help
You can clear the recorded metrics stored in the database (before the duration time automatically clears the data). From the Developer Options Tools menu, select Record & Share, and then click the menu button on your remote.
Some TVs use overscan with their display. Overscan means the TV displays some information off the edges of the visible screen (to accommodate discrepancies in monitors). You should not display important information in the overscan areas.
To make the overscan areas visible, you can turn the SafeZone switch to On. This will make the overscan areas apparent so you can avoid displaying any information in these areas.
Note that Fire TV Stick (Gen 2) does not include screen size calibration. If the screen display doesn't fit correctly on the TV screen, the overscan area may not show accurately.
Currently, some third-party apps, such as Netflix and HBO Go, display recommendations on the Amazon Fire TV home screen in specific rows. For more information on recommendations, see Recommendations Overview.
Developer Options allows you to turn on a row called "Recommended By Your Apps" (displayed below the Netlix and HBO Go rows). This "Recommended By Your Apps" row will show recommendations sent from third-party apps.
Turning on this row shows recommendations from all third-party apps the user has installed (excluding some apps such as Netflix and HBO Go, which display recommendations on their own rows).
If your app communicates with remote services or websites, it's often useful to inspect the HTTP or HTTPS traffic it generates. This includes requests initiated by your app and the responses it receives, as well as HTTP headers containing (among other things) cookies and caching information.
The Network Proxy option allows you to specify the hostname and port of a proxy through which all network traffic will pass, allowing you to observe the data sent to or from your app. The proxy host and your Fire TV must be on the same network.
Working with HTTPS and Encrypted Data using Charles Proxy
If your app works with sensitive information, it is likely that you rely on HTTPS connections to protect against eavesdropping and man-in-the-middle attacks. In this case, traffic is SSL-encrypted between source and destination, keeping it private—the data is inaccessible even to a proxy you configure yourself through the Network Proxy option.
Some proxies support SSL Proxying, allowing you to view network traffic even when it's encrypted. Charles Proxy is a popular utility that offers this feature. When your app attempts to communicate with a remote server, Charles Proxy intercepts the server certificate and dynamically generates and signs one of its own. It uses this substitute certificate to establish a secure connection with your app, then securely connects to the remote site using the original server certificate it received, allowing you to view in plain text the communication between your app and the SSL web server.
To take advantage of SSL Proxying in Charles Proxy, your app must trust the certificate authority (Charles CA) used to sign the substitute certificate that Charles Proxy generates. On Fire OS 5, simply installing the certificate on your device is sufficient, since all apps implicitly trust certificates installed at the device level. On Fire OS 6, each app must explicitly specify which certificates it trusts by listing them in
To determine the Fire OS version installed on your test device, go to Settings > My Fire TV > About > Fire TV and look at the "Software Version" details. You can also review the complete list of Fire TV devices and their corresponding Fire OS versions.
The following steps assume you have already installed and configured Charles Proxy. See the documentation if you are new to the application.
Trusting Charles CA on FOS 5
- Obtain the certificate file in PEM format from within the Charles Proxy application. From the menu, choose Help > SSL Proxying > Save Charles Root Certificate….
- Upload the certificate file to your Fire TV device:
adb push charles-ssl-proxying-certificate.pem /storage/emulated/0/Download
- Bring up the Certificate Installer dialog for the file you just uploaded:
adb shell am start -a "android.intent.action.VIEW" -d "file:///storage/emulated/0/Download/charles-ssl-proxying-certificate.pem" -t "application/x-x509-ca-cert"
Provide a friendly name and ensure that VPN and apps is selected under Credential use.
- Press OK to install the certificate. You will be asked to authenticate with your Amazon credentials and an onscreen notification will confirm success.
Trusting Charles CA on FOS 6
- Obtain and install the certificate file as for FOS 5, above.
Update your Android project's manifest to include a Network Security Configuration file:
<?xml version="1.0" encoding="utf-8"?> <manifest ... > <application android:networkSecurityConfig="@xml/network_security_config" ... > ... </application> </manifest>
Add the following
res/xml/network_security_config.xmlto your Android project to explicitly trust all installed certificates:
<?xml version="1.0" encoding="utf-8"?> <network-security-config> <debug-overrides> <trust-anchors> <!-- Trust the following CA while debuggable only --> <certificates src="user"/> </trust-anchors> </debug-overrides> </network-security-config>
- Obtain the certificate file as for FOS 5, above, but do not install it on the device.
- Instead, embed the file directly in your app by copying it to the
res/rawsubdirectory of your Android project. You can rename the file for convenience, if you want (for example,
As above, update your Android project's manifest to add a Network Security Configuration file such as
res/xml/network_security_config.xml, but change the src attribute to use the filename you chose for the certificate:
... <!-- Trust the following CA while debuggable only --> <certificates src="@raw/my_ca"/> ...
Inspecting Encrypted Traffic
Once you have configured your device to trust the Charles CA certificate, you can enable the Network Proxy on your device and begin observing encrypted traffic to and from your app. It is important to perform the following steps in the order listed.
To inspect encrypted traffic using Charles Proxy:
- Make sure Charles Proxy is running.
Turn on SSL Proxying in the Charles Proxy application. From the menu, choose Proxy > SSL Proxy Settings…, then use Add to specify which hosts to observe. Subdomains such as
wwware considered distinct and should be listed individually.
On your device, set Network Proxy mode to Manual and specify the hostname (or IP address) and port number where Charles Proxy is running.
- Launch your app.
You can now view secure network traffic between your app and the server endpoints for which you enabled SSL Proxying in Charles Proxy. The data is unencrypted for display by Charles Proxy, then re-encrypted for delivery to its final destination. You can see cleartext headers and bodies of each request and response.
For more information about using Charles Proxy to inspect your app's network traffic, see the documentation.
Launch Network Advisor
Launches a network analysis window that checks your network connection strength, channel, and other details. If there are problems, the Network Advisor provides recommendations to fix the issues.
For more details, see the following: