Configuring Android TV Status Bar Battery with a Custom Xposed
Updated 2026-11-08
The Android TV status bar hides battery-level information behind the system UI, and many users lose access to the percentage readout when they change the default launcher. Custom Xposed modules for Android TV let you inject a small hook into the status bar renderer so it reads battery data from the TPL2 power service and displays it next to the time. This guide shows step by step how to set up the launcher, enable the hook, and verify that the battery badge appears correctly on your box.
Why Android TV shows no battery icon on default launchers
Most Samsung, LG, and Sony Android TV models ship with a stock launcher that draws the status bar from system resources alone. When the system does not expose battery percentages as a drawable element, the launcher respects that absence and leaves the bar empty beneath the clock. Users who install a third-party launcher—either from the Android TV app store or from a side-loaded APK—often find the same gap, which makes low-power mode difficult to manage without a separate overlay.
A custom Xposed module that wraps the power service call solves this without touching the system partition. Instead, it supplies a small overlay component that queries BatteryManager every few seconds and paints a compact label into the top-left corner of the status bar. Because the hook lives in user space, you can keep the original launcher intact and swap it back instantly if something goes wrong.
How a battery-reading Xposed module works on Android TV
The module targets the same BatteryManager API used by the Settings > Battery screen. It calls getStateProperties() to extract percent, status, and level. It then calculates the remaining minutes from level / (discharge rate) and converts that to an 8-bit alpha mask that drives a tiny text field. The field sits inside onDraw for the status bar surface group: background transparent, foreground white text, font size around 10sp.
The module also adds a small preference page so you can choose the display style: a fixed percentage show, a dynamic battery icon that changes color with charge level, or an off switch that hides the badge entirely. This preference is stored in the module’s private data path, and toggling it triggers a reload without rebooting the box. Because the module hooks only the getPowerUsage method and does not intercept the normal status bar drawing pipeline, it runs alongside the stock launcher without visible lag, typically adding less than 5 milliseconds per frame.
If your TV runs a build that pins Xposed to a specific version, make sure you are using the Android TV-compatible build of the module. The API surface changed slightly around Xposed Framework 7.0; builds intended for phones often fail to load on the TV platform.
Setting up the launcher and installing the module
First, confirm that Xposed Framework is installed. Open Settings > Apps > Special Access > Xposed Framework and verify the toggle is on, or flash a build that includes the framework binary. Without that foundation, no module will load.
Next, obtain the launcher package you intend to use. For a clean test, try the open-source “Launcher 2” variants that publish for Android TV via sideloading. Install the APK and boot the device into recovery mode if the standard update path does not expose the package manager. Confirm the file appears in adb shell /data/system/frameworks/com.android.package-framework-*.zip or the equivalent package store.
To load the battery module, copy the .xmod archive to the root of the boot image partition, then run am instrument -w com.example.android.tv.batteryhook. The module will register its components in Android.mk and write a marker file in /data/local/.xposed. After the device restarts, open Settings > System > Developer options and enable “Debugging” to see the module icon in the quick settings tile area. Long-press the tile and select “Enable module.”
The first launch may show a brief “Module disabled” message. That is normal while the framework finishes indexing the hook. On subsequent boots, the badge should appear beneath the clock time on every screen, including the home page and the notification shade.
Verifying the readout and troubleshooting common failures
Check the badge during three scenarios: idle power state, charging on the wall adapter, and discharging while watching a movie. An accurate percentage reading confirms that BatteryManager is being queried from user space and not overridden by a broken plugin. If the number stays at zero or repeats the same value, disable any other launcher-installed battery widget, since some competing widgets write to the same surface group and overwrite the text.
A common failure point is incorrect API level handling. Some Android TV builds still target APIs below L27, where getStateProperties() returns fewer fields. If the module returns an empty string, add a fallback to intent.getExtra("level") and intent.getExtra("status") in the source code and rebuild. Another frequent issue is insufficient storage permission for the module cache directory; delete /data/local/.xposed/cache and retry.
When the badge does not appear on the first attempt, clear the module’s preference page and re-enable it. In rare cases the hook fails to attach to the status bar surface group; reboot the box and re-enable via the quick settings tile, because the service must be alive before it can observe the draw callback.
When to keep the stock launcher and when to rely on the hook
If you need full control over the home screen layout, the Xposed battery hook is a lightweight addition that does not block switching back to the stock launcher. For users who want a permanent badge alongside the clock hour and day, the module is a small, self-contained replacement for the missing status bar feature. Otherwise, leave the hook disabled and avoid installing untested mod bundles, since an unverified Xposed module can interfere with OTA updates on some firmware versions.
Both approaches require a working Xposed installation. If your TV cannot boot into recovery, flash a build that includes Xposed, or use the built-in status bar tweaks available in some stock firmware. The launcher-based battery readout is not magic, but once configured it gives you reliable low-power information without relying on a hidden Settings screen.
Related reading: more Android TV notes
Read next
Integrating Chromecast on Android TV Without a Separate Launcher
Learn to route Cast screen share directly through Android TV using the built-in Chromecast UI—no extra launcher needed.
Optimizing Battery Life with Low-Wake Android TV Launchers
Learn which Android TV launchers preserve battery best and step-by-step settings to cut wake locks and extend screen time on your set-top box.